index int64 0 20.3k | text stringlengths 0 1.3M | year stringdate 1987-01-01 00:00:00 2024-01-01 00:00:00 | No stringlengths 1 4 |
|---|---|---|---|
6,400 | Unified Methods for Exploiting Piecewise Linear Structure in Convex Optimization Tyler B. Johnson University of Washington, Seattle tbjohns@washington.edu Carlos Guestrin University of Washington, Seattle guestrin@cs.washington.edu Abstract We develop methods for rapidly identifying important components of a convex optimization problem for the purpose of achieving fast convergence times. By considering a novel problem formulation—the minimization of a sum of piecewise functions—we describe a principled and general mechanism for exploiting piecewise linear structure in convex optimization. This result leads to a theoretically justified working set algorithm and a novel screening test, which generalize and improve upon many prior results on exploiting structure in convex optimization. In empirical comparisons, we study the scalability of our methods. We find that screening scales surprisingly poorly with the size of the problem, while our working set algorithm convincingly outperforms alternative approaches. 1 Introduction Scalable optimization methods are critical for many machine learning applications. Due to tractable properties of convexity, many optimization tasks are formulated as convex problems, many of which exhibit useful structure at their solutions. For example, when training a support vector machine, the optimal model is uninfluenced by easy-to-classify training instances. For sparse regression problems, the optimal model makes predictions using a subset of features, ignoring its remaining inputs. In these examples and others, the problem’s “structure” can be exploited to perform optimization efficiently. Specifically, given the important components of a problem (for example the relevant training examples or features) we could instead optimize a simpler objective that results in the same solution. In practice, since the important components are unknown prior to optimization, we focus on methods that rapidly discover the relevant components as progress is made toward convergence. One principled method for exploiting structure in optimization is screening, a technique that identifies components of a problem guaranteed to be irrelevant to the solution. First proposed by [1], screening rules have been derived for many objectives in recent years. These approaches are specialized to particular objectives, so screening tests do not readily translate between optimization tasks. Prior works have separately considered screening irrelevant features [1–8], training examples [9, 10], or constraints [11]. No screening test applies to all of these applications. Working set algorithms are a second approach to exploiting structure in optimization. By minimizing a sequence of simplified objectives, working set algorithms quickly converge to the problem’s global solution. Perhaps the most prominent working set algorithms for machine learning are those of the LIBLINEAR library [12]. As is common with working set approaches, there is little theoretical understanding of these algorithms. Recently a working set algorithm with some theoretical guarantees was proposed [11]. This work fundamentally relies on the objective being a constrained function, however, making it unclear how to use this algorithm for other problems with structure. The purpose of this work is to both unify and improve upon prior ideas for exploiting structure in convex optimization. We begin by formalizing the concept of “structure” using a novel problem 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. formulation: the minimization of a sum of many piecewise functions. Each piecewise function is defined by multiple simpler subfunctions, at least one of which we assume to be linear. With this formulation, exploiting structure amounts to selectively replacing piecewise terms in the objective with corresponding linear subfunctions. The resulting objective can be considerably simpler to solve. Using our piecewise formulation, we first present a general theoretical result on exploiting structure in optimization. This result guarantees quantifiable progress toward a problem’s global solution by minimizing a simplified objective. We apply this result to derive a new working set algorithm that compares favorably to [11] in that (i) our algorithm results from a minimax optimization of new bounds, and (ii) our algorithm is not limited to constrained objectives. Later, we derive a state-ofthe-art screening test by applying the same initial theoretical result. Compared to prior screening tests, our screening result is more effective at simplifying the objective function. Moreover, unlike previous screening results, our screening test applies to a broad class of objectives. We include empirical evaluations that compare the scalability of screening and working set methods on real-world problems. While many screening tests have been proposed for large-scale optimization, we have not seen the scalability of screening studied in prior literature. Surprisingly, although our screening test significantly improves upon many prior results, we find that screening scales poorly as the size of the problem increases. In fact, in many cases, screening has negligible effect on overall convergence times. In contrast, our working set algorithm improves convergence times considerably in a number of cases. This result suggests that compared to screening, working set algorithms are significantly more useful for scaling optimization to large problems. 2 Piecewise linear optimization framework We consider optimization problems of the form minimize x∈Rn f(x) := ψ(x) + Pm i=1 φi(x) , (P) where ψ is γ-strongly convex, and each φi is convex and piecewise; for each φi, we assume a function πi : Rn →{1, 2, . . . , pi} and convex subfunctions φ1 i , . . . , φpi i such that ∀x ∈Rn, we have φi(x) = φπi(x) i (x) . As will later become clear, we focus on instances of (P) for which many of the subfunctions φk i are linear. We denote by X k i the subset of Rn corresponding to the kth piecewise subdomain of φi: X k i := {x : πi(x) = k} . The purpose of this work is to develop efficient and principled methods for solving (P) by exploiting the piecewise structure of f. Our approach is based on the following observation: Proposition 2.1 (Exploiting piecewise structure at x⋆). Let x⋆be the minimizer of f. For each i ∈[m], assume knowledge of πi(x⋆) and whether x⋆∈int(X πi(x⋆) i ). Define φ⋆ i = φπi(x⋆) i if x⋆∈int(X πi(x⋆) i ) , φi otherwise , where int(·) denotes the interior of a set. Then x⋆is also the solution to minimize x∈Rn f ⋆(x) := ψ(x) + Pm i=1 φ⋆ i (x) . (P⋆) In words, Proposition 2.1 states that if x⋆does not lie on the boundary of the subdomain X πi(x⋆) i , then replacing φi with the subfunction φπi(x⋆) i in f does not affect the minimizer of f. Despite having identical solutions, solving (P⋆) can require far less computation than solving (P). This is especially true when many φ⋆ i are linear, since the sum of linear functions is also linear. More formally, consider a set W⋆⊆[m] such that ∀i /∈W⋆, φ⋆ i is linear, meaning φ⋆ i (x) = ⟨a⋆ i , x⟩+ b⋆ i for some a⋆ i and b⋆ i . Defining a⋆= P i/∈W⋆a⋆ i and b⋆= P i/∈W⋆b⋆ i , then (P⋆) is equivalent to minimize x∈Rn f ⋆(x) := ψ(x) + ⟨a⋆, x⟩+ b⋆+ P i∈W⋆φ⋆ i (x) . (P⋆⋆) That is, (P) has been reduced from a problem with m piecewise functions to a problem of size |W⋆|. Since often |W⋆| ≪m, solving (P⋆) can be tremendously simpler than solving (P). The scenario is quite common in machine learning applications. Some important examples include: 2 • Piecewise loss minimization: φi is a piecewise loss with at least one linear subfunction. • Constrained optimization: φi takes value 0 for a subset of Rn and +∞otherwise. • Optimization with sparsity inducing penalties: ℓ1-regularized regression, group lasso, fused lasso, etc., are instances of (P) via duality [13]. We include elaboration on these examples in Appendix A. 3 Theoretical results We have seen that solving (P⋆) can be more efficient than solving (P). However, since W⋆is unknown prior to optimization, solving (P⋆) is impractical. Instead, we can hope to design algorithms that rapidly learn W⋆. In this section, we propose principled methods for achieving this goal. 3.1 A general mechanism for exploiting piecewise linear structure In this section, we focus on the consequences of minimizing the function f ′(x) := ψ(x) + Pm i=1 φ′ i(x) , where φ′ i ∈{φi} ∪{φ1 i , . . . , φpi i }. That is, φ′ i is either the original piecewise function φi or one of its subfunctions φk i . With (P⋆) unknown, it is natural to consider this more general class of objectives (in the case that φ′ i = φ⋆ i for all i, we see f ′ is the objective function of (P⋆)). The goal of this section is to establish choices of f ′ such that by minimizing f ′, we can make progress toward minimizing f. We later introduce working set and screening methods based on this result. To guide the choice of f ′, we assume points x0 ∈Rn, y0 ∈dom(f), where x0 minimizes a γ-strongly convex function f0 that lower bounds f. The point y0 represents an existing approximation of x⋆, while x0 can be viewed as a second approximation related to a point in (P)’s dual space. Since f0 lower bounds f and x0 minimizes f0, note that f0(x0) ≤f0(x⋆) ≤f(x⋆). Using this fact, we quantify the suboptimality of x0 and y0 in terms of the suboptimality gap ∆0 := f(y0) −f0(x0) ≥f(y0) −f(x⋆) . (1) Importantly, we consider choices of f ′ such that by minimizing f ′, we can form points (x′, y′) that improve upon the existing approximations (x0, y0) in terms of the suboptimality gap. Specifically, we define x′ as the minimizer of f ′, while y′ is a point on the segment [y0, x′] (to be defined precisely later). Our result in this section applies to choices of f ′ that satisfy three natural requirements: R1. Tight in a neighborhood of y0: For a closed set S with y0 ∈int(S), f ′(x) = f(x) ∀x ∈S. R2. Lower bound on f: For all x, we have f ′(x) ≤f(x). R3. Upper bound on f0: For all x, we have f ′(x) ≥f0(x). Each of these requirements serves a specific purpose. After solving x′ := argminx f ′(x), R1 enables a backtracking operation to obtain a point y′ such that f(y′) < f(y0) (assuming y0 ̸= x⋆). We define y′ as the point on the segment (y0, x′] that is closest to x′ while remaining in the set S: θ′ := max {θ ∈(0, 1] : θx′ + (1 −θ)y0 ∈S} , y′ := θ′x′ + (1 −θ′)y0 . (2) Since (i) f ′ is convex, (ii) x′ minimizes f ′, and (iii) y0 ∈int(S), it follows that f(y′) ≤f(y0). Applying R2 leads to the new suboptimality gap ∆′ := f(y′) −f ′(x′) ≥f(y′) −f(x⋆) . (3) R2 is also a natural requirement since we are interested in the scenario that many φ′ i are linear, in which case (i) φ′ i lower bounds φi as a result of convexity, and (ii) the resulting f ′ likely can be minimized efficiently. Finally, R3 is useful for ensuring f ′(x′) ≥f0(x′) ≥f0(x0). It follows that ∆′ ≤∆0. Moreover, this improvement in suboptimality gap can be quantified as follows: Lemma 3.1 (Guaranteed suboptimality gap progress—proven in Appendix B). Consider points x0 ∈Rn, y0 ∈dom(f) such that x0 minimizes a γ-strongly convex function f0 that lower bounds f. For any function f ′ that satisfies R1, R2, and R3, let x′ be the minimizer of f ′, and define θ′ and y′ via backtracking as in (2). Then defining suboptimality gaps ∆0 and ∆′ as in (1) and (3), we have ∆′ ≤(1 −θ′) ∆0 −1+θ′ θ′2 γ 2 min z/∈int(S)
z −θ′x0+y0 1+θ′
2 − θ′ 1+θ′ γ 2 ∥x0 −y0∥2 . The primary significance of Lemma 3.1 is the bound’s relatively simple dependence on S. We next design working set and screening methods that choose S to optimize this bound. 3 Algorithm 1 PW-BLITZ initialize y0 ∈dom(f) # Initialize x0 by minimizing a simple lower bound on f: ∀i ∈[m], φ′ i,0(x) := φi(y0) + ⟨gi, x −y0⟩, where gi ∈∂φi(y0) x0 ←argminx f ′ 0(x) := ψ(x) + Pm i=1 φ′ i,0(x) for t = 1, . . . , T until xT = yT do # Form subproblem: Select βt ∈[0, 1 2] ct ←βtxt−1 + (1 −βt)yt−1 Select threshold τt > βt ∥xt−1 −yt−1∥ St := {x : ∥x −ct∥≤τt} for i = 1, . . . , m do k ←πi(yt−1) if (C1 and C2 and C3) then φ′ i,t := φk i else φ′ i,t := φi # Solve subproblem: xt ←argminx f ′ t(x) := ψ(x) + Pm i=1 φ′ i,t(x) # Backtrack: αt ←argminα∈(0,1] f(αxt + (1 −α)yt−1) yt ←αtxt + (1 −αt)yt−1 return yT 3.2 Piecewise working set algorithm Lemma 3.1 suggests an iterative algorithm that, at each iteration t, minimizes a modified objective f ′ t(x) := ψ(x) + Pm i=1 φ′ i,t(x), where φ′ i,t ∈{φi} ∪{φ1 i , . . . , φpi i }. To guide the choice of each φ′ i,t, our algorithm considers previous iterates xt−1 and yt−1, where xt−1 minimizes f ′ t−1. For all i ∈[m], j = φi(yt−1), we define φ′ i,t = φj i if the following three conditions are satisfied: C1. Tight in the neighborhood of yt−1: We have St ⊆X k i (implying φi(x) = φk i (x) ∀x ∈St). C2. Lower bound on φi: For all x, we have φk i (x) ≤φi(x). C3. Upper bound on φ′ i,t−1 in the neighborhood of xt−1: For all x ∈Rn and gi ∈∂φ′ i,t−1(xt−1), we have φk i (x) ≥φ′ i,t−1(xt−1) + ⟨gi, x −xt−1⟩. If any of the above conditions are unmet, then we let φ′ i,t = φi. As detailed in Appendix C, this choice of φ′ i,t ensures f ′ t satisfies conditions analogous to conditions R1, R2, and R3 for Lemma 3.1. After determining f ′ t, the algorithm proceeds by solving xt ←argminx f ′ t(x). We then set yt ←αtxt + (1 −αt)yt−1, where αt is chosen via backtracking. Lemma 3.1 implies the suboptimality gap ∆t := f(yt) −f ′ t(xt) decreases with t until xT = yT , at which point ∆T = 0 and xT and yT solve (P). Defined in Algorithm 1, we call this algorithm “PW-BLITZ” as it extends the BLITZ algorithm for constrained problems from [11] to a broader class of piecewise objectives. An important consideration of Algorithm 1 is the choice of St. If St is large, C1 is easily violated, meaning φ′ i,t = φi for many i. This implies f ′ t is difficult to minimize. In contrast, if St is small, then φ′ i,t is potentially linear for many i. In this case, f ′ t is simpler to minimize, but ∆t may be large. Interestingly, conditioned on oracle knowledge of θt := max {θ ∈(0, 1] : θxt + (1 −θ)yt−1 ∈St}, we can derive an optimal St according to Lemma 3.1 subject to a volume constraint vol(St) ≤V : S⋆ t := argmax S : vol(S)≤V min z/∈int(S)
z −θtxt−1+yt−1 1+θt
. S⋆ t is a ball with center θtxt−1+yt−1 1+θt . Of course, this result cannot be used in practice directly, since θt is unknown when choosing St. Motivated by this result, Algorithm 1 instead defines St as a ball with radius τt and a similar center ct := βtxt−1 + (1 −βt)yt−1 for some βt ∈[0, 1 2]. 4 By choosing St in this manner, we can quantify the amount of progress Algorithm 1 makes at ieration t. Our first theorem lower bounds the amount of progress during iteration t of Algorithm 1 for the case in which βt happens to be chosen optimally. That is, St is a ball with center θtxt−1+yt−1 1+θt . Theorem 3.2 (Convergence progress with optimal βt). Let ∆t−1 and ∆t be the suboptimality gaps after iterations t −1 and t of Algorithm 1, and suppose that βt = θt(1 + θt)−1. Then ∆t ≤∆t−1 + γ 2 τ 2 t −3 2 γτ 2 t ∆2 t−1 1/3 . Since the optimal βt is unknown when choosing St, our second theorem characterizes the worst-case performance of extremal choices of βt (the cases βt = 0 and βt = 1 2). Theorem 3.3 (Convergence progress with suboptimal βt). Let ∆t−1 and ∆t be the suboptimality gaps after iterations t −1 and t of Algorithm 1, and suppose that βt = 0. Then ∆t ≤∆t−1 + γ 2 τ 2 t −(2γτ 2 t ∆t−1)1/2. Alternatively, suppose that βt = 1 2 , and define dt := ∥xt−1 −yt−1∥. Then ∆t ≤∆t−1 + γ 2 (τt −1 2dt)2 −3 2 γ(τt −1 2dt)2∆2 t−1 1/3 . These results are proven in Appendices D and E. Note that it is often desirable to choose τt such that γ 2 τ 2 t is significantly less than ∆t−1. (In the alternative case, the subproblem objective f ′ t may be no simpler than f. One could choose τt such that ∆t = 0, for example, but as we will see in §3.3, we are only performing screening in this scenario.) Assuming γ 2 τ 2 t is small in relation to ∆t−1, the ability to choose βt is advantageous in terms of worst case bounds if one manages to select βt ≈θt(1 + θt)−1. At the same time, Theorem 3.3 suggests that Algorithm 1 is robust to the choice of βt; the algorithm makes progress toward convergence even with worst-case choices of this parameter. Practical considerations We make several notes about using Algorithm 1 in practice. Since subproblem solvers are iterative, it is important to only compute xt approximately. In Appendix F, we include a modified version of Lemma 3.1 that considers this case. This result suggests terminating subproblem t when f ′ t(xt) −minx f ′ t(x) ≤ϵ∆t−1 for some ϵ ∈(0, 1). Here ϵ trades off the amount of progress resulting from solving subproblem t with the time dedicated to solving this subproblem. To choose βt, we find it practical to initialize β0 = 0 and let βt = αt−1(1 + αt−1)−1 for t > 0. This roughly approximates the optimal choice βt = θt(1 + θt)−1, since θt can be viewed as a worst-case version of αt, and αt often changes gradually with t. Selecting τt is problem dependent. By letting τt = βt ∥xt−1 −yt−1∥+ ξ∆1/2 t−1 for a small ξ > 0, Algorithm 1 converges linearly in t. It can also be beneficial to choose τt in other ways—for example, choosing τt so subproblem t fits in memory. It is also important to recognize the relative amount of time required for each stage of Algorithm 1. When forming subproblem t, the time consuming step is checking condition C1. In the most common scenarios that X k i is a half-space or ball, this condition is testable in O(n) time. However, for arbitrary regions, this condition could be difficult to test. The time required for solving subproblem t is clearly application dependent, but we note it can be helpful to select subproblem termination criteria to balance time usage between stages of the algorithm. The backtracking stage is a 1D convex problem that at most requires evaluating f a logarithmic number of times. Simpler backtracking approaches are available for many objectives. It is also not necessary to perform exact backtracking. Relation to BLITZ algorithm Algorithm 1 is related to the BLITZ algorithm [11]. BLITZ applies only to constrained problems, however, while Algorithm 1 applies to a more general class of piecewise objectives. In Appendix G, we ellaborate on Algorithm 1’s connection to BLITZ and other algorithms. 3.3 Piecewise screening test Lemma 3.1 can also be used to simplify the objective f in such a way that the minimizer x⋆is unchanged. Recall Lemma 3.1 assumes a function f ′ and set S for which f ′(x) = f(x) for all x ∈S. The idea of this section is to select the smallest region S such that in Lemma 3.1, ∆′ must equal 0 (according to the lemma). In this case, the minimizer of f ′ is equal to the minimizer of f—even though f ′ is potentially much simpler to minimize. This results in the following screening test: 5 Theorem 3.4 (Piecewise screening test—proven in Appendix H). Consider any x0, y0 ∈Rn such that x0 minimizes a γ-strongly convex function f0 that lower bounds f. Define the suboptimality gap ∆0 := f(y0) −f0(x0) as well as the point c0 := x0+y0 2 . Then for any i ∈[m] and k = πi(y0), if S := x : ∥x −c0∥≤ q 1 γ ∆0 −1 4 ∥x0 −y0∥2 ⊆int(X k i ) , then x⋆∈int(X k i ). This implies φi may be replaced with φk i in (P) without affecting x⋆. Theorem 3.4 applies to general X k i , and testing if S ⊆int(X k i ) may be difficult. Fortunately, X k i often is (or is a superset of) a simple region that makes applying Theorem 3.4 simple. Corollary 3.5 (Piecewise screening test for half-space X k i ). Suppose that X k i ⊇{x : ⟨ai, x⟩≤bi} for some ai ∈Rn, bi ∈R. Define x0, y0, ∆0, and c0 as in Theorem 3.4. Then x⋆∈int(X k i ) if bi −⟨ai, c0⟩ ∥ai∥ > q 1 γ ∆0 −1 4 ∥x0 −y0∥2 . Corollary 3.6 (Piecewise screening test for ball X k i ). Suppose that X k i ⊇{x : ∥x −ai∥≤bi} for some ai ∈Rn, bi ∈R>0. Define x0, y0, ∆0, and c0 as in Theorem 3.4. Then x⋆∈int(X k i ) if bi −∥ai −c0∥> q 1 γ ∆0 −1 4 ∥x0 −y0∥2 . Corollary 3.5 applies to piecewise loss minimization (for SVMs, discarding examples that are not marginal support vectors), ℓ1-regularized learning (discarding irrelevant features), and optimization with linear constraints (discarding superfluous constraints). Applications of Corollary 3.6 include group lasso and many constrained objectives. In order to obtain the point x0, it is usually practical to choose f0 as the sum of ψ and a first-order lower bound on Pm i=1 φi. In this case, computing x0 is as simple as finding the conjugate of ψ. We illustrate this idea with an SVM example in Appendix I. Since ∆0 decreases over the course of an iterative algorithm, Theorem 3.4 is “adaptive,” meaning it increases in effectiveness as progress is made toward convergence. In contrast, most screening tests are “nonadaptive.” Nonadaptive screening tests depend on knowledge of an exact solution to a related problem, which is disadvantageous, since (i) solving a related problem exactly is generally computationally expensive, and (ii) the screening test can only be applied prior to optimization. Relation to existing screening tests Theorem 3.4 generalizes and improves upon many existing screening tests. We summarize Theorem 3.4’s relation to previous results below. Unlike Theorem 3.4, existing tests typically apply to only one or two objectives. Elaboration is included in Appendix J. • Adaptive tests for sparse optimization: Recently, [6], [7], and [8] considered adaptive screening tests for several sparse optimization problems, including ℓ1-regularized learning and group lasso. These tests rely on knowledge of primal and dual points (analogous to x0 and y0), but the tests are not as effective (nor as general) as Theorem 3.4. • Adaptive tests for constrained optimization: [11] considered screening with primal-dual pairs for constrained optimization problems. The resulting test is a more general version (applies to more objectives) of [6], [7], and [8]. Thus, Theorem 3.4 improves upon [11] as well. • Nonadaptive tests for degree 1 homogeneous loss minimization: [10] considered screening for ℓ2-regularized learning with hinge and ℓ1 loss functions. This is a special non-adaptive case of Theorem 3.4, which requires solving the problem with greater regularization prior to screening. • Nonadaptive tests for sparse optimization: Some tests, such as [4] for the lasso, may screen components that Theorem 3.4 does not eliminate. In Appendix J, we show how Theorem 3.4 can be modified to generalize [4], but this change increases the time needed for screening. In practice, we were unable to overcome this drawback to speed up iterative algorithms. Relation to working set algorithm Theorem 3.4 is closely related to Algorithm 1. In particular, our screening test can be viewed as a working set algorithm that converges in one iteration. In the context of Algorithm 1, this amounts to choosing β1 = 1 2 and τ1 = q 1 γ ∆0 −1 4 ∥x0 −y0∥2. It is important to understand that it is usually not desirable that a working set algorithm converges in one iteration. Since screening rules do not make errors, these methods simplify the objective by only a modest amount. In many cases, screening may fail to simplify the objective in any meaningful way. In the following section, we consider real-world scenarios to demonstrate these points. 6 0 1 2 3 4 5 6 7 Time (s) 10−6 10−5 10−4 10−3 10−2 10−1 |g −g⋆|/|g⋆| 0 5 10 15 20 25 30 35 Time (s) 10−6 10−5 10−4 10−3 10−2 10−1 |g −g⋆|/|g⋆| 0 100 200 300 400 500 600 700 800 Time (s) 10−6 10−5 10−4 10−3 10−2 10−1 |g −g⋆|/|g⋆| 0 1 2 3 4 5 6 7 Time (s) 0.70 0.75 0.80 0.85 0.90 0.95 1.00 Support set precision 0 5 10 15 20 25 30 35 Time (s) 0.70 0.75 0.80 0.85 0.90 0.95 1.00 Support set precision 0 100 200 300 400 500 600 700 800 Time (s) 0.70 0.75 0.80 0.85 0.90 0.95 1.00 Support set precision DCA + working sets + piecewise screening DCA + working sets DCA + piecewise screening DCA + gap screening DCA (a) m = 100 (b) m = 400 (c) m = 1600 Figure 1: Group lasso convergence comparison. While screening is marginally useful for the problem with only 100 groups, screening becomes ineffective as m increases. The working set algorithm convincingly outperforms dual coordinate descent in all cases. 4 Comparing the scalability of screening and working set methods This section compares the scalability of our working set and screening approaches. We consider two popular instances of (P): group lasso and linear SVMs. For each problem, we examine the performance of our working set algorithm and screening rule as m increases. This is an important comparison, as we have not seen such scalability experiments in prior works on screening. We implemented dual coordinate ascent (DCA) to solve each instance of (P). DCA is known to be simple and fast, and there are no parameters to tune. We compare DCA to three alternatives: 1. DCA + screening: After every five DCA epochs we apply screening. “Piecewise screening” refers to Theorem 3.4. For group lasso, we also implement “gap screening” [7]. 2. DCA + working sets: Implementation of Algorithm 1. DCA is used to solve each subproblem. 3. DCA + working sets + screening: Algorithm 1 with Theorem 3.4 applied after each iteration. Group lasso comparisons We define the group lasso objective as gGL(ω) := 1 2 ∥Aω −b∥2 + λ Pm i=1 ∥ωGi∥2 . A ∈Rn×q is a design matrix, and b ∈Rn is a labels vector. λ > 0 is a regularization parameter, and G1, . . . , Gm are disjoint sets of feature indices such that ∪m i=1Gi = [q]. Denote a minimizer of gGL by ω⋆. For large λ, groups of elements, ω⋆ Gi, have value 0 for many Gi. While gGL is not directly an instance of (P), the dual of gGL is strongly concave with m constraints (and thus an instance of (P)). We consider an instance of gGL to perform feature selection for an insurance claim prediction task1. Given n = 250,000 training instances, we learned an ensemble of 1600 decision trees. To make predictions more efficiently, we use group lasso to reduce the number of trees in the model. The resulting problem has m = 1600 groups and q = 28,733 features. To evaluate the dependence of the algorithms on m, we form smaller problems by uniformly subsampling 100 and 400 groups. For each problem we set λ so that exactly 5% of groups have nonzero weight in the optimal model. Figure 1 contains results of this experiment. Our metrics include the relative suboptimality of the current iterate as well as the agreement of this iterate’s nonzero groups with those of the optimal solution in terms of precision (all algorithms had high recall). This second metric is arguably more important, since the task is feature selection. Our results illustrate that while screening is marginally helpful when m is small, our working set method is more effective when scaling to large problems. 1https://www.kaggle.com/c/ClaimPredictionChallenge 7 0.00 0.05 0.10 0.15 0.20 Time (s) 10−6 10−5 10−4 10−3 10−2 10−1 (f −f ⋆)/f ⋆ 0 1 2 3 4 5 6 7 8 Time (s) 10−6 10−5 10−4 10−3 10−2 10−1 (f −f ⋆)/f ⋆ 0 10 20 30 40 50 60 Time (s) 10−6 10−5 10−4 10−3 10−2 10−1 (f −f ⋆)/f ⋆ 101 102 103 C/C0 10 20 30 40 # Epochs Fraction of examples screened 0.0 0.2 0.4 0.6 0.8 1.0 101 102 103 104 C/C0 10 20 30 40 # Epochs Fraction of examples screened 0.0 0.2 0.4 0.6 0.8 1.0 101 102 103 104 105 106 C/C0 10 20 30 40 # Epochs Fraction of examples screened 0.0 0.2 0.4 0.6 0.8 1.0 DCA + working sets + piecewise screening DCA + working wets DCA + piecewise screening DCA (a) m = 104 (b) m = 105 (c) m = 106 Figure 2: SVM convergence comparison. (above) Relative suboptimality vs. time. (below) Heat map depicting fraction of examples screened by Theorem 3.4 when used in conjunction with dual coordinate ascent. y-axis is the number of epochs completed; x-axis is the tuning parameter C. C0 is the largest value of C for which each element of the dual solution takes value C. Darker regions indicate more successful screening. The vertical line indicates the choice of C that minimizes validation loss—this is also the choice of C for the above plots. As the number of examples increases, screening becomes progressively less effective near the desirable choice of C. SVM comparisons We define the linear SVM objective as fSVM(x) := 1 2 ∥x∥2 + C Pm i=1(1 −bi ⟨ai, x⟩)+ . Here C is a tuning parameter, while ai ∈Rn, bi ∈{−1, +1} represents the ith training instance. We train an SVM model on the Higgs boson dataset2. This dataset was generated by a team of particle physicists. The classification task is to determine whether an event corresponds to the Higgs boson. In order to learn an accurate model, we performed feature engineering on this dataset, resulting in 8010 features. In this experiment, we consider subsets of examples with size m = 104, 105, and 106. Results of this experiment are shown in Figure 2. For this problem, we plot the relative suboptimality in terms of objective value. We also include a heat map that shows screening’s effectiveness for different values of C. Similar to the group lasso results, the utility of screening decreases as m increases. Meanwhile, working sets significantly improve convergence times, regardless of m. 5 Discussion Starting from a broadly applicable problem formulation, we have derived principled and unified methods for exploiting piecewise structure in convex optimization. In particular, we have introduced a versatile working set algorithm along with a theoretical understanding of the progress this algorithm makes with each iteration. Using the same analysis, we have also proposed a screening rule that improves upon many prior screening results as well as enables screening for many new objectives. Our empirical results highlight a significant disadvantage of using screening: unless a good approximate solution is already known, screening is often ineffective. This is perhaps understandable, since screening rules operate under the constraint that erroneous simplifications are forbidden. Working set algorithms are not subject to this constraint. Instead, working set algorithms achieve fast convergence times by aggressively simplifying the objective function, correcting for mistakes only as needed. 2https://archive.ics.uci.edu/ml/datasets/HIGGS 8 Acknowledgments We thank Hyunsu Cho, Christopher Aicher, and Tianqi Chen for their helpful feedback as well as assistance preparing datasets used in our experiments. This work is supported in part by PECASE N00014-13-1-0023, NSF IIS-1258741, and the TerraSwarm Research Center 00008169. References [1] L. E. Ghaoui, V. Viallon, and T. Rabbani. Safe feature elimination for the lasso and sparse supervised learning problems. Pacific Journal of Optimization, 8(4):667–698, 2012. [2] Z. J. Xiang and P. J. Ramadge. Fast lasso screening tests based on correlations. In IEEE International Conference on Acoustics, Speech, and Signal Processing, 2012. [3] R. Tibshirani, J. Bien, J. Friedman, T. Hastie, N. Simon, J. Taylor, and R. J. Tibshirani. Strong rules for discarding predictors in lasso-type problems. Journal of the Royal Statistical Society, Series B, 74(2):245–266, 2012. [4] J. Liu, Z. Zhao, J. Wang, and J. Ye. Safe screening with variational inequalities and its application to lasso. In International Conference on Machine Learning, 2014. [5] J. Wang, P. Wonka, and J. Ye. Lasso screening rules via dual polytope projection. Journal of Machine Learning Research, 16(May):1063–1101, 2015. [6] O. Fercoq, A. Gramfort, and J. Salmon. Mind the duality gap: safer rules for the lasso. In International Conference on Machine Learning, 2015. [7] E. Ndiaye, O. Fercoq, A. Gramfort, and J. Salmon. GAP safe screening rules for sparse multi-task and multi-class models. In Advances in Neural Information Processing Systems 28, 2015. [8] E. Ndiaye, O. Fercoq, A. Gramfort, and J. Salmon. Gap safe screening rules for sparse-group lasso. Technical Report arXiv:1602.06225, 2016. [9] I. Takeuchi K. Ogawa, Y. Suzuki. Safe screening of non-support vectors in pathwise SVM computation. In International Conference on Machine Learning, 2013. [10] J. Wang, P. Wonka, and J. Ye. Scaling SVM and least absolute deviations via exact data reduction. In International Conference on Machine Learning, 2014. [11] T. B. Johnson and C. Guestrin. Blitz: a principled meta-algorithm for scaling sparse optimization. In International Conference on Machine Learning, 2015. [12] R.-E. Fan, K.-W. Chang, C.-J. Hsieh, X.-R. Wang, and C.-J. Lin. LIBLINEAR: A library for large linear classification. Journal of Machine Learning Research, 9:1871–1874, 2008. [13] F. Bach, R. Jenatton, J. Mairal, and G. Obozinski. Optimization with sparsity-inducing penalties. Foundations and Trends in Machine Learning, 4(1):1–106, 2012. 9 | 2016 | 466 |
6,401 | Large-Scale Price Optimization via Network Flow Shinji Ito NEC Corporation s-ito@me.jp.nec.com Ryohei Fujimaki NEC Corporation rfujimaki@nec-labs.com Abstract This paper deals with price optimization, which is to find the best pricing strategy that maximizes revenue or profit, on the basis of demand forecasting models. Though recent advances in regression technologies have made it possible to reveal price-demand relationship of a large number of products, most existing price optimization methods, such as mixed integer programming formulation, cannot handle tens or hundreds of products because of their high computational costs. To cope with this problem, this paper proposes a novel approach based on network flow algorithms. We reveal a connection between supermodularity of the revenue and cross elasticity of demand. On the basis of this connection, we propose an efficient algorithm that employs network flow algorithms. The proposed algorithm can handle hundreds or thousands of products, and returns an exact optimal solution under an assumption regarding cross elasticity of demand. Even if the assumption does not hold, the proposed algorithm can efficiently find approximate solutions as good as other state-of-the-art methods, as empirical results show. 1 Introduction Price optimization is a central research topic with respect to revenue management in marketing science [10, 16, 18]. The goal is to find the best price strategy (a set of prices for multiple products) that maximizes revenue or profit. There is a lot of literature regarding price optimization [1, 5, 10, 13, 17, 18, 20], and significant success has been achieved in industries such as online retail [7], fast-fashion [5], hotels [13, 14], and airlines [16]. One key component in price optimization is demand modeling, which reveals relationships between price and demand. Though traditional studies have focused more on a single price-demand relationship, such as price elasticity of demand [13, 14] and the law of diminishing marginal utility [16], multi-product relationships such as cross price elasticity of demand [15] have recently received increased attention [5, 17]. Recent advances in regression technologies (non-linear, sparse, etc.) make demand modeling over tens or even hundreds of products possible, and data oriented demand modeling has become more and more important. Given demand models of multiple products, the role of optimization is to find the best price strategy. Most existing studies for multi-product price optimization employ mixed-integer programming [5, 13, 14] due to the discrete nature of individual prices, but their methods cannot be applied to large scale problems with tens or hundreds of products since their computational costs exponentially increases over increasing numbers of products. Though restricting demand models might make optimization problems tractable [5, 7], such approaches cannot capture complicated price-demand relationships and often result in poor performance. Ito and Fujimaki [9] have recently proposed a prescriptive price optimization framework to efficiently solve multi-product price optimization with non-linear demand models. In this prescriptive price optimization, the problem is transformed into a sort of binary quadratic programming problem, and they have proposed an efficient relaxation method based on semi-definite programming (SDP). Although their approach has significantly improved computational efficiency over that of mixed-integer approaches, the computational complexity of their SDP formulation requires O(M 6) in theory, where M is the number of products, and it is not 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. sufficiently scalable for large scale problems with hundreds of products, as our empirical evaluation show in Section 5. The goal of this paper is to develop an efficient algorithm for large scale multi-product price optimization problems that can handle hundreds of products as well as flexible demand models. Our main technical contributions are two-fold. First, we reveal the connection between submodularity of the revenue and cross elasticity of demand. More specifically, we show that the gross profit function of the prescriptive price optimization is supermodular (i.e., the maximization of the gross profit function is equivalent to the submodular minimization) under the assumption regarding cross elasticity of demand that there are no pairs of complementary goods (we refer to this property as a substitute-goods property).1 On the basis of the submodularity, we propose a practical, efficient algorithm that employs network flow algorithms for minimum cut problems and returns exact solutions for problems with the substitute-goods property. Further, even in cases in which the property does not hold, it can efficiently find approximate solutions by iteratively improving submodular lower bounds. Our empirical results show that the proposed algorithm can successfully handle hundreds of products and derive solutions as good as other state-of-the-art methods, while its computational cost is much cheaper, regardless of whether the substitute-goods property holds or not. 2 Literature review Our price optimization problems are reduced to binary quadratic problems such as (4). It is well known that submodular binary quadratic programming problems can be reduced to minimum cut problems [12], and hence it can be solved by maximum flow algorithms. Also for unconstrained nonsubmodular binary quadratic programming problems, there is a lot of literature regarding optimization algorithm using minimum cut, especially in the context of Markov random fields inference or energy minimization in computer vision [2, 3, 4, 8, 11, 22]. Above all, QPBO method [2, 11] and its extensions such as QPBOI method [19] are known to be state-of-the-art methods in terms of scalability and theoretical properties. These QPBO/QPBOI and our method are similar in that they all employ network flow algorithms and derive not only partial/approximate solutions but also lower bounds of the exact optimal (minimum) value. Our methods, however, differs from QPBO and its extensions in network structures, accuracy and scalability, as is shown in Section 5. 3 Price optimization and submodularity in cross elasticity of demand Suppose we have M products and a product index is denoted by i ∈{1, . . . , M}. In prescriptive price optimization [9], for a price strategy p = [p1, . . . , pM]⊤, where pi is the price of the i-th product, and for external variables r = [r1, . . . , rD]⊤such as weather, temperature and days of the week, the sales quantity (demand) for the i-th product is modeled by the following regression formula: qi(p, r) = M X j=1 fij(pj) + D X t=1 git(rt), (1) where fii expresses the effect of price elasticity of demand, fij (i ̸= j) reflects the effect of cross elasticity, and git represent how the t-th external variable affect the sales quantity. Note that fij for all (i, j) can be arbitrary functions, and Eq. (1) covers various regression (demand) models, such as linear regression, additive models [21], linear regression models with univariate basis functions, etc. This paper assumes that the regression models are given using existing methods and focuses its discussion on optimization. Given qi(p) for all i and a cost vector c = [c1, . . . , cM]⊤, and fixed external variables r, the gross profit can be represented as ℓ(p) = M X i=1 (pi −ci)qi(p) = M X i=1 (pi −ci) M X j=1 fij(pj) + D X t=1 git(rt) . (2) 1"Complementary goods" and "substitute goods" are terms in economics. A good example of complementary goods might be wine and cheese, i.e., if we discount wine, the sales of cheese will increase. An example of substitute goods might be products of different brands in the same product category. If we discount one product, sales of the other products will decrease. 2 The goal of price optimization is to find p maximizing ℓ(p). In practice, pm is often chosen from the finite set Pi = {Pi1, . . . , PiK} ⊆R of K price candidates, where PiK might be a list price and Pik (k < K) might be discounted prices such as 10%-off, 5%-off, 3%-off. Then, the problem of maximizing the gross profit can be formulated as the following combinatorial optimization problem: Maximize ℓ(p) subject to pi ∈Pi. (3) It is trivial to show that (3) is NP-hard in general. Let us formally define the "substitute-goods property" as follows. Definition 1 (Substitute-Goods Property). The demand model defined by (1) of the i-th product is said to satisfy the substitute-goods property if fij is monotone non-decreasing for all j ̸= i. The concept of substitute-goods property is practical and important because retailers often deal with substitute goods. Suppose the situation that a retailer decides a price strategy of different brand in the same products category. For example, supermarkets sell milk of different brands and car dealerships sell various types of cars. These products are usually substitute goods. This kind of cross elasticity effect is one of advanced topics in revenue management and is practically important [13, 14, 17]. Our key observation is the connection between the substitute-goods property in marketing science and the supermodularity of the gross profit function, which is formally described in the following proposition. Proposition 2. The gross profit function ℓ: P1 ×· · ·×PM →R is supermodular2 if demand models defined by (1) for all products satisfies the substitute-goods property. The above proposition implies that, under the assumption of the substitute-goods property, problem (3) can be solved precisely using submodular minimization algorithms, where time complexity is a polynomial in M and K. This fact, however, does not necessarily imply that there exists a practical, efficient algorithm for problem (3). Indeed, general submodular minimization algorithms are slow in practice even though their time complexities are polynomial. Further, actual models do not always satisfy the substitute-goods property. We propose solutions to these problems in the next section. 4 Network flow-based algorithm for revenue maximization 4.1 Binary quadratic programming formulation This section shows that problem (3) can be reduced to the following binary quadratic programming problem (notations are explained in the latter part of this section): Minimize x⊤Ax + b⊤x subject to x = [x1, . . . , xn]⊤∈{0, 1}n, xu ≤xv ((u, v) ∈C), (4) Each variable pi takes Pik if and only if the binary vector xi = [xi1, . . . , xi,K−1]⊤∈{0, 1}(K−1) satisfies: xi = ck := [1, . . . , 1 | {z } k−1 , 0, . . . , 0 | {z } K−k ]⊤ (k = 1, . . . , K). (5) Also we define x = [x⊤ 1 , . . . , x⊤ M]⊤∈{0, 1}(K−1)M and redefine the indices of the entries of x as x = [x1, x2, . . . , x(K−1)M], i.e. xi,k = xi(K−1)+k for notational simplicity. Defining ℓij : Pi × Pj →R by ℓij(pi, pj) = (pi −ci)fij(pj) for i ̸= j and ℓi : Pi →R by ℓi(pi) = (pi −ci)(fii(pi) + PD t=1 git(rt)), we can express ℓas ℓ(p) = X 1≤i,j≤M,i̸=j ℓij(pi, pj) + M X i=1 ℓi(pi). (6) 2We say that a function f : D1 × · · · × Dn →R (Dj ⊆R) is submodular if f(x) + f(y) ≤f(x ∨y) + f(x ∧y) for all x, y, where x ∨y and x ∧y denote the coordinate-wise maximum and minimum, respectively. We say a function f is supermodular if −f is submodular. 3 Algorithm 1 s-t cut for price optimization with the substitute-goods property Input: Problem instance (A, b, C) of (4), where all entries of A are non-positive. Output: An optimal solution x∗to (4). 1: Construct a weighted directed graph G = (V, E, w) satisfying (9). 2: Add edges C with weight ∞to G, i.e., set E ←E ∪C and w(u, v) ←∞for all (u, v) ∈C. 3: Compute a minimum s-t cut U ∗of G, define x∗by (10) and return x∗. Using xi, we can construct matrices Aij ∈R(K−1)×(K−1) for which it holds that ℓij(pi, pj) = −x⊤ i Aijxj + const. (7) Indeed, matrices Aij = [aij uv]1≤u,v≤K−1 ∈R(K−1)×(K−1) defined by aij uv = −ℓij(Pi,u+1, Pj,v+1) + ℓij(Pi,u, Pj,v+1) + ℓij(Pi,u+1, Pj,v) −ℓij(Pi,u, Pj,v) (8) satisfy (7). In a similar way, we can construct bi ∈RK−1 such that ℓi(pi) = −b⊤ i xi + const. Accordingly, the objective function ℓof problem (3) satisfies ℓ(p) = −(x⊤Ax + b⊤x) + const, where we define A = [Aij]1≤i,j≤M ∈R(K−1)M×(K−1)M and b = [bi]1≤i≤M ∈R(K−1)M. The conditions xi ∈{c1, . . . , cK} (i = 1, . . . , M) can be expressed as xu ≤xv ((u, v) ∈C), where we define C := {((K −1)(i −1) + k + 1, (K −1)(i −1) + k) | 1 ≤i ≤M, 1 ≤k ≤ K −2}. Consequently, problem (3) is reduced to problem (4). Although [9] also gives another BQP formulation for the problem (3) and relaxes it to a semi-definite programming problem, our construction of the BQP problem can be solved much more efficiently, as is explained in the next section. 4.2 Minimum cut for problems with substitute goods property As is easily seen from (8), if the problem satisfies the substitute-goods property, matrix A has only non-positive entries. It is well known that unconstrained binary quadratic programming problems such as (4) with non-positive A ∈Rn×n and C = ∅can be efficiently solved3 by algorithms for minimum cut [6]. Indeed, we can construct a positive weighted directed graph, G = (V = {s, t, 1, 2, . . . , n}, E ⊆V × V, w : E →R>0 ∪{∞})4 for which x⊤Ax + b⊤x = cG({s} ∪{u | xu = 1}) + const (9) holds for all x ∈{0, 1}n, where cG is the cut function of graph G5. Hence, once we can compute a minimum s-t cut U that is a vertex set U ⊆V minimizing cG(U) subject to s ∈U and t /∈U, we can construct an optimal solution x = [x1, . . . , xn]⊤to the problem (4) by setting xu = 1 (u ∈U) 0 (u /∈U) (u = 1, . . . , n). (10) For constrained problems such as (4) with C ̸= ∅, the constraint xu ≤xv is equivalent to xu = 1 =⇒xv = 1. This condition can be, in the minimum cut problem, expressed as u ∈U =⇒v ∈U. By adding a directed edge (u, v) with weight ∞, we can forbid the minimum cut to violate the constraints. In fact, if both u ∈U and v /∈U hold, the value of the cut function is ∞, and hence such a U cannot be a minimum cut. We summarize this in Algorithm 1. 4.3 Submodular relaxation for problems without the substitute-goods property For problems without the substitute-goods property, we first decompose the matrix A into A+ and A−so that A+ + A−= A, where A+ = [a+ uv] and A−= [a− uv] ∈Rn×n are given by a+ uv = auv (auv ≥0) 0 (auv < 0) , a− uv = 0 (auv ≥0) auv (auv < 0) (u, v ∈N). (11) 3The computational cost of the minimum cut depends on the choice of algorithms. For example, if we use Dinic’s method, the time complexity is O(n3 log n) = O((KM)3 log(KM)). 4 s, t are auxiliary vertices different from 1, . . . , n corresponding to source, sink in maximum flow problems. 5 For details about the construction of G, see, e.g., [4, 12]. 4 This leads to a decomposition of the objective function of Problem (4) into supermodular and submodular terms: x⊤Ax + b⊤x = x⊤A+x + x⊤A−x + b⊤x, (12) where x⊤A+x is supermodular and x⊤A−x + b⊤x is submodular. Our approach is to replace the supermodular term x⊤A+x by a linear function to construct a submodular function approximating x⊤Ax+b⊤x, that can be minimized by Algorithm 1. Similar approaches can be found in the literature, e.g. [8, 22], but ours has a significant point of difference; our method constructs approximate functions bounding objectives from below, which provides information about the degree of accuracy. Consider an affine function h(x) such that h(x) ≤x⊤A+x for all x ∈{0, 1}n. Such an h can be constructed as follows. Since γuv(xu + xv −1) ≤xuxv (xu, xv ∈{0, 1}) (13) holds for all γuv ∈[0, 1], an arbitrary matrix Γ ∈[0, 1]n×n satisfies x⊤A+x ≥x⊤(A+ ◦Γ)1 + 1⊤(A+ ◦Γ)x −1⊤(A+ ◦Γ)1 =: hΓ(x), (14) where A+ ◦Γ denotes the Hadamard product, i.e., (A+ ◦Γ)uv = a+ uv · γuv. From inequality (14), the optimal value of the following problem, Minimize x⊤A−x + b⊤x + hΓ(x) subject to x = [x1, . . . , xn]⊤∈{0, 1}n, xu ≤xv ((u, v) ∈C), (15) is a lower bound for that of problem (4). Since A−has non-positive entries and b⊤x + hΓ(x) is affine, we can solve (15) using Algorithm 1 to obtain an approximate solution for (4) and a lower bound for the optimal value of (4). 4.4 Proximal gradient method with sequential submodular relaxation An essential problem in submodular relaxation is how to choose Γ ∈[0, 1]n×n and to optimize x given Γ. Let ψ(Γ) denote the optimal value of (15), i.e., define ψ(Γ) by ψ(Γ) = minx∈R x⊤A−x + b⊤x + hΓ(x), where R is the feasible region of (15). Then, for simultaneous optimization of x and Γ, we consider the following problem: Maximize ψ(Γ) subject to Γ ∈[0, 1]n×n, (16) which can be rewritten as follows:6 Minimize −ψ(Γ) + Ω(Γ) subject to Γ ∈Rn×n, (17) where we define Ω: Rn×n →R ∪{∞} by Ω(Γ) = 0 (Γ ∈[0, 1]n×n) ∞ (Γ /∈[0, 1]n×n) . (18) Then, −ψ(Γ) is convex and (17) can be solved using a proximal gradient method. Let Γt ∈Rn×n denote the solution on the t-th step. Let xt be the optimal solution of (15) with Γ = Γt, i.e., xt ∈arg min x∈R{x⊤A−x + b⊤x + hΓt(x)}. (19) The partial derivative of −hΓ(x) w.r.t. Γ at (Γt, xt), denoted by St, is then a subgradient of −ψ(Γ) at Γt, which can be computed as follows: St = A+ ◦(11⊤−xt1⊤−1x⊤ t ) (20) 6Problem (16) can be also solved using the ellipsoid method, which guarantees polynomial time-complexity in the input size. However, it is known that the order of its polynomial is large and that the performance of the algorithm can be poor in practice, especially for large size problems. To try to achieve more practical performance, this paper proposes a proximal gradient algorithm. 5 Algorithm 2 An iterative relaxation algorithm for (4) Input: Problem instance (A, b, C) of (4). Output: An approximate solution ˆx to (4) satisfying (25), a lower bound ψ of optimal value of (4). 1: Set Γ1 = 11⊤/2, t = 1, min_value = ∞, ψ = −∞. 2: while Not converged do 3: Compute xt satisfying (19) by using Algorithm 1, and compute valuet = x⊤ t Axt + b⊤xt, ψt = x⊤ t A−xt + b⊤xt + hΓt(xt), ψ = max{ψ, ψt} 4: if valuet < max_value then 5: Update value and ˆx by min_value = valuet, ˆx = xt. (24) 6: end if 7: Compute Γt+1 by (22) and (23). 8: end while 9: Return ˆx, min_value and ψ. By using St and a decreasing sequence {ηt} of positive real numbers, we can express the update scheme for the proximal gradient method as follows: Γt+1 ∈arg min Γ∈Rn×n{St · Γ + 1 2ηt ∥Γ −Γt∥2 + Ω(Γ)}, (21) We can compute Γt+1 satisfying (21) by Γt+1 = Proj[0,1]n×n(Γt −ηtSt), (22) where Proj[0,1](X) is defined by (Proj[0,1](X))uv = ( 0 ((X)uv < 0) 1 ((X)uv > 1) (X)uv (otherwise) . (23) The proposed algorithm can be summarized as Algorithm 2. The choice of {ηt} has a major impact on the rate of the convergence of the algorithm. From a convergence analysis of the proximal gradient method, when we set ηt = Θ(1/ √ t), it is guaranteed that ψt converge to the optimal value ψ∗of (16) and |ψt −ψ∗| = O(1/ √ t). Because ψ(Γ) is non-smooth and not strongly concave, there is no better guarantee of convergence rate, to the best of our knowledge. In practice, however, we can observe the convergence in ∼10 steps iteration. 4.5 Initialization of Γ Let ˜xΓ denote an optimal solution to (15). We employ Γ1 = 1/211⊤for the initialization of Γ because (xu + xu −1)/2 is the tightest lower bound of xuxv in the max-norm sense, i.e., h(xu, xv) = (xu + xv −1)/2 is the unique minimizer of maxxu,xv∈{0,1}{|xuxv −h(xu, xv)|}, subject to the constraints that h(xu, xv) is affine and bounded from above by xuxv. In this case, ˜xΓ is an approximate solution satisfying the following performance guarantee. Proposition 3. If Γ = 11⊤/2, then ˜xΓ satisfies ˜x⊤ Γ A˜xΓ + b⊤˜xΓ ≤x⊤ ∗Ax∗+ b⊤x∗+ 1 21⊤A+1, (25) where x∗is an optimal solution to (4). 5 Experiments 5.1 Simulations This section investigates behavior of Algorithm 2 on the basis of the simulation model used in [9], and we compare the proposed method with state-of-the-art methods: the SDP relaxation method [9] 6 Table 1: Ranges of parameters in regression models. (i) is supermodular, (ii) is supermodular + submodular, and (iii) is submodular. βij (i ̸= j) βii αi (i) [0, 2] [−2M, −M] [M, 3M] (ii) [−25, 25] [−2M, 0] [M, 3M] (iii) [−2, 0] [M −3, M −1] [1, 3] Table 2: Results on real retail data. (a) is computational time, (b) is estimated gross profit, (c) is upper bound. actual proposed QPBO (a) 36[s] 964[s] (b) 1403700 1883252 1245568 (c) 1897393 1894555 and the QPBO and QBPOI methods [11]. We use SDPA 7.3.8 to solve SDP problems7 and use the implementation of QPBO and QPBOI written by Kolmogolov.8 QPBO methods computes partial labeling, i.e., there might remain unlabeled variables, and we set unlabeled variables to 0 in our experiments. For computing a minimum s-t cut, we use Dinic’s algorithm [6]. All experiments were conducted in a machine equipped with Intel(R) Xeon(R) CPU E5-2699 v3 @ 2.30GHz, 768GB RAM. We limited all processes to a single CPU core. Revenue simulation model [9] The sales quantity qi of the i-th product was generated from the regression model qi = αi + PM j=1 βijpj, where {αi} and {βij} were generated by uniform distributions. We considered three types of uniform distributions to investigate the effect of submodularity, as shown in Table 1, which correspond to three different situations: (i) all pairs of products are substitute goods, i.e., the gross profit function is supermodular, (ii) half pairs are substitute goods and the others are complementary goods, i.e., the gross profit function contains submodular terms and supermodular terms, and (iii) all pairs are complementary goods, i.e., the gross profit function is submodular. Price candidates Pi and cost ci for each product are fixed to Pi = {0.6, 0.7, . . . , 1.0} and ci = 0, respectively. Scalability and accuracy comparison We evaluated four methods in terms of computational time (sec) and optimization accuracy (i.e. optimal values calculated by four methods). In addition to calculating approximate optimal solutions and values, all four algorithms derive upper bounds of exact optimal value, which provide information about how accurate the calculated solution.9 Fig. 1 shows the results with M = 30, 60, . . . , 300 for situations (i),(ii) and (iii). The plotted values are arithmetic means of 5 random problem instances. We can observe that proposed, QPBO and QPBOI methods derived exact solutions in the case (i), which can be confirmed from the computed upper bounds coinciding with the values of objective function. For situations (ii) and (iii), on the other hand, the upper bound and the objective value did not coincide and the solutions by QPBO were worse than the others. The solutions by QPBOI and SDPrelax are as good as the proposed methods, but their computational costs are significantly higher especially for the situations (ii) and (iii). For all situations, the proposed method successfully derived solutions as good as the best of the four methods did, and its computational cost was the lowest. 5.2 Real-world retail data Data and settings We applied the proposed method to actual retail data from a middle-size supermarket located in Tokyo [23].10 We selected 50 regularly-sold beer products. The data range is approximately three years from 2012/01 to 2014/12, and we used the first 35 months (1065 samples) for training regression models and simulated the best price strategy for the next 20 days. Therefore, the problem here was to determine 1000 prices (50 products × 20 days). For forecasting the sales quantity q(d) i of the i-product on the d-th day, we use prices features {p(d′) j }1≤j≤50,d−19≤d′≤d of 50 products for the 20 days before the d-th day. In addition to these 1000 linear price features, we employed “day of the week" and “month" features (both binary), as well as temperature forecasting features (continuous), as external features. The price candidates 7http://sdpa.sourceforge.net/ 8http://pub.ist.ac.at/~vnk/software.html 9 For example, the coincidence of the upper bound and the calculated optimal value implies that the algorithm computed the exact optimal solution. 10The Data has been provided by KSP-SP Co., LTD, http://www.ksp-sp.com. 7 0 50 100 150 200 250 300 M: number of products 0 50 100 150 200 250 computational time [s] proposed QPBO QPBOI SDPrelax 0 50 100 150 200 250 300 M: number of products 0 50 100 150 200 250 computational time [s] proposed QPBO QPBOI SDPrelax 0 50 100 150 200 250 300 M: number of products 0 50 100 150 200 250 computational time [s] proposed QPBO QPBOI SDPrelax 0 50 100 150 200 250 300 M: number of products 0.6 0.7 0.8 0.9 1.0 1.1 1.2 value of objective function proposed QPBO QPBOI SDPrelax (i) supermodular 0 50 100 150 200 250 300 M: number of products 0.70 0.75 0.80 0.85 0.90 0.95 1.00 1.05 1.10 value of objective function proposed QPBO QPBOI SDPrelax (ii) supermodular + submodular 0 50 100 150 200 250 300 M: number of products 0.0 0.2 0.4 0.6 0.8 1.0 1.2 value of objective function proposed QPBO QPBOI SDPrelax (iii) submodular Figure 1: Comparisons of proposed, QPBO, QPBOI, and SDPrelax methods on revenue simulation data. The horizontal axis represents the number M of products. The vertical axes represent computational time (top) and optimal values of four methods (3) (bottom). For the bottom, circle markers with dashed line represent the computed upper bounds of the optimal values, and optimal values and upper bounds are normalized so that upper bounds with the proposed method are equal to 1. {P (d) ik }5 k=1 were generated by splitting equally the range [Pi1, Pi5], where Pi1 and Pi5 are the highest and lowest prices of the i-th product in the historical data. We assumed that the cost c(d) i was 0.3Pi5 (30% of the list prices). Our objective was to obtain a price strategy for 50-products over the 20 days, from the 1066-th to 1085-th, which involves 1000-dimensional variables, in order to maximize the sum of the gross profit for the 20 days. We estimated parameters in regression models, using the ridge regression method. The estimated model contained 310293 pairs with the substitute-goods property and 189207 pairs with complementary goods property. The results are summarized in Table 2, where “actual” means the gross profit computed on the basis of the historical data regarding sales quantities and prices over the 20 days, from the 1066-th to 1085-th, and costs c(d) i = 0.3Pi5. Thus, the target is to find a strategy that expectedly achieves better gross profit than “actual”. We have omitted results for QPBOI and SDPrelax here because they did not terminate after running over 8 hours. We observe that the proposed method successfully derived a price strategy over 1000 products, which can be expected to increase gross profit significantly in spite of its cheap computational cost, in contrast to QPBO, which failed with more expensive computation. Although Table 2 shows results using a single CPU core for fair comparison, the algorithm can be easily parallelized that can finish optimization in a few seconds. This makes it possible to dynamically change prices in real time or enables price managers to flexibly explore a better price strategy (changing a price range, target products, domain constraints, etc.) 6 Conclusion In this paper we dealt with price optimization based on large-scale demand forecasting models. We have shown that the gross profit function is supermodular under the assumption of the substitute-goods property. On the basis of this supermodularity, we have proposed an efficient algorithm that employs network flow algorithms and that returns exact solutions for problems with the substitute-goods property. Even in case in which the property does not hold, the proposed algorithm can efficiently find approximate solutions. Our empirical results have shown that the proposed algorithm can handle hundreds/thousands products with much cheaper computational cost than other existing methods. References [1] G. Bitran and R. Caldentey. An overview of pricing models for revenue management. Manufacturing & Service Operations Management, 5(3):203–229, 2003. 8 [2] E. Boros and P. L. Hammer. Pseudo-boolean optimization. Discrete applied mathematics, 123(1):155–225, 2002. [3] Y. Boykov and V. Kolmogorov. An experimental comparison of min-cut/max-flow algorithms for energy minimization in vision. Pattern Analysis and Machine Intelligence, IEEE Transactions on, 26(9):1124– 1137, 2004. [4] Y. Boykov, O. Veksler, and R. Zabih. Fast approximate energy minimization via graph cuts. Pattern Analysis and Machine Intelligence, IEEE Transactions on, 23(11):1222–1239, 2001. [5] F. Caro and J. Gallien. Clearance pricing optimization for a fast-fashion retailer. Operations Research, 60(6):1404–1422, 2012. [6] T. H. Cormen. Introduction to algorithms. MIT press, 2009. [7] K. J. Ferreira, B. H. A. Lee, and D. Simchi-Levi. Analytics for an online retailer: Demand forecasting and price optimization. Manufacturing & Service Operations Management, pages 69–88, 2015. [8] L. Gorelick, Y. Boykov, O. Veksler, I. Ayed, and A. Delong. Submodularization for binary pairwise energies. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pages 1154–1161, 2014. [9] S. Ito and R. Fujimaki. Optimization beyond prediction: Prescriptive price optimization. ArXiv e-prints, http://arxiv.org/abs/1605.05422, 2016. [10] R. Klein. Revenue Management. Springer, 2008. [11] V. Kolmogorov and C. Rother. Minimizing nonsubmodular functions with graph cuts-a review. Pattern Analysis and Machine Intelligence, IEEE Transactions on, 29(7):1274–1279, 2007. [12] V. Kolmogorov and R. Zabin. What energy functions can be minimized via graph cuts? Pattern Analysis and Machine Intelligence, IEEE Transactions on, 26(2):147–159, 2004. [13] D. Koushik, J. A. Higbie, and C. Eister. Retail price optimization at intercontinental hotels group. Interfaces, 42(1):45–57, 2012. [14] S. Lee. Study of demand models and price optimization performance. PhD thesis, Georgia Institute of Technology, 2011. [15] A. Marshall. Principles of Economics. Library of Economics and Liberty, 1920. [16] J. I. McGill and G. J. Van Ryzin. Revenue management: Research overview and prospects. Transportation science, 33(2):233–256, 1999. [17] M. Natter, T. Reutterer, and A. Mild. Dynamic pricing support systems for diy retailers - a case study from austria. Marketing Intelligence Review, 1:17–23, 2009. [18] R. L. Phillips. Pricing and Revenue Optimization. Stanford University Press, 2005. [19] C. Rother, V. Kolmogorov, V. Lempitsky, and M. Szummer. Optimizing binary mrfs via extended roof duality. In Computer Vision and Pattern Recognition, 2007. CVPR’07. IEEE Conference on, pages 1–8. IEEE, 2007. [20] P. Rusmevichientong, B. Van Roy, and P. W. Glynn. A nonparametric approach to multiproduct pricing. Operations Research, 54(1):82–98, 2006. [21] C. J. Stone. Additive regression and other nonparametric models. The annals of Statistics, pages 689–705, 1985. [22] M. Tang, I. B. Ayed, and Y. Boykov. Pseudo-bound optimization for binary energies. In Computer Vision–ECCV 2014, pages 691–707. Springer, 2014. [23] J. Wang, R. Fujimaki, and Y. Motohashi. Trading interpretability for accuracy: Oblique treed sparse additive models. In KDD, pages 1245–1254, 2015. 9 | 2016 | 467 |
6,402 | Generative Adversarial Imitation Learning Jonathan Ho OpenAI hoj@openai.com Stefano Ermon Stanford University ermon@cs.stanford.edu Abstract Consider learning a policy from example expert behavior, without interaction with the expert or access to a reinforcement signal. One approach is to recover the expert’s cost function with inverse reinforcement learning, then extract a policy from that cost function with reinforcement learning. This approach is indirect and can be slow. We propose a new general framework for directly extracting a policy from data as if it were obtained by reinforcement learning following inverse reinforcement learning. We show that a certain instantiation of our framework draws an analogy between imitation learning and generative adversarial networks, from which we derive a model-free imitation learning algorithm that obtains significant performance gains over existing model-free methods in imitating complex behaviors in large, high-dimensional environments. 1 Introduction We are interested in a specific setting of imitation learning—the problem of learning to perform a task from expert demonstrations—in which the learner is given only samples of trajectories from the expert, is not allowed to query the expert for more data while training, and is not provided a reinforcement signal of any kind. There are two main approaches suitable for this setting: behavioral cloning [18], which learns a policy as a supervised learning problem over state-action pairs from expert trajectories; and inverse reinforcement learning [23, 16], which finds a cost function under which the expert is uniquely optimal. Behavioral cloning, while appealingly simple, only tends to succeed with large amounts of data, due to compounding error caused by covariate shift [21, 22]. Inverse reinforcement learning (IRL), on the other hand, learns a cost function that prioritizes entire trajectories over others, so compounding error, a problem for methods that fit single-timestep decisions, is not an issue. Accordingly, IRL has succeeded in a wide range of problems, from predicting behaviors of taxi drivers [29] to planning footsteps for quadruped robots [20]. Unfortunately, many IRL algorithms are extremely expensive to run, requiring reinforcement learning in an inner loop. Scaling IRL methods to large environments has thus been the focus of much recent work [6, 13]. Fundamentally, however, IRL learns a cost function, which explains expert behavior but does not directly tell the learner how to act. Given that the learner’s true goal often is to take actions imitating the expert—indeed, many IRL algorithms are evaluated on the quality of the optimal actions of the costs they learn—why, then, must we learn a cost function, if doing so possibly incurs significant computational expense yet fails to directly yield actions? We desire an algorithm that tells us explicitly how to act by directly learning a policy. To develop such an algorithm, we begin in Section 3, where we characterize the policy given by running reinforcement learning on a cost function learned by maximum causal entropy IRL [29, 30]. Our characterization introduces a framework for directly learning policies from data, bypassing any intermediate IRL step. Then, we instantiate our framework in Sections 4 and 5 with a new model-free imitation learning algorithm. We show that our resulting algorithm is intimately connected to generative adversarial 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. networks [8], a technique from the deep learning community that has led to recent successes in modeling distributions of natural images: our algorithm harnesses generative adversarial training to fit distributions of states and actions defining expert behavior. We test our algorithm in Section 6, where we find that it outperforms competing methods by a wide margin in training policies for complex, high-dimensional physics-based control tasks over various amounts of expert data. 2 Background Preliminaries R will denote the extended real numbers R ∪{∞}. Section 3 will work with finite state and action spaces S and A, but our algorithms and experiments later in the paper will run in high-dimensional continuous environments. Π is the set of all stationary stochastic policies that take actions in A given states in S; successor states are drawn from the dynamics model P(s′|s, a). We work in the γ-discounted infinite horizon setting, and we will use an expectation with respect a policy π ∈Π to denote an expectation with respect to the trajectory it generates: Eπ[c(s, a)] ≜E [P∞ t=0 γtc(st, at)], where s0 ∼p0, at ∼π(·|st), and st+1 ∼P(·|st, at) for t ≥0. We will use ˆEτ to denote an empirical expectation with respect to trajectory samples τ, and we will always use πE to refer to the expert policy. Inverse reinforcement learning Suppose we are given an expert policy πE that we wish to rationalize with IRL. For the remainder of this paper, we will adopt and assume the existence of solutions of maximum causal entropy IRL [29, 30], which fits a cost function from a family of functions C with the optimization problem maximize c∈C min π∈Π −H(π) + Eπ[c(s, a)] −EπE[c(s, a)] (1) where H(π) ≜Eπ[−log π(a|s)] is the γ-discounted causal entropy [3] of the policy π. In practice, πE will only be provided as a set of trajectories sampled by executing πE in the environment, so the expected cost of πE in Eq. (1) is estimated using these samples. Maximum causal entropy IRL looks for a cost function c ∈C that assigns low cost to the expert policy and high cost to other policies, thereby allowing the expert policy to be found via a certain reinforcement learning procedure: RL(c) = arg min π∈Π −H(π) + Eπ[c(s, a)] (2) which maps a cost function to high-entropy policies that minimize the expected cumulative cost. 3 Characterizing the induced optimal policy To begin our search for an imitation learning algorithm that both bypasses an intermediate IRL step and is suitable for large environments, we will study policies found by reinforcement learning on costs learned by IRL on the largest possible set of cost functions C in Eq. (1): all functions RS×A = {c : S × A →R}. Using expressive cost function classes, like Gaussian processes [14] and neural networks [6], is crucial to properly explain complex expert behavior without meticulously hand-crafted features. Here, we investigate the best IRL can do with respect to expressiveness by examining its capabilities with C = RS×A. Of course, with such a large C, IRL can easily overfit when provided a finite dataset. Therefore, we will incorporate a (closed, proper) convex cost function regularizer ψ : RS×A →R into our study. Note that convexity is a not particularly restrictive requirement: ψ must be convex as a function defined on all of RS×A, not as a function defined on a small parameter space; indeed, the cost regularizers of Finn et al. [6], effective for a range of robotic manipulation tasks, satisfy this requirement. Interestingly, ψ will play a central role in our discussion and will not serve as a nuisance in our analysis. Let us define an IRL primitive procedure, which finds a cost function such that the expert performs better than all other policies, with the cost regularized by ψ: IRLψ(πE) = arg max c∈RS×A −ψ(c) + min π∈Π −H(π) + Eπ[c(s, a)] −EπE[c(s, a)] (3) 2 Let ˜c ∈IRLψ(πE). We are interested in a policy given by RL(˜c)—this is the policy given by running reinforcement learning on the output of IRL. To characterize RL(˜c), let us first define for a policy π ∈Π its occupancy measure ρπ : S × A →R as ρπ(s, a) = π(a|s) P∞ t=0 γtP(st = s|π). The occupancy measure can be interpreted as the unnormalized distribution of state-action pairs that an agent encounters when navigating the environment with the policy π, and it allows us to write Eπ[c(s, a)] = P s,a ρπ(s, a)c(s, a) for any cost function c. We will also need the concept of a convex conjugate: for a function f : RS×A →R, its convex conjugate f ∗: RS×A →R is given by f ∗(x) = supy∈RS×A xT y −f(y). Now, we are prepared to characterize RL(˜c), the policy learned by RL on the cost recovered by IRL: Proposition 3.1. RL ◦IRLψ(πE) = arg minπ∈Π −H(π) + ψ∗(ρπ −ρπE) (4) The proof of Proposition 3.1 can be found in Appendix A.1. It relies on the observation that the optimal cost function and policy form a saddle point of a certain function. IRL finds one coordinate of this saddle point, and running RL on the output of IRL reveals the other coordinate. Proposition 3.1 tells us that ψ-regularized inverse reinforcement learning, implicitly, seeks a policy whose occupancy measure is close to the expert’s, as measured by ψ∗. Enticingly, this suggests that various settings of ψ lead to various imitation learning algorithms that directly solve the optimization problem given by Proposition 3.1. We explore such algorithms in Sections 4 and 5, where we show that certain settings of ψ lead to both existing algorithms and a novel one. The special case when ψ is a constant function is particularly illuminating, so we state and show it directly using concepts from convex optimization. Proposition 3.2. Suppose ρπE > 0. If ψ is a constant function, ˜c ∈IRLψ(πE), and ˜π ∈RL(˜c), then ρ˜π = ρπE. In other words, if there were no cost regularization at all, the recovered policy will exactly match the expert’s occupancy measure. (The condition ρπE > 0, inherited from Ziebart et al. [30], simplifies our discussion and in fact guarantees the existence of ˜c ∈IRLψ(πE). Elsewhere in the paper, as mentioned in Section 2, we assume the IRL problem has a solution.) To show Proposition 3.2, we need the basic result that the set of valid occupancy measures D ≜{ρπ : π ∈Π} can be written as a feasible set of affine constraints [19]: if p0(s) is the distribution of starting states and P(s′|s, a) is the dynamics model, then D = n ρ : ρ ≥0 and P a ρ(s, a) = p0(s) + γ P s′,a P(s|s′, a)ρ(s′, a) ∀s ∈S o . Furthermore, there is a one-to-one correspondence between Π and D: Lemma 3.1 (Theorem 2 of Syed et al. [27]). If ρ ∈D, then ρ is the occupancy measure for πρ(a|s) ≜ρ(s, a)/ P a′ ρ(s, a′), and πρ is the only policy whose occupancy measure is ρ. We are therefore justified in writing πρ to denote the unique policy for an occupancy measure ρ. We also need a lemma that lets us speak about causal entropies of occupancy measures: Lemma 3.2. Let ¯H(ρ) = −P s,a ρ(s, a) log(ρ(s, a)/ P a′ ρ(s, a′)). Then, ¯H is strictly concave, and for all π ∈Π and ρ ∈D, we have H(π) = ¯H(ρπ) and ¯H(ρ) = H(πρ). The proof of this lemma is in Appendix A.1. Lemma 3.1 and Lemma 3.2 together allow us to freely switch between policies and occupancy measures when considering functions involving causal entropy and expected costs, as in the following lemma: Lemma 3.3. If L(π, c) = −H(π) + Eπ[c(s, a)] and ¯L(ρ, c) = −¯H(ρ) + P s,a ρ(s, a)c(s, a), then, for all cost functions c, L(π, c) = ¯L(ρπ, c) for all policies π ∈Π, and ¯L(ρ, c) = L(πρ, c) for all occupancy measures ρ ∈D. Now, we are ready to verify Proposition 3.2. Proof of Proposition 3.2. Define ¯L(ρ, c) = −¯H(ρ) + P s,a c(s, a)(ρ(s, a) −ρE(s, a)). Given that ψ is a constant function, we have the following, due to Lemma 3.3: ˜c ∈IRLψ(πE) = arg max c∈RS×A min π∈Π −H(π) + Eπ[c(s, a)] −EπE[c(s, a)] + const. (5) = arg max c∈RS×A min ρ∈D −¯H(ρ) + X s,a ρ(s, a)c(s, a) − X s,a ρE(s, a)c(s, a) = arg max c∈RS×A min ρ∈D ¯L(ρ, c). (6) 3 This is the dual of the optimization problem minimize ρ∈D −¯H(ρ) subject to ρ(s, a) = ρE(s, a) ∀s ∈S, a ∈A (7) with Lagrangian ¯L, for which the costs c(s, a) serve as dual variables for equality constraints. Thus, ˜c is a dual optimum for (7). In addition, strong duality holds for (7): D is compact and convex, −¯H is convex, and, since ρE > 0, there exists a feasible point in the relative interior of the domain D. Moreover, Lemma 3.2 guarantees that −¯H is in fact strictly convex, so the primal optimum can be uniquely recovered from the dual optimum [4, Section 5.5.5] via ˜ρ = arg minρ∈D ¯L(ρ, ˜c) = arg minρ∈D −¯H(ρ) + P s,a ˜c(s, a)ρ(s, a) = ρE, where the first equality indicates that ˜ρ is the unique minimizer of ¯L(·, ˜c), and the third follows from the constraints in the primal problem (7). But if ˜π ∈RL(˜c), then Lemma 3.3 implies ρ˜π = ˜ρ = ρE. Let us summarize our conclusions. First, IRL is a dual of an occupancy measure matching problem, and the recovered cost function is the dual optimum. Classic IRL algorithms that solve reinforcement learning repeatedly in an inner loop, such as the algorithm of Ziebart et al. [29] that runs a variant of value iteration in an inner loop, can be interpreted as a form of dual ascent, in which one repeatedly solves the primal problem (reinforcement learning) with fixed dual values (costs). Dual ascent is effective if solving the unconstrained primal is efficient, but in the case of IRL, it amounts to reinforcement learning! Second, the induced optimal policy is the primal optimum. The induced optimal policy is obtained by running RL after IRL, which is exactly the act of recovering the primal optimum from the dual optimum; that is, optimizing the Lagrangian with the dual variables fixed at the dual optimum values. Strong duality implies that this induced optimal policy is indeed the primal optimum, and therefore matches occupancy measures with the expert. IRL is traditionally defined as the act of finding a cost function such that the expert policy is uniquely optimal, but we can alternatively view IRL as a procedure that tries to induce a policy that matches the expert’s occupancy measure. 4 Practical occupancy measure matching We saw in Proposition 3.2 that if ψ is constant, the resulting primal problem (7) simply matches occupancy measures with expert at all states and actions. Such an algorithm is not practically useful. In reality, the expert trajectory distribution will be provided only as a finite set of samples, so in large environments, most of the expert’s occupancy measure values will be small, and exact occupancy measure matching will force the learned policy to rarely visit these unseen state-action pairs simply due to lack of data. Furthermore, in the cases in which we would like to use function approximation to learn parameterized policies πθ, the resulting optimization problem of finding an appropriate θ would have an intractably large number of constraints when the environment is large: as many constraints as points in S × A. Keeping in mind that we wish to eventually develop an imitation learning algorithm suitable for large environments, we would like to relax Eq. (7) into the following form, motivated by Proposition 3.1: minimize π dψ(ρπ, ρE) −H(π) (8) by modifying the IRL regularizer ψ so that dψ(ρπ, ρE) ≜ψ∗(ρπ −ρE) smoothly penalizes violations in difference between the occupancy measures. Entropy-regularized apprenticeship learning It turns out that with certain settings of ψ, Eq. (8) takes on the form of regularized variants of existing apprenticeship learning algorithms, which indeed do scale to large environments with parameterized policies [10]. For a class of cost functions C ⊂RS×A, an apprenticeship learning algorithm finds a policy that performs better than the expert across C, by optimizing the objective minimize π max c∈C Eπ[c(s, a)] −EπE[c(s, a)] (9) Classic apprenticeship learning algorithms restrict C to convex sets given by linear combinations of basis functions f1, . . . , fd, which give rise a feature vector f(s, a) = [f1(s, a), . . . , fd(s, a)] for each state-action pair. Abbeel and Ng [1] and Syed et al. [27] use, respectively, Clinear = {P iwifi : ∥w∥2 ≤1} and Cconvex = {P iwifi : P iwi = 1, wi ≥0 ∀i} . (10) 4 Clinear leads to feature expectation matching [1], which minimizes ℓ2 distance between expected feature vectors: maxc∈Clinear Eπ[c(s, a)]−EπE[c(s, a)] = ∥Eπ[f(s, a)]−EπE[f(s, a)]∥2. Meanwhile, Cconvex leads to MWAL [26] and LPAL [27], which minimize worst-case excess cost among the individual basis functions, as maxc∈Cconvex Eπ[c(s, a)] −EπE[c(s, a)] = maxi∈{1,...,d} Eπ[fi(s, a)] − EπE[fi(s, a)]. We now show how Eq. (9) is a special case of Eq. (8) with a certain setting of ψ. With the indicator function δC : RS×A →R, defined by δC(c) = 0 if c ∈C and +∞otherwise, we can write the apprenticeship learning objective (9) as max c∈C Eπ[c(s, a)]−EπE[c(s, a)] = max c∈RS×A−δC(c) + X s,a (ρπ(s, a)−ρπE(s, a))c(s, a) = δ∗ C(ρπ−ρπE) Therefore, we see that entropy-regularized apprenticeship learning minimize π −H(π) + max c∈C Eπ[c(s, a)] −EπE[c(s, a)] (11) is equivalent to performing RL following IRL with cost regularizer ψ = δC, which forces the implicit IRL procedure to recover a cost function lying in C. Note that we can scale the policy’s entropy regularization strength in Eq. (11) by scaling C by a constant α as {αc : c ∈C}, recovering the original apprenticeship objective (9) by taking α →∞. Cons of apprenticeship learning It is known that apprenticeship learning algorithms generally do not recover expert-like policies if C is too restrictive [27, Section 1]—which is often the case for the linear subspaces used by feature expectation matching, MWAL, and LPAL, unless the basis functions f1, . . . , fd are very carefully designed. Intuitively, unless the true expert cost function (assuming it exists) lies in C, there is no guarantee that if π performs better than πE on all of C, then π equals πE. With the aforementioned insight based on Proposition 3.1 that apprenticeship learning is equivalent to RL following IRL, we can understand exactly why apprenticeship learning may fail to imitate: it forces πE to be encoded as an element of C. If C does not include a cost function that explains expert behavior well, then attempting to recover a policy from such an encoding will not succeed. Pros of apprenticeship learning While restrictive cost classes C may not lead to exact imitation, apprenticeship learning with such C can scale to large state and action spaces with policy function approximation. Ho et al. [10] rely on the following policy gradient formula for the apprenticeship objective (9) for a parameterized policy πθ: ∇θ max c∈C Eπθ[c(s, a)] −EπE[c(s, a)] = ∇θEπθ[c∗(s, a)] = Eπθ [∇θ log πθ(a|s)Qc∗(s, a)] where c∗= arg max c∈C Eπθ[c(s, a)] −EπE[c(s, a)], Qc∗(¯s, ¯a) = Eπθ[c∗(¯s, ¯a) | s0 = ¯s, a0 = ¯a] (12) Observing that Eq. (12) is the policy gradient for a reinforcement learning objective with cost c∗, Ho et al. propose an algorithm that alternates between two steps: 1. Sample trajectories of the current policy πθi by simulating in the environment, and fit a cost function c∗ i , as defined in Eq. (12). For the cost classes Clinear and Cconvex (10), this cost fitting amounts to evaluating simple analytical expressions [10]. 2. Form a gradient estimate with Eq. (12) with c∗ i and the sampled trajectories, and take a trust region policy optimization (TRPO) [24] step to produce πθi+1. This algorithm relies crucially on the TRPO policy step, which is a natural gradient step constrained to ensure that πθi+1 does not stray too far πθi, as measured by KL divergence between the two policies averaged over the states in the sampled trajectories. This carefully constructed step scheme ensures that the algorithm does not diverge due to high noise in estimating the gradient (12). We refer the reader to Schulman et al. [24] for more details on TRPO. With the TRPO step scheme, Ho et al. were able train large neural network policies for apprenticeship learning with linear cost function classes (10) in environments with hundreds of observation dimensions. Their use of these linear cost function classes, however, limits their approach to settings in which expert behavior is well-described by such classes. We will draw upon their algorithm to develop an imitation learning method that both scales to large environments and imitates arbitrarily complex expert behavior. To do so, we first turn to proposing a new regularizer ψ that wields more expressive power than the regularizers corresponding to Clinear and Cconvex (10). 5 5 Generative adversarial imitation learning As discussed in Section 4, the constant regularizer leads to an imitation learning algorithm that exactly matches occupancy measures, but is intractable in large environments. The indicator regularizers for the linear cost function classes (10), on the other hand, lead to algorithms incapable of exactly matching occupancy measures without careful tuning, but are tractable in large environments. We propose the following new cost regularizer that combines the best of both worlds, as we will show in the coming sections: ψGA(c) ≜ EπE[g(c(s, a))] if c < 0 +∞ otherwise where g(x) = −x −log(1 −ex) if x < 0 +∞ otherwise (13) This regularizer places low penalty on cost functions c that assign an amount of negative cost to expert state-action pairs; if c, however, assigns large costs (close to zero, which is the upper bound for costs feasible for ψGA) to the expert, then ψGA will heavily penalize c. An interesting property of ψGA is that it is an average over expert data, and therefore can adjust to arbitrary expert datasets. The indicator regularizers δC, used by the linear apprenticeship learning algorithms described in Section 4, are always fixed, and cannot adapt to data as ψGA can. Perhaps the most important difference between ψGA and δC, however, is that δC forces costs to lie in a small subspace spanned by finitely many basis functions, whereas ψGA allows for any cost function, as long as it is negative everywhere. Our choice of ψGA is motivated by the following fact, shown in the appendix (Corollary A.1.1): ψ∗ GA(ρπ −ρπE) = sup D∈(0,1)S×A Eπ[log(D(s, a))] + EπE[log(1 −D(s, a))] (14) where the supremum ranges over discriminative classifiers D : S × A →(0, 1). Equation (14) is proportional to the optimal negative log loss of the binary classification problem of distinguishing between state-action pairs of π and πE. It turns out that this optimal loss is, up to a constant shift and scaling, the Jensen-Shannon divergence DJS(¯ρπ, ¯ρπE) ≜DKL (¯ρπ∥(¯ρπ + ¯ρE)/2) + DKL (¯ρE∥(¯ρπ + ¯ρE)/2), which is a squared metric between the normalized occupancy distributions ¯ρπ = (1 −γ)ρπ and ¯ρπE = (1 −γ)ρπE [8, 17]. Treating the causal entropy H as a policy regularizer controlled by λ ≥0 and dropping the 1 −γ occupancy measure normalization for clarity, we obtain a new imitation learning algorithm: minimize π ψ∗ GA(ρπ −ρπE) −λH(π) = DJS(ρπ, ρπE) −λH(π), (15) which finds a policy whose occupancy measure minimizes Jensen-Shannon divergence to the expert’s. Equation (15) minimizes a true metric between occupancy measures, so, unlike linear apprenticeship learning algorithms, it can imitate expert policies exactly. Algorithm Equation (15) draws a connection between imitation learning and generative adversarial networks [8], which train a generative model G by having it confuse a discriminative classifier D. The job of D is to distinguish between the distribution of data generated by G and the true data distribution. When D cannot distinguish data generated by G from the true data, then G has successfully matched the true data. In our setting, the learner’s occupancy measure ρπ is analogous to the data distribution generated by G, and the expert’s occupancy measure ρπE is analogous to the true data distribution. We now present a practical imitation learning algorithm, called generative adversarial imitation learning or GAIL (Algorithm 1), designed to work in large environments. GAIL solves Eq. (15) by finding a saddle point (π, D) of the expression Eπ[log(D(s, a))] + EπE[log(1 −D(s, a))] −λH(π) (16) with both π and D represented using function approximators: GAIL fits a parameterized policy πθ, with weights θ, and a discriminator network Dw : S × A →(0, 1), with weights w. GAIL alternates between an Adam [11] gradient step on w to increase Eq. (16) with respect to D, and a TRPO step on θ to decrease Eq. (16) with respect to π (we derive an estimator for the causal entropy gradient ∇θH(πθ) in Appendix A.2). The TRPO step serves the same purpose as it does with the apprenticeship learning algorithm of Ho et al. [10]: it prevents the policy from changing too much due to noise in the policy gradient. The discriminator network can be interpreted as a local cost function providing learning signal to the policy—specifically, taking a policy step that decreases expected cost with respect to the cost function c(s, a) = log D(s, a) will move toward expert-like regions of state-action space, as classified by the discriminator. 6 Algorithm 1 Generative adversarial imitation learning 1: Input: Expert trajectories τE ∼πE, initial policy and discriminator parameters θ0, w0 2: for i = 0, 1, 2, . . . do 3: Sample trajectories τi ∼πθi 4: Update the discriminator parameters from wi to wi+1 with the gradient ˆEτi[∇w log(Dw(s, a))] + ˆEτE[∇w log(1 −Dw(s, a))] (17) 5: Take a policy step from θi to θi+1, using the TRPO rule with cost function log(Dwi+1(s, a)). Specifically, take a KL-constrained natural gradient step with ˆEτi [∇θ log πθ(a|s)Q(s, a)] −λ∇θH(πθ), where Q(¯s, ¯a) = ˆEτi[log(Dwi+1(s, a)) | s0 = ¯s, a0 = ¯a] (18) 6: end for 6 Experiments We evaluated GAIL against baselines on 9 physics-based control tasks, ranging from low-dimensional control tasks from the classic RL literature—the cartpole [2], acrobot [7], and mountain car [15]—to difficult high-dimensional tasks such as a 3D humanoid locomotion, solved only recently by modelfree reinforcement learning [25, 24]. All environments, other than the classic control tasks, were simulated with MuJoCo [28]. See Appendix B for a complete description of all the tasks. Each task comes with a true cost function, defined in the OpenAI Gym [5]. We first generated expert behavior for these tasks by running TRPO [24] on these true cost functions to create expert policies. Then, to evaluate imitation performance with respect to sample complexity of expert data, we sampled datasets of varying trajectory counts from the expert policies. The trajectories constituting each dataset each consisted of about 50 state-action pairs. We tested GAIL against three baselines: 1. Behavioral cloning: a given dataset of state-action pairs is split into 70% training data and 30% validation data. The policy is trained with supervised learning, using Adam [11] with minibatches of 128 examples, until validation error stops decreasing. 2. Feature expectation matching (FEM): the algorithm of Ho et al. [10] using the cost function class Clinear (10) of Abbeel and Ng [1] 3. Game-theoretic apprenticeship learning (GTAL): the algorithm of Ho et al. [10] using the cost function class Cconvex (10) of Syed and Schapire [26] We used all algorithms to train policies of the same neural network architecture for all tasks: two hidden layers of 100 units each, with tanh nonlinearities in between. The discriminator networks for GAIL also used the same architecture. All networks were always initialized randomly at the start of each trial. For each task, we gave FEM, GTAL, and GAIL exactly the same amount of environment interaction for training. We ran all algorithms 5-7 times over different random seeds in all environments except Humanoid, due to time restrictions. Figure 1 depicts the results, and Appendix B provides exact performance numbers and details of our experiment pipeline, including expert data sampling and algorithm hyperparameters. We found that on the classic control tasks (cartpole, acrobot, and mountain car), behavioral cloning generally suffered in expert data efficiency compared to FEM and GTAL, which for the most part were able produce policies with near-expert performance with a wide range of dataset sizes, albeit with large variance over different random initializations of the policy. On these tasks, GAIL consistently produced policies performing better than behavioral cloning, FEM, and GTAL. However, behavioral cloning performed excellently on the Reacher task, on which it was more sample efficient than GAIL. We were able to slightly improve GAIL’s performance on Reacher using causal entropy regularization—in the 4-trajectory setting, the improvement from λ = 0 to λ = 10−3 was statistically significant over training reruns, according to a one-sided Wilcoxon rank-sum test with p = .05. We used no causal entropy regularization for all other tasks. 7 1 4 7 10 0.0 0.2 0.4 0.6 0.8 1.0 Cartpole 1 4 7 10 0.0 0.2 0.4 0.6 0.8 1.0 Acrobot 1 4 7 10 0.0 0.2 0.4 0.6 0.8 1.0 Mountain Car 4 11 18 25 0.0 0.2 0.4 0.6 0.8 1.0 HalfCheetah 4 11 18 25 0.0 0.2 0.4 0.6 0.8 1.0 Hopper 4 11 18 25 0.0 0.2 0.4 0.6 0.8 1.0 Walker 4 11 18 25 −1.0 −0.5 0.0 0.5 1.0 Ant 80 160 240 0.0 0.2 0.4 0.6 0.8 1.0 Humanoid Number of trajectories in dataset Performance (scaled) Expert Random Behavioral cloning FEM GTAL GAIL (ours) (a) 4 11 18 −0.5 0.0 0.5 1.0 Reacher Number of trajectories in dataset Performance (scaled) Expert Random Behavioral cloning GAIL (¸ = 0) GAIL (¸ = 10¡3) GAIL (¸ = 10¡2) (b) Figure 1: (a) Performance of learned policies. The y-axis is negative cost, scaled so that the expert achieves 1 and a random policy achieves 0. (b) Causal entropy regularization λ on Reacher. Except for Humanoid, shading indicates standard deviation over 5-7 reruns. On the other MuJoCo environments, GAIL almost always achieved at least 70% of expert performance for all dataset sizes we tested and reached it exactly with the larger datasets, with very little variance among random seeds. The baseline algorithms generally could not reach expert performance even with the largest datasets. FEM and GTAL performed poorly for Ant, producing policies consistently worse than a policy that chooses actions uniformly at random. Behavioral cloning was able to reach satisfactory performance with enough data on HalfCheetah, Hopper, Walker, and Ant, but was unable to achieve more than 60% for Humanoid, on which GAIL achieved exact expert performance for all tested dataset sizes. 7 Discussion and outlook As we demonstrated, GAIL is generally quite sample efficient in terms of expert data. However, it is not particularly sample efficient in terms of environment interaction during training. The number of such samples required to estimate the imitation objective gradient (18) was comparable to the number needed for TRPO to train the expert policies from reinforcement signals. We believe that we could significantly improve learning speed for GAIL by initializing policy parameters with behavioral cloning, which requires no environment interaction at all. Fundamentally, our method is model free, so it will generally need more environment interaction than model-based methods. Guided cost learning [6], for instance, builds upon guided policy search [12] and inherits its sample efficiency, but also inherits its requirement that the model is well-approximated by iteratively fitted time-varying linear dynamics. Interestingly, both GAIL and guided cost learning alternate between policy optimization steps and cost fitting (which we called discriminator fitting), even though the two algorithms are derived completely differently. Our approach builds upon a vast line of work on IRL [29, 1, 27, 26], and hence, just like IRL, our approach does not interact with the expert during training. Our method explores randomly to determine which actions bring a policy’s occupancy measure closer to the expert’s, whereas methods that do interact with the expert, like DAgger [22], can simply ask the expert for such actions. Ultimately, we believe that a method that combines well-chosen environment models with expert interaction will win in terms of sample complexity of both expert data and environment interaction. Acknowledgments We thank Jayesh K. Gupta, John Schulman, and the anonymous reviewers for assistance, advice, and critique. This work was supported by the SAIL-Toyota Center for AI Research and by a NSF Graduate Research Fellowship (grant no. DGE-114747). 8 References [1] P. Abbeel and A. Y. Ng. Apprenticeship learning via inverse reinforcement learning. In Proceedings of the 21st International Conference on Machine Learning, 2004. [2] A. G. Barto, R. S. Sutton, and C. W. Anderson. Neuronlike adaptive elements that can solve difficult learning control problems. Systems, Man and Cybernetics, IEEE Transactions on, (5):834–846, 1983. [3] M. Bloem and N. Bambos. Infinite time horizon maximum causal entropy inverse reinforcement learning. In Decision and Control (CDC), 2014 IEEE 53rd Annual Conference on, pages 4911–4916. IEEE, 2014. [4] S. Boyd and L. Vandenberghe. Convex optimization. Cambridge university press, 2004. [5] G. Brockman, V. Cheung, L. Pettersson, J. Schneider, J. Schulman, J. Tang, and W. Zaremba. OpenAI Gym. arXiv preprint arXiv:1606.01540, 2016. [6] C. Finn, S. Levine, and P. Abbeel. Guided cost learning: Deep inverse optimal control via policy optimization. In Proceedings of the 33rd International Conference on Machine Learning, 2016. [7] A. Geramifard, C. Dann, R. H. Klein, W. Dabney, and J. P. How. Rlpy: A value-function-based reinforcement learning framework for education and research. JMLR, 2015. [8] I. Goodfellow, J. Pouget-Abadie, M. Mirza, B. Xu, D. Warde-Farley, S. Ozair, A. Courville, and Y. Bengio. Generative adversarial nets. In NIPS, pages 2672–2680, 2014. [9] J.-B. Hiriart-Urruty and C. Lemaréchal. Convex Analysis and Minimization Algorithms, volume 305. Springer, 1996. [10] J. Ho, J. K. Gupta, and S. Ermon. Model-free imitation learning with policy optimization. In Proceedings of the 33rd International Conference on Machine Learning, 2016. [11] D. Kingma and J. Ba. Adam: A method for stochastic optimization. arXiv preprint arXiv:1412.6980, 2014. [12] S. Levine and P. Abbeel. Learning neural network policies with guided policy search under unknown dynamics. In Advances in Neural Information Processing Systems, pages 1071–1079, 2014. [13] S. Levine and V. Koltun. Continuous inverse optimal control with locally optimal examples. In Proceedings of the 29th International Conference on Machine Learning, pages 41–48, 2012. [14] S. Levine, Z. Popovic, and V. Koltun. Nonlinear inverse reinforcement learning with gaussian processes. In Advances in Neural Information Processing Systems, pages 19–27, 2011. [15] A. W. Moore and T. Hall. Efficient memory-based learning for robot control. 1990. [16] A. Y. Ng and S. Russell. Algorithms for inverse reinforcement learning. In ICML, 2000. [17] X. Nguyen, M. J. Wainwright, and M. I. Jordan. On surrogate loss functions and f-divergences. The Annals of Statistics, pages 876–904, 2009. [18] D. A. Pomerleau. Efficient training of artificial neural networks for autonomous navigation. Neural Computation, 3(1):88–97, 1991. [19] M. L. Puterman. Markov decision processes: discrete stochastic dynamic programming. John Wiley & Sons, 2014. [20] N. D. Ratliff, D. Silver, and J. A. Bagnell. Learning to search: Functional gradient techniques for imitation learning. Autonomous Robots, 27(1):25–53, 2009. [21] S. Ross and D. Bagnell. Efficient reductions for imitation learning. In AISTATS, pages 661–668, 2010. [22] S. Ross, G. J. Gordon, and D. Bagnell. A reduction of imitation learning and structured prediction to no-regret online learning. In AISTATS, pages 627–635, 2011. [23] S. Russell. Learning agents for uncertain environments. In Proceedings of the Eleventh Annual Conference on Computational Learning Theory, pages 101–103. ACM, 1998. [24] J. Schulman, S. Levine, P. Abbeel, M. Jordan, and P. Moritz. Trust region policy optimization. In Proceedings of The 32nd International Conference on Machine Learning, pages 1889–1897, 2015. [25] J. Schulman, P. Moritz, S. Levine, M. Jordan, and P. Abbeel. High-dimensional continuous control using generalized advantage estimation. arXiv preprint arXiv:1506.02438, 2015. [26] U. Syed and R. E. Schapire. A game-theoretic approach to apprenticeship learning. In Advances in Neural Information Processing Systems, pages 1449–1456, 2007. [27] U. Syed, M. Bowling, and R. E. Schapire. Apprenticeship learning using linear programming. In Proceedings of the 25th International Conference on Machine Learning, pages 1032–1039, 2008. [28] E. Todorov, T. Erez, and Y. Tassa. Mujoco: A physics engine for model-based control. In Intelligent Robots and Systems (IROS), 2012 IEEE/RSJ International Conference on, pages 5026–5033. IEEE, 2012. [29] B. D. Ziebart, A. Maas, J. A. Bagnell, and A. K. Dey. Maximum entropy inverse reinforcement learning. In AAAI, AAAI’08, 2008. [30] B. D. Ziebart, J. A. Bagnell, and A. K. Dey. Modeling interaction via the principle of maximum causal entropy. In ICML, pages 1255–1262, 2010. 9 | 2016 | 468 |
6,403 | Truncated Variance Reduction: A Unified Approach to Bayesian Optimization and Level-Set Estimation Ilija Bogunovic1, Jonathan Scarlett1, Andreas Krause2, Volkan Cevher1 1 Laboratory for Information and Inference Systems (LIONS), EPFL 2 Learning and Adaptive Systems Group, ETH Z¨urich {ilija.bogunovic,jonathan.scarlett,volkan.cevher}@epfl.ch, krausea@ethz.ch Abstract We present a new algorithm, truncated variance reduction (TRUVAR), that treats Bayesian optimization (BO) and level-set estimation (LSE) with Gaussian processes in a unified fashion. The algorithm greedily shrinks a sum of truncated variances within a set of potential maximizers (BO) or unclassified points (LSE), which is updated based on confidence bounds. TRUVAR is effective in several important settings that are typically non-trivial to incorporate into myopic algorithms, including pointwise costs and heteroscedastic noise. We provide a general theoretical guarantee for TRUVAR covering these aspects, and use it to recover and strengthen existing results on BO and LSE. Moreover, we provide a new result for a setting where one can select from a number of noise levels having associated costs. We demonstrate the effectiveness of the algorithm on both synthetic and real-world data sets. 1 Introduction Bayesian optimization (BO) [1] provides a powerful framework for automating design problems, and finds applications in robotics, environmental monitoring, and automated machine learning, just to name a few. One seeks to find the maximum of an unknown reward function that is expensive to evaluate, based on a sequence of suitably-chosen points and noisy observations. Numerous BO algorithms have been presented previously; see Section 1.1 for an overview. Level-set estimation (LSE) [2] is closely related to BO, with the added twist that instead of seeking a maximizer, one seeks to classify the domain into points that lie above or below a certain threshold. This is of considerable interest in applications such as environmental monitoring and sensor networks, allowing one to find all “sufficiently good” points rather than the best point alone. While BO and LSE are closely related, they are typically studied in isolation. In this paper, we provide a unified treatment of the two via a new algorithm, Truncated Variance Reduction (TRUVAR), which enjoys theoretical guarantees, good computational complexity, and the versatility to handle important settings such as pointwise costs, non-constant noise, and multi-task scenarios. The main result of this paper applies to the former two settings, and even the fixed-noise and unit-cost case, we refine existing bounds via a significantly improved dependence on the noise level. 1.1 Previous Work Three popular myopic techniques for Bayesian optimization are expected improvement (EI), probability of improvement (PI), and Gaussian process upper confidence bound (GP-UCB) [1, 3], each of which chooses the point maximizing an acquisition function depending directly on the current posterior mean and variance. In [4], the GP-UCB-PE algorithm was presented for BO, choosing the highest-variance point within a set of potential maximizers that is updated based on confidence bounds. Another relevant BO algorithm is BaMSOO [5], which also keeps track of potential maximizers, but instead chooses points based on a global optimization technique called simultaneous 1 online optimization (SOO). An algorithm for level-set estimation with GPs is given in [2], which keeps track of a set of unclassified points. These algorithms are computationally efficient and have various theoretical guarantees, but it is unclear how best to incorporate aspects such as pointwise costs and heteroscedastic noise [6]. The same is true for the Straddle heuristic for LSE [7]. Entropy search (ES) [8] and its predictive version [9] choose points to reduce the uncertainty of the location of the maximum, doing so via a one-step lookahead of the posterior rather than only the current posterior. While this is more computationally expensive, it also permits versatility with respect to costs [6], heteroscedastic noise [10], and multi-task scenarios [6]. A recent approach called minimum regret search (MRS) [11] also performs a look-ahead, but instead chooses points to minimize the regret. To our knowledge, no theoretical guarantees have been provided for these. The multi-armed bandit (MAB) [12] literature has developed alongside the BO literature, with the two often bearing similar concepts. The MAB literature is far too extensive to cover here, but we briefly mention some variants relevant to this paper. Extensive attention has been paid to the bestarm identification problem [13], and cost constraints have been incorporated in a variety of forms [14]. Moreover, the concept of “zooming in” to the optimal point has been explored [15]. In general, the assumptions and analysis techniques in the MAB and BO literature are quite different. 1.2 Contributions We present a unified analysis of Bayesian optimization and level-set estimation via a new algorithm Truncated Variance Reduction (TRUVAR). The algorithm works by keeping track of a set of potential maximizers (BO) or unclassified points (LSE), selecting points that shrink the uncertainty within that set up to a truncation threshold, and updating the set using confidence bounds. Similarly to ES and MRS, the algorithm performs a one-step lookahead that is highly beneficial in terms of versatility. However, unlike these previous works, our lookahead avoids the computationally expensive task of averaging over the posterior distribution and the observations. Also in contrast with ES and MRS, we provide theoretical bounds for TRUVAR characterizing the cost required to achieve a certain accuracy in finding a near-optimal point (BO) or in classifying each point in the domain (LSE). By applying this to the standard BO setting, we not only recover existing results [2, 4], but we also strengthen them via a significantly improved dependence on the noise level, with better asymptotics in the small noise limit. Moreover, we provide a novel result for a setting in which the algorithm can choose the noise level, each coming with an associated cost. Finally, we compare our algorithm to previous works on several synthetic and real-world data sets, observing it to perform favorably in a variety of settings. 2 Problem Setup and Proposed Algorithm Setup: We seek to sequentially optimize an unknown reward function f(x) over a finite domain D.1 At time t, we query a single point xt 2 D and observe a noisy sample yt = f(xt) + zt, where zt ⇠N(0, σ2(xt)) for some known noise function σ2(·) : D ! R+. Thus, in general, some points may be noisier than others, in which case we have heteroscedastic noise [10]. We associate with each point a cost according to some known cost function c : D ! R+. If both σ2(·) and c(·) are set to be constant, then we recover the standard homoscedastic and unit-cost setting. We model f(x) as a Gaussian process (GP) [16] having mean zero and kernel function k(x, x0), normalized so that k(x, x) = 1 for all x 2 D. The posterior distribution of f given the points and observations up to time t is again a GP, with the posterior mean and variance given by [10] µt(x) = kt(x)T ! Kt + ⌃t "−1yt (1) σt(x)2 = k(x, x) −kt(x)T ! Kt + ⌃t "−1kt(x), (2) where kt(x) = ⇥ k(xi, x) ⇤t i=1, Kt = ⇥ k(xt, xt0) ⇤ t,t0, and ⌃t = diag(σ2(x1), . . . , σ2(xt)). We also let σ2 t−1|x(x) denote the posterior variance of x upon observing x along with x1, · · · , xt−1. 1Extensions to continuous domains are discussed in the supplementary material. 2 Confidence Target Selected point Potential maximizers Max. lower bound (a) t = 6 (b) t = 7 (c) t = 8 (d) t = 9 Figure 1: An illustration of the TRUVAR algorithm. In (a), (b), and (c), three points within the set of potential maximizers Mt are selected in order to bring the confidence bounds to within the target range, and Mt shrinks during this process. In (d), the target confidence width shrinks as a result of the last selected point bringing the confidence within Mt to within the previous target. We consider both Bayesian optimization, which consists of finding a point whose function value is as high as possible, and level-set estimation, which consists of classifying the domain according into points that lie above or below a given threshold h. The precise performance criteria for these settings are given in Definition 3.1 below. Essentially, after spending a certain cost we report a point (BO) or a classification (LSE), but there is no preference on the values of f(xt) for the points xt chosen before coming to such a decision (in contrast with other notions such as cumulative regret). TRUVAR algorithm: Our algorithm is described in Algorithm 1, making use of the updates described in Algorithm 2. The algorithm keeps track of a sequence of unclassified points Mt, representing potential maximizers for BO or points close to h for LSE. This set is updated based on the confidence bounds depending on constants β(i). The algorithm proceeds in epochs, where in the i-th epoch it seeks to bring the confidence β1/2 (i) σt(x) of points within Mt below a target value ⌘(i). It does this by greedily minimizing the sum of truncated variances P x2Mt−1 max{β(i)σ2 t−1|x(x), ⌘(i)} arising from choosing the point x, along with a normalization and division by c(x) to favor low-cost points. The truncation by ⌘(i) in this decision rule means that once the confidence of a point is below the current target value, there is no preference in making it any lower (until the target is decreased). Once the confidence of every point in Mt is less than a factor 1 + δ above the target value, the target confidence is reduced according to a multiplication by r 2 (0, 1). An illustration of the process is given in Figure 1, with details in the caption. For level-set estimation, we also keep track of the sets Ht and Lt, containing points believed to have function values above and below h, respectively. The constraint x 2 Mt−1 in (5)–(7) ensures that {Mt} is non-increasing with respect to inclusion, and Ht and Lt are non-decreasing. Algorithm 1 Truncated Variance Reduction (TRUVAR) Input: Domain D, GP prior (µ0, σ0, k), confidence bound parameters δ > 0, r 2 (0, 1), {β(i)}i≥1, ⌘(1) > 0, and for LSE, level-set threshold h 1: Initialize the epoch number i = 1 and potential maximizers M(0) = D. 2: for t = 1, 2, . . . do 3: Choose xt = arg max x2D P x2Mt−1 max{β(i)σ2 t−1(x), ⌘2 (i)} −P x2Mt−1 max{β(i)σ2 t−1|x(x), ⌘2 (i)} c(x) . (3) 4: Observe the noisy function sample yt, and update according to Algorithm 2 to obtain Mt, µt, σt, lt and ut, as well as Ht and Lt in the case of LSE 5: while maxx2Mt β1/2 (i) σt(x) (1 + δ)⌘(i) do 6: Increment i, set ⌘(i) = r ⇥⌘(i−1). The choices of β(i), δ, and r are discussed in Section 4. As with previous works, the kernel is assumed known in our theoretical results, whereas in practice it is typically learned from training data [3]. Characterizing the effect of model mismatch or online hyperparameter updates is beyond the scope of this paper, but is an interesting direction for future work. 3 Algorithm 2 Parameter Updates for TRUVAR Input: Selected points and observations {xt0}t t0=1; {yt0}t t0=1, previous sets Mt−1, Ht−1, Lt−1, parameter β1/2 (i) , and for LSE, level-set threshold h. 1: Update µt and σt according to (1)–(2), and form the upper and lower confidence bounds ut(x) = µt(x) + β1/2 (i) σt(x), `t(x) = µt(x) −β1/2 (i) σt(x). (4) 2: For BO, set Mt = ⇢ x 2 Mt−1 : ut(x) ≥ max x2Mt−1 `t(x) ' , (5) or for LSE, set Mt = ( x 2 Mt−1 : ut(x) ≥h and `t(x) h (6) Ht = Ht−1 [ ( x 2 Mt−1 : `t(x) > h , Lt = Lt−1 [ ( x 2 Mt−1 : ut(x) < h . (7) Some variants of our algorithm and theory are discussed in the supplementary material due to lack of space, including pure variance reduction, non-Bayesian settings [3], continuous domains [3], the batch setting [4], and implicit thresholds for level-set estimation [2]. 3 Theoretical Bounds In order to state our results for BO and LSE in a unified fashion, we define a notion of ✏-accuracy for the two settings. That is, we define this term differently in the two scenarios, but then we provide theorems that simultaneously apply to both. All proofs are given in the supplementary material. Definition 3.1. After time step t of TRUVAR, we use the following terminology: • For BO, the set Mt is ✏-accurate if it contains all true maxima x⇤2 arg maxx f(x), and all of its points satisfy f(x⇤) −f(x) ✏. • For LSE, the triplet (Mt, Ht, Lt) is ✏-accurate if all points in Ht satisfy f(x) > h, all points in Lt satisfy f(x) < h, and all points in Mt satisfy |f(x) −h| ✏ 2. In both cases, the cumulative cost after time t is defined as Ct = Pt t0=1 c(xt0). We use ✏ 2 in the LSE setting instead of ✏since this creates a region of size ✏where the function value lies, which is consistent with the BO setting. Our performance criterion for level-set estimation is slightly different from that of [2], but the two are closely related. 3.1 General Result Preliminary definitions: Suppose that the {β(i)} are chosen to ensure valid confidence bounds, i.e., lt(x) f(x) ut(x) with high probability; see Theorem 3.1 and its proof below for such choices. In this case, we have after the i-th epoch that all points are either already discarded (BO) or classified (LSE), or are known up to the confidence level (1 + δ)⌘(i). For the points with such confidence, we have ut(x) −lt(x) 2(1 + δ)⌘(i), and hence ut(x) lt(x) + 2(1 + δ)⌘(i) f(x) + 2(1 + δ)⌘(i), (8) and similarly lt(x) ≥f(x) −2(1 + δ)⌘(i). This means that all points other than those within a gap of width 4(1 + δ)⌘(i) must have been discarded or classified: Mt ✓ ( x : f(x) ≥f(x⇤) −4(1 + δ)⌘(i) =: M (i) (BO) (9) Mt ✓ ( x : |f(x) −h| 2(1 + δ)⌘(i) =: M (i) (LSE) (10) Since no points are discarded or classified initially, we define M (0) = D. 4 For a collection of points S = (x0 1, . . . , x0 |S|), possibly containing duplicates, we write the total cost as c(S) = P|S| i=1 c(x0 i). Moreover, we denote the posterior variance upon observing the points up to time t −1 and the additional points in S by σt−1|S(x). Therefore, c(x) = c({x}) and σt−1|x(x) = σt−1|{x}(x). The minimum cost (respectively, maximum cost) is denoted by cmin = minx2D c(x) (respectively, cmax = maxx2D c(x)). Finally, we introduce the quantity C⇤(⇠, M) = min S n c(S) : max x2M σ0|S(x) ⇠ o , (11) representing the minimum cost to achieve a posterior standard deviation of at most ⇠within M. Main result: In all of our results, we make the following assumption. Assumption 3.1. The kernel k(x, x0) is such that the variance reduction function t,x(S) = σ2 t (x) −σ2 t|S(x) (12) is submodular [17] for any time t, and any selected points (x1, . . . , xt) and query point x. This assumption has been used in several previous works based on Gaussian processes, and sufficient conditions for its validity can be found in [18, Sec. 8]. We now state the following general guarantee. Theorem 3.1. Fix ✏> 0 and δ 2 (0, 1), and suppose there exist values {C(i)} and {β(i)} such that C(i) ≥C⇤ ✓⌘(i) β1/2 (i) , M (i−1) ◆ log |M (i−1)|β(i) δ 2⌘2 (i) + cmax, (13) and β(i) ≥2 log |D| ! P i0i C(i0) "2⇡2 6δc2 min . (14) Then if TRUVAR is run with these choices of β(i) until the cumulative cost reaches C✏= X i : 4(1+δ)⌘(i−1)>✏ C(i), (15) then with probability at least 1 −δ, we have ✏-accuracy. While this theorem is somewhat abstract, it captures the fact that the algorithm improves when points having a lower cost and/or lower noise are available, since both of these lead to a smaller value of C⇤(⇠, M); the former by directly incurring a smaller cost, and the latter by shrinking the variance more rapidly. Below, we apply this result to some important cases. 3.2 Results for Specific Settings Homoscedastic and unit-cost setting: Define the maximum mutual information [3] γT = max x1,...,xT 1 2 log det ! IT + σ−2KT " , (16) and consider the case that σ2(x) = σ2 and c(x) = 1. In the supplementary material, we provide a theorem with a condition for ✏-accuracy of the form T ≥⌦⇤! C1γT βT ✏2 + 1 " with C1 = 1 log(1+σ−2), thus matching [2, 4] up to logarithmic factors. In the following, we present a refined version that has a significantly better dependence on the noise level, thus exemplifying that a more careful analysis of (13) can provide improvements over the standard bounding techniques. Corollary 3.1. Fix ✏> 0 and δ 2 (0, 1), define βT = 2 log |D|T 2⇡2 6δ , and set ⌘(1) = 1 and r = 1 2. There exist choices of β(i) (not depending on the time horizon T) such that we have ✏-accuracy with probability at least 1 −δ once the following condition holds: T ≥ ✓ 2σ2γT βT 96(1 + δ)2 ✏2 + C1γT βT 6(1 + δ)2 σ2 + 2 l log2 32(1 + δ)2 ✏σ m◆ log 16(1 + δ)2|D|βT δ 2✏2 , (17) where C1 = 1 log(1+σ−2). This condition is of the form T ≥⌦⇤! σ2γT βT ✏2 + C1γT βT σ2 + 1 " . 5 The choices ⌘(1) = 1 and r = 1 2 are made for mathematical convenience, and a similar result follows for any other choices ⌘(1) > 0 and r 2 (0, 1), possibly with different constant factors. As σ2 ! 1 (i.e., high noise), both of the above-mentioned bounds have noise dependence O⇤(σ2), since log(1 + ↵−1) = O(↵−1) as ↵! 1. On the other hand, as σ2 ! 0 (i.e., low noise), C1 is logarithmic, and Corollary 3.1 is significantly better provided that ✏⌧σ. Choosing the noise and cost: Here we consider the setting that there is a domain of points D0 that the reward function depends on, and alongside each point we can choose a noise variance σ2(k) (k = 1, . . . , K). Hence, D = D0⇥{1, · · · , K}. Lower noise variances incur a higher cost according to a cost function c(k). Corollary 3.2. For each k = 1, · · · , K, let T ⇤(k) denote the smallest value of T such that (17) holds with σ2(k) in place of σ2, and with βT = 2 log |D|T 2c2 max⇡2 6δc2 min . Then, under the preceding setting, there exist choices of β(i) (not depending on T) such that we have ✏-accuracy with probability at least 1−δ once the cumulative cost reaches mink c(k)T ⇤(k). This result roughly states that we obtain a bound as good as that obtained by sticking to any fixed choice of noise level. In other words, every choice of noise (and corresponding cost) corresponds to a different version of a BO or LSE algorithm (e.g., [2, 4]), and our algorithm has a similar performance guarantee to the best among all of those. This is potentially useful in avoiding the need for running an algorithm once per noise level and then choosing the best-performing one. Moreover, we found numerically that beyond matching the best fixed noise strategy, we can strictly improve over it by mixing the noise levels; see Section 4. 4 Experimental Results We evaluate our algorithm in both the level-set estimation and Bayesian optimization settings. Parameter choices: As with previous GP-based algorithms that use confidence bounds, our theoretical choice of β(i) in TRUVAR is typically overly conservative. Therefore, instead of using (14) directly, we use a more aggressive variant with similar dependence on the domain size and time: β(i) = a log(|D|t2 (i)), where t(i) is the time at which the epoch starts, and a is a constant. Instead of the choice a = 2 dictated by (14), we set a = 0.5 for BO to avoid over-exploration. We found exploration to be slightly more beneficial for LSE, and hence set a = 1 for this setting. We found TRUVAR to be quite robust with respect to the choices of the remaining parameters, and simply set ⌘(1) = 1, r = 0.1, and δ = 0 in all experiments; while our theory assumes δ > 0, in practice there is negligible difference between choosing zero and a small positive value. Level-set estimation: For the LSE experiments, we use a common classification rule in all algorithms, classifying the points according to the posterior mean as ˆHt = {x : µt(x) ≥h} and ˆLt = {x : µt(x) < h}. The classification accuracy is measured by the F1-score (i.e., the harmonic mean of precision and recall) with respect to the true super- and sub-level sets. We compare TRUVAR against the GP-based LSE algorithm [2], which we name via the authors’ surnames as GCHK, as well as the state-of-the-art straddle (STR) heuristic [7] and the maximum variance rule (VAR) [2]. Descriptions can be found in the supplementary material. GCHK includes an exploration constant βt, and we follow the recommendation in [2] of setting β1/2 t = 3. Lake data (unit cost): We begin with a data set from the domain of environmental monitoring of inland waters, consisting of 2024 in situ measurements of chlorophyll concentration within a vertical transect plane, collected by an autonomous surface vessel in Lake Z¨urich [19]. As in [2], our goal is to detect regions of high concentration. We evaluate each algorithm on a 50 ⇥50 grid of points, with the corresponding values coming from the GP posterior that was derived using the original data (see Figure 2d). We use the Mat´ern-5/2 ARD kernel, setting its hyperparameters by maximizing the likelihood on the second (smaller) available dataset. The level-set threshold h is set to 1.5. In Figure 2a, we show the performance of the algorithms averaged over 100 different runs; here the randomness is only with respect to the starting point, as we are in the noiseless setting. We observe that in this unit-cost case, TRUVAR performs similarly to GCHK and STR. All three methods outperform VAR, which is good for global exploration but less suited to level-set estimation. 6 Time 0 20 40 60 80 100 120 F1 score 0 0.2 0.4 0.6 0.8 1 TruVaR GCHK STR VAR (a) Lake data, unit-cost Cost (×104) ×104 0 0.5 1 1.5 2 F1 score 0 0.2 0.4 0.6 0.8 1 TruVaR GCHK (b) Lake data, varying cost Cost (×104) 0.1 0.15 0.2 0.25 0.3 0.35 0.4 F1 score 0.5 0.6 0.7 0.8 0.9 1 TruVaR GCHK high noise GCHK medium noise GCHK small noise (c) Synthetic data, varying noise (d) Inferred concentration function (e) Points chosen by GCHK (f) Points chosen by TRUVAR Figure 2: Experimental results for level-set estimation. Time 0 20 40 60 80 100 120 Median Regret 10-6 10-4 10-2 100 TruVaR EI GP-UCB ES MRS (a) Synthetic, median Time 0 20 40 60 80 100 120 Averaged Regret 10-6 10-4 10-2 100 TruVaR EI GP-UCB ES MRS (b) Synthetic, outlier-adjusted mean Time 0 20 40 60 80 100 Validation Error 0.24 0.25 0.26 0.27 TruVaR EI GP-UCB (c) SVM data Figure 3: Experimental results for Bayesian optimization. Lake data (varying cost): Next, we modify the above setting by introducing pointwise costs that are a function of the previous sampled point x0, namely, cx0(x) = 0.25|x1 −x0 1| + 4(|x2| + 1), where x1 is the vessel position and x2 is the depth. Although we did not permit such a dependence on x0 in our original setup, the algorithm itself remains unchanged. Our choice of cost penalizes the distance traveled |x1 −x0 1|, as well as the depth of the measurement |x2|. Since incorporating costs into existing algorithms is non-trivial, we only compare against the original version of GCHK that ignores costs. In Figure 2b, we see that TruVaR significantly outperforms GCHK, achieving a higher F1 score for a significantly smaller cost. The intuition behind this can be seen in Figures 2e and 2f, where we show the points sampled by TruVaR and GCHK in one experiment run, connecting all pairs of consecutive points. GCHK is designed to pick few points, but since it ignores costs, the distance traveled is large. In contrast, by incorporating costs, TRUVAR tends to travel small distances, often even staying in the same x1 location to take measurements at multiple depths x2. Synthetic data with multiple noise levels: In this experiment, we demonstrate Corollary 3.2 by considering the setting in which the algorithm can choose the sampling noise variance and incur the associated cost. We use a synthetic function sampled from a GP on a 50 ⇥50 grid with an isotropic squared exponential kernel having length scale l = 0.1 and unit variance, and set h = 2.25. We use three different noise levels, σ2 2 {10−6, 10−3, 0.05}, with corresponding costs {15, 10, 2}. We run GCHK separately for each of the three noise levels, while running TRUVAR as normal and allowing it to mix between the noise levels. The resulting F1-scores are shown in Figure 2c. The best-performing version of GCHK changes throughout the time horizon, while TRUVAR is consistently better than all three. A discussion on how TRUVAR mixes between the noise levels can be found in the supplementary material. 7 Bayesian optimization. We now provide the results of two experiments for the BO setting. Synthetic data: We first conduct a similar experiment as that in [8, 11], generating 200 different test functions defined on [0, 1]2. To generate a single test function, 200 points are chosen uniformly at random from [0, 1]2, their function values are generated from a GP using an isotropic squared exponential kernel with length scale l = 0.1 and unit variance, and the resulting posterior mean forms the function on the whole domain [0, 1]2. We subsequently assume that samples of this function are corrupted by Gaussian noise with σ2 = 10−6. The extension of TRUVAR to continuous domains is straightforward, and is explained in the supplementary material. For all algorithms considered, we evaluate the performance according to the regret of a single reported point, namely, the one having the highest posterior mean. We compare the performance of TRUVAR against expected improvement (EI), GP-upper confidence bound (GP-UCB), entropy search (ES) and minimum regret search (MRS), whose acquisition functions are outlined in the supplementary material. We use publicly available code for ES and MRS [20]. The exploration parameter βt in GP-UCB is set according to the recommendation in [3] of dividing the theoretical value by five, and the parameters for ES and MRS are set according to the recommendations given in [11, Section 5.1]. Figure 3a plots the median of the regret, and Figure 3b plots the mean after removing outliers (i.e., the best and worst 5% of the runs). In the earlier rounds, ES and MRS provide the best performance, while TRUVAR improves slowly due to exploration. However, the regret of TRUVAR subsequently drops rapidly, giving the best performance in the later rounds after “zooming in” towards the maximum. GP-UCB generally performs well with the aggressive choice of βt, despite previous works’ experiments revealing it to perform poorly with the theoretical value. Hyperparameter tuning data: In this experiment, we use the SVM on grid dataset, previously used in [21]. A 25 ⇥14 ⇥4 grid of hyperparameter configurations resulting in 1400 data points was preevaluated, forming the search space. The goal is to find a configuration with small validation error. We use a Mat´ern-5/2 ARD kernel, and re-learn its hyperparameters by maximizing the likelihood after sampling every 3 points. Since the hyperparameters are not fixed in advance, we replace Mt−1 by D in (5) to avoid incorrectly ruling points out early on, allowing some removed points to be added again in later steps. Once the estimated hyperparameters stop to vary significantly, the size of the set of potential maximizers decreases almost monotonically. Since we consider the noiseless setting here, we measure performance using the simple regret, i.e., the best point found so far. We again average over 100 random starting points, and plot the resulting validation error in Figure 3c. Even in this noiseless and unit-cost setting that EI and GP-UCB are suited to, we find that TRUVAR performs slightly better, giving a better validation error with smaller error bars. 5 Conclusion We highlight the following aspects in which TRUVAR is versatile: • Unified optimization and level-set estimation: These are typically treated separately, whereas TRUVAR and its theoretical guarantees are essentially identical in both cases • Actions with costs: TRUVAR naturally favors cost-effective points, as this is directly incorporated into the acquisition function. • Heteroscedastic noise: TRUVAR chooses points that effectively shrink the variance of other points, thus directly taking advantage of situations in which some points are noisier than others. • Choosing the noise level: We provided novel theoretical guarantees for the case that the algorithm can choose both a point and a noise level, cf., Corollary 3.2. Hence, TRUVAR directly handles several important aspects that are non-trivial to incorporate into myopic algorithms. Moreover, compared to other BO algorithms that perform a lookahead (e.g., ES and MRS), TRUVAR avoids the computationally expensive task of averaging over the posterior and/or measurements, and comes with rigorous theoretical guarantees. Acknowledgment: This work was supported in part by the European Commission under Grant ERC Future Proof, SNF Sinergia project CRSII2-147633, SNF 200021-146750, and EPFL Fellows Horizon2020 grant 665667. 8 References [1] B. Shahriari, K. Swersky, Z. Wang, R. P. Adams, and N. de Freitas, “Taking the human out of the loop: A review of Bayesian optimization,” Proc. IEEE, vol. 104, no. 1, pp. 148–175, 2016. [2] A. Gotovos, N. Casati, G. Hitz, and A. Krause, “Active learning for level set estimation,” in Int. Joint. Conf. Art. Intel., 2013. [3] N. Srinivas, A. Krause, S. Kakade, and M. Seeger, “Information-theoretic regret bounds for Gaussian process optimization in the bandit setting,” IEEE Trans. Inf. Theory, vol. 58, no. 5, pp. 3250–3265, May 2012. [4] E. Contal, D. Buffoni, A. Robicquet, and N. Vayatis, Machine Learning and Knowledge Discovery in Databases. Springer Berlin Heidelberg, 2013, ch. Parallel Gaussian Process Optimization with Upper Confidence Bound and Pure Exploration, pp. 225–240. [5] Z. Wang, B. Shakibi, L. Jin, and N. de Freitas, “Bayesian multi-scale optimistic optimization,” http://arxiv.org/abs/1402.7005. [6] K. Swersky, J. Snoek, and R. P. Adams, “Multi-task Bayesian optimization,” in Adv. Neur. Inf. Proc. Sys. (NIPS), 2013, pp. 2004–2012. [7] B. Bryan and J. G. Schneider, “Actively learning level-sets of composite functions,” in Int. Conf. Mach. Learn. (ICML), 2008. [8] P. Hennig and C. J. Schuler, “Entropy search for information-efficient global optimization,” J. Mach. Learn. Research, vol. 13, no. 1, pp. 1809–1837, 2012. [9] J. M. Hern´andez-Lobato, M. W. Hoffman, and Z. Ghahramani, “Predictive entropy search for efficient global optimization of black-box functions,” in Adv. Neur. Inf. Proc. Sys. (NIPS), 2014, pp. 918–926. [10] P. W. Goldberg, C. K. Williams, and C. M. Bishop, “Regression with input-dependent noise: A Gaussian process treatment,” Adv. Neur. Inf. Proc. Sys. (NIPS), vol. 10, pp. 493–499, 1997. [11] J. H. Metzen, “Minimum regret search for single-and multi-task optimization,” in Int. Conf. Mach. Learn. (ICML), 2016. [12] S. Bubeck and N. Cesa-Bianchi, Regret Analysis of Stochastic and Nonstochastic Multi-Armed Bandit Problems, ser. Found. Trend. Mach. Learn. Now Publishers, 2012. [13] K. Jamieson and R. Nowak, “Best-arm identification algorithms for multi-armed bandits in the fixed confidence setting,” in Ann. Conf. Inf. Sci. Sys. (CISS), 2014, pp. 1–6. [14] O. Madani, D. J. Lizotte, and R. Greiner, “The budgeted multi-armed bandit problem,” in Learning Theory. Springer, 2004, pp. 643–645. [15] R. Kleinberg, A. Slivkins, and E. Upfal, “Multi-armed bandits in metric spaces,” in Proc. ACM Symp. Theory Comp., 2008. [16] C. E. Rasmussen, “Gaussian processes for machine learning.” MIT Press, 2006. [17] A. Krause and D. Golovin, “Submodular function maximization,” Tractability: Practical Approaches to Hard Problems, vol. 3, 2012. [18] A. Das and D. Kempe, “Algorithms for subset selection in linear regression,” in Proc. ACM Symp. Theory Comp. (STOC). ACM, 2008, pp. 45–54. [19] G. Hitz, F. Pomerleau, M.-E. Garneau, E. Pradalier, T. Posch, J. Pernthaler, and R. Y. Siegwart, “Autonomous inland water monitoring: Design and application of a surface vessel,” IEEE Robot. Autom. Magazine, vol. 19, no. 1, pp. 62–72, 2012. [20] http://github.com/jmetzen/bayesian optimization (accessed 19/05/2016). [21] J. Snoek, H. Larochelle, and R. P. Adams, “Practical Bayesian optimization of machine learning algorithms,” in Adv. Neur. Inf. Proc. Sys., 2012. [22] K. Swersky, J. Snoek, and R. P. Adams, “Freeze-thaw Bayesian optimization,” 2014, http://arxiv.org/abs/1406.3896. [23] D. R. Jones, C. D. Perttunen, and B. E. Stuckman, “Lipschitzian optimization without the Lipschitz constant,” J. Opt. Theory Apps., vol. 79, no. 1, pp. 157–181, 1993. [24] A. Krause and C. Guestrin, “A note on the budgeted maximization of submodular functions,” 2005, Technical Report. 9 | 2016 | 469 |
6,404 | Improving PAC Exploration Using the Median of Means Jason Pazis Laboratory for Information and Decision Systems Massachusetts Institute of Technology Cambridge, MA 02139, USA jpazis@mit.edu Ronald Parr Department of Computer Science Duke University Durham, NC 27708 parr@cs.duke.edu Jonathan P. How Aerospace Controls Laboratory Department of Aeronautics and Astronautics Massachusetts Institute of Technology Cambridge, MA 02139, USA jhow@mit.edu Abstract We present the first application of the median of means in a PAC exploration algorithm for MDPs. Using the median of means allows us to significantly reduce the dependence of our bounds on the range of values that the value function can take, while introducing a dependence on the (potentially much smaller) variance of the Bellman operator. Additionally, our algorithm is the first algorithm with PAC bounds that can be applied to MDPs with unbounded rewards. 1 Introduction As the reinforcement learning community has shifted its focus from heuristic methods to methods that have performance guarantees, PAC exploration algorithms have received significant attention. Thus far, even the best published PAC exploration bounds are too pessimistic to be useful in practical applications. Even worse, lower bound results [14, 7] indicate that there is little room for improvement. While these lower bounds prove that there exist pathological examples for which PAC exploration can be prohibitively expensive, they leave the door open for the existence of “well-behaved” classes of problems in which exploration can be performed at a significantly lower cost. The challenge of course is to identify classes of problems that are general enough to include problems of real-world interest, while at the same time restricted enough to have a meaningfully lower cost of exploration than pathological instances. The approach presented in this paper exploits the fact that while the square of the maximum value that the value function can take (Q2 max) is typically quite large, the variance of the Bellman operator is rather small in many domains of practical interest. For example, this is true in many control tasks: It is not very often that an action takes the system to the best possible state with 50% probability and to the worst possible state with 50% probability. Most PAC exploration algorithms take an average over samples. By contrast, the algorithm presented in this paper splits samples into sets, takes the average over each set, and returns the median of the averages. This seemingly simple trick (known as the median trick [1]), allows us to derive sample complexity bounds that depend on the variance of the Bellman operator rather than Q2 max. Addi30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. tionally, our algorithm (Median-PAC) is the first reinforcement learning algorithm with theoretical guarantees that allows for unbounded rewards.1 Not only does Median-PAC offer significant sample complexity savings in the case when the variance of the Bellman operator is low, but even in the worst case (the variance of the Bellman operator is bounded above by Q2 max 4 ) our bounds match the best, published PAC bounds. Note that Median-PAC does not require the variance of the Bellman operator to be known in advance. Our bounds show that there is an inverse relationship between the (possibly unknown) variance of the Bellman operator and Median-PAC’s performance. This is to the best of our knowledge not only the first application of the median of means in PAC exploration, but also the first application of the median of means in reinforcement learning in general. Contrary to recent work which has exploited variance in Markov decision processes to improve PAC bounds [7, 3], Median-PAC makes no assumptions about the number of possible next-states from every state-action (it does not even require the number of possible next states to be finite), and as a result it is easily extensible to the continuous state, concurrent MDP, and delayed update settings [12]. 2 Background, notation, and definitions In the following, important symbols and terms will appear in bold when first introduced. Let X be the domain of x. Throughout this paper, 888x will serve as a shorthand for 8x 2 X. In the following s, ¯s, ˜s, s0 s, ¯s, ˜s, s0 s, ¯s, ˜s, s0 are used to denote various states, and a, ¯a, ˜a, a0 a, ¯a, ˜a, a0 a, ¯a, ˜a, a0 are used to denote actions. A Markov Decision Process (MDP) [13] is a 5-tuple (S, A, P, R, γ), where SSS is the state space of the process, AAA is the action space2, PPP is a Markovian transition model ! p(s0|s, a) denotes the probability of a transition to state s0 when taking action a in state s " , RRR is a reward function ! R(s, a, s0) is the reward for taking action a in state s and transitioning to state s0" , and γγγ 2 [0, 1) is a discount factor for future rewards. A deterministic policy ⇡⇡⇡is a mapping ⇡: S 7! A from states to actions; ⇡(s) denotes the action choice in state s. The value V ⇡(s) V ⇡(s) V ⇡(s) of state s under policy ⇡is defined as the expected, accumulated, discounted reward when the process begins in state s and all decisions are made according to policy ⇡. There exists an optimal policy ⇡⇤ ⇡⇤ ⇡⇤ for choosing actions which yields the optimal value function V ⇤(s), defined recursively via the Bellman optimality equation V ⇤(s) V ⇤(s) V ⇤(s) = maxa {P s0 p(s0|s, a) (R(s, a, s0) + γV ⇤(s0))}. Similarly, the value Q⇡(s, a) Q⇡(s, a) Q⇡(s, a) of a state-action (s, a) under policy ⇡is defined as the expected, accumulated, discounted reward when the process begins in state s by taking action a and all decisions thereafter are made according to policy ⇡. The Bellman optimality equation for Q becomes Q⇤(s, a) Q⇤(s, a) Q⇤(s, a) = P s0 p(s0|s, a) (R(s, a, s0) + γ maxa0{Q⇤(s0, a0)}). For a fixed policy ⇡the Bellman operator for Q is defined as B⇡Q(s, a) B⇡Q(s, a) B⇡Q(s, a) = P s0 p(s0|s, a) ⇣ R(s, a, s0) + γQ(s0, ⇡(s0)) ⌘ . In reinforcement learning (RL) [15], a learner interacts with a stochastic process modeled as an MDP and typically observes the state and immediate reward at every step; however, the transition model P and reward function R are not known. The goal is to learn a near optimal policy using experience collected through interaction with the process. At each step of interaction, the learner observes the current state s, chooses an action a, and observes the reward received r, and resulting next state s0, essentially sampling the transition model and reward function of the process. Thus experience comes in the form of (s, a, r, s0) samples. We assume that all value functions Q live in a complete metric space. Definition 2.1. Qmax Qmax Qmax denotes an upper bound on the expected, accumulated, discounted reward from any state-action under any policy. We require that Qmin, the minimum expected, accumulated, discounted reward from any state-action under any policy is bounded, and in order to simplify notation we also assume without loss of 1Even though domains with truly unbounded rewards are not common, many domains exist for which infrequent events with extremely high (winning the lottery) or extremely low (nuclear power-plant meltdown) rewards exist. Algorithms whose sample complexity scales with the highest magnitude event are not well suited to such domains. 2For simplicity of exposition we assume that the same set of actions is available at every state. Our results readily extend to the case where the action set can differ from state to state. 2 generality that it is bounded below by 0. If Qmin < 0, this assumption is easy to satisfy in all MDPs for which Qmin is bounded by simply shifting the reward space by (γ −1)Qmin. There have been many definitions of sample complexity in RL. In this paper we will be using the following [12]: Definition 2.2. Let (s1, s2, s3, . . . ) be the random path generated on some execution of ⇡, where ⇡ is an arbitrarily complex, possibly non-stationary, possibly history dependent policy (such as the policy followed by an exploration algorithm). Let ✏be a positive constant, T the (possibly infinite) set of time steps for which V ⇡(st) < V ⇤(st) −✏, and define3 ✏e(t) =V ⇤(st) −V ⇡(st) −✏, 8 t 2 T. ✏e(t) =0, 8 t /2 T. The Total Cost of Exploration (TCE) is defined as the undiscounted infinite sum P1 t=0 ✏e(t). “Number of suboptimal steps” bounds follow as a simple corollary of TCE bounds. We will be using the following definition of efficient PAC exploration [14]: Definition 2.3. An algorithm is said to be efficient PAC-MDP (Probably Approximately Correct in Markov Decision Processes) if, for any ✏> 0 and 0 < δ < 1, its sample complexity, its per-timestep computational complexity, and its space complexity, are less than some polynomial in the relevant quantities (S, A, 1 ✏, 1 δ , 1 1−γ ), with probability at least 1 −δ. 3 The median of means Before we present Median-PAC we will demonstrate the usefulness of the median of means with a simple example. Suppose we are given n independent samples from a random variable X and we want to estimate its mean. The types of guarantees that we can provide about how close that estimate will be to the expectation, will depend on what knowledge we have about the variable, and on the method we use to compute the estimate. The main question of interest in our work is how many samples are needed until our estimate is ✏-close to the expectation with probability at least 1 −δ. Let the expectation of X be E[X] = µ and its variance var[X] = σ2. Cantelli’s inequality tells us that: P (X −µ ≥✏) σ2 σ2+✏2 and P (X −µ −✏) σ2 σ2+✏2 . Let Xi be a random variable describing the value of the i-th sample, and define X0 = X1+X2+···+Xn n . We have that E[X0] = µ and var[X0] = σ2 n . From Cantelli’s inequality we have that P (X0 −µ ≥✏) σ2 σ2+n✏2 and P (X0 −µ −✏) σ2 σ2+n✏2 . Solving for n we have that we need at most n = (1−δ)σ2 δ✏2 = O ⇣ σ2 δ✏2 ⌘ samples until our estimate is ✏-close to the expectation with probability at least 1 −δ. In RL, it is common to apply a union bound over the entire state-action space in order to prove uniformly good approximation. This means that δ has to be small enough that even when multiplied with the number of state-actions, it yields an acceptably low probability of failure. The most significant drawback of the bound above is that it grows very quickly as δ becomes smaller. Without further assumptions one can show that the bound above is tight for the average estimator. If we know that X can only take values in a bounded range a X b, Hoeffding’s inequality tells us that P (X0 −µ ≥✏) e − 2n✏2 (b−a)2 and P (X0 −µ −✏) e − 2n✏2 (b−a)2 . Solving for n we have that n = (b−a)2 ln 1 δ 2✏2 samples suffice to guarantee that our estimate is ✏-close to the expectation with probability at least 1 −δ. Hoeffding’s inequality yields a much better bound with respect to δ, but introduces a quadratic dependence on the range of values that the variable can take. For long planning horizons (discount factor close to 1) and/or large reward magnitudes, the range of possible Q-values can be very large, much larger than the variance of individual state-actions. We can get the best of both worlds by using a more sophisticated estimator. Instead of taking the average over n samples, we will split them into km = n✏2 4σ2 sets of 4σ2 ✏2 samples each,4 compute the 3Note that V ⇡(st) denotes the expected, discounted, accumulated reward of the arbitrarily complex policy ⇡ from state st at time t, rather than the expectation of some stationary snapshot of ⇡. 4The number of samples per set was chosen so as to minimize the constants in the final bound. 3 average over each set, and then take the median of the averages. From Cantelli’s inequality we have that with probability at least 4 5, each one of the sets will not underestimate, or overestimate the mean µ by more than ✏. Let f −be the function that counts the number of sets that underestimate the mean by more than ✏, and f + the function that counts the number of sets that overestimate the mean by more than ✏. From McDiarmid’s inequality [9] we have that P ! f −≥km 2 " e− 2( 3km 10 ) 2 km and P ! f + ≥km 2 " e− 2( 3km 10 ) 2 km . Solving for n we have that n = 200 9 σ2 ln( 1 δ) ✏2 ⇡ 22.22σ2 ln( 1 δ) ✏2 samples suffice to guarantee that our estimate is ✏-close to the expectation with probability at least 1 −δ. The median of means offers logarithmic dependence on 1 δ, independence from the range of values that the variables in question can take (even allowing for them to be infinite), and can be computed efficiently. The median of means estimator only requires a finite variance and the existence of a mean. No assumptions (including boundedness) are made on higher moments. 4 Median PAC exploration Algorithm 1 Median-PAC 1: Inputs: start state s, discount factor γ, max number of samples k, number of sets km, and acceptable error ✏a. 2: Initialize sample sets unew(s, a) = ;, u(s, a) = ; 8 (s, a). (|u(s, a)| denotes the number of samples in u(s, a)) 3: Set ✏b = ✏a p k, and initialize value function ˜Q(s, a) = Qmax 8 (s, a). 4: loop 5: Perform action a = arg max˜a ˜Q(s, ˜a) 6: Receive reward r, and transition to state s0. 7: if |u(s, a)| < k then 8: Add (s, a, r, s0) to unew(s, a). 9: if |unew(s, a)| > |u(s, a)| and |unew(s, a)| = 2ikm, where i ≥0 is an integer then 10: u(s, a) = unew(s, a) 11: unew(s, a) = ; 12: end if 13: while max(s,a)( ˜B ˜Q(s, a) −˜Q(s, a)) > ✏a or max(s,a)( ˜Q(s, a) −˜B ˜Q(s, a)) > ✏a do 14: Set ˜Q(s, a) = ˜B ˜Q(s, a) 8 (s, a). 15: end while 16: end if 17: end loop 18: function ˜B ˜Q(s, a) 19: if |u(s, a)| ≥km then 20: Let (s, a, ri, s0 i) be the i-th sample in u(s, a). 21: for j = 1 to km do 22: g(j) = Pj |u(s,a)| km i=1+(j−1) |u(s,a)| km ri + γ max¯a ˜Q(s0 i, ¯a) ! 23: end for 24: return min ⇢ Qmax, ✏b p |u(s,a)| + kmmedian{g(1),...g(km)} |u(s,a)| ) 25: else 26: return Qmax. 27: end if 28: end function Algorithm 1 has three parameters that can be set by the user: • k is the maximum number of samples per state-action. As we will show, higher values for k lead to increased sample complexity but better approximation. • ✏a is an “acceptable error” term. Since Median-PAC is based on value iteration (lines 13 through 15) we specify a threshold after which value iteration should terminate. Value 4 iteration is suspended when the max-norm of the difference between Bellman backups is no larger than ✏a. • Due to the stochasticity of Markov decision processes, Median-PAC is only guaranteed to achieve a particular approximation quality with some probability. km offers a tradeoff between approximation quality and the probability that this approximation quality is achieved. For a fixed k smaller values of km offer potentially improved approximation quality, while larger values offer a higher probability of success. For simplicity of exposition our analysis requires that k = 2ikm for some integer i. If km ≥ & 50 9 ln 4 log2 4Q2 max ✏2a |SA|2 δ ' the probability of failure is bounded above by δ. Like most modern PAC exploration algorithms, Median-PAC is based on the principle of optimism in the face of uncertainty. At every step, the algorithm selects an action greedily based on the current estimate of the Q-value function ˜Q. The value function is optimistically initialized to Qmax, the highest value that any state-action can take. If k is set appropriately (see theorem 5.4), the value function is guaranteed to remain approximately optimistic (approximately represent the most optimistic world consistent with the algorithm’s observations) with high probability. We would like to draw the reader’s attention to two aspects of Median-PAC, both in the way Bellman backups are computed: 1) Instead of taking a simple average over sample values, Median-PAC divides them into km sets, computes the mean over each set, and takes the median of means. 2) Instead of using all the samples available for every state-action, Median-PAC uses samples in batches of a power of 2 times km (line 9). The reasoning behind the first choice follows from the discussion above: using the median of means will allow us to show that Median-PAC’s complexity scales with the variance of the Bellman operator (see definition 5.1) rather than Q2 max. The reasoning behind using samples in batches of increasing powers of 2 is more subtle. A key requirement in the analysis of our algorithm is that samples belonging to the same state-action are independent. While the outcome of sample i does not provide information about the outcome of sample j if i < j (from the Markov property), the fact that j samples exist can reveal information about the outcome of i. If the first i samples led to a severe underestimation of the value of the state-action in question, it is likely that j samples would never have been collected. The fact that they did gives us some information about the outcome of the first i samples. Using samples in batches, and discarding the old batch when a new batch becomes available, ensures that the outcomes of samples within each batch are independent from one another. 5 Analysis Definition 5.1. σσσ is the minimal constant satisfying 8(s, a, ⇡ ˜ Q, ˜Q), sX s0 p(s0|s, a) ⇣ R(s, a, s0) + γ ˜Q(s0, ⇡˜ Q(s0)) −B⇡˜ Q ˜Q(s, a) ⌘2 σ, where 8 ˜Q refers to any value function produced by Median-PAC, rather than any conceivable value function (similarly ⇡˜ Q refers to any greedy policy over ˜Q followed during the execution of Median-PAC rather than any conceivable policy). In the following we will call σ2 σ2 σ2 the variance of the Bellman operator. Note that the variance of the Bellman operator is not the same as the variance, or stochasticity in the transition model of an MDP. A state-action can be highly stochastic (lead to many possible next states), yet if all the states it transitions to have similar values, the variance of its Bellman operator will be small. From Lemmas 5.2, 5.3, and theorem 5.4 below, we have that Median-PAC is efficient PAC-MDP. Lemma 5.2. The space complexity of algorithm 1 is O (k|S||A|). Proof. Follows directly from the fact that at most k samples are stored per state-action. Lemma 5.3. The per step computational complexity of algorithm 1 is bounded above by O ✓k|S||A|2 1 −γ ln Qmax ✏a ◆ . 5 Proof. The proof of this lemma is deferred to the appendix. Theorem 5.4 below is the main theorem of this paper. It decomposes errors into the following three sources: 1. ✏a is the error caused by the fact that we are only finding an ✏a-approximation, rather than the true fixed point of the approximate Bellman operator ˜B, and the fact that we are using only a finite set of samples (at most k) to compute the median of the means, thus we only have an estimate. 2. ✏u is the error caused by underestimating the variance of the MDP. When k is too small and Median-PAC fails to be optimistic, ✏u will be non-zero. ✏u is a measure of how far Median-PAC is from being optimistic (follow the greedy policy over the value function of the most optimistic world consistent with its observations). 3. Finally, ✏e(t) is the error caused by the fact that at time t there may exist state-actions that do not yet have k samples. Theorem 5.4. Let (s1, s2, s3, . . . ) be the random path generated on some execution of Median-PAC, and ˜⇡˜⇡˜⇡be the (non-stationary) policy followed by Median-PAC. Let ✏u = max{0, σp4km −✏a p k}, and ✏a be defined as in algorithm 1. If km = & 50 9 ln 4 log2 4Q2 max ✏2a |SA|2 δ ' , ✏a ✏b p k, 2d 1 1−γ ln (1−γ)Qmax ✏a e2 ln log2 2k km δ km|SA|+1 < 1, and k = 2ikm for some integer i, then with probability at least 1 −δ, for all t V ⇤(st) −V ˜⇡(st) 2✏u + 5✏a 1 −γ + ✏e(t), (1) where 1 X t=0 ✏e(t) < c0 ✓✓ 2km + log2 2k km ◆ Qmax + ✏ak ✓ 8 + 8 p 2 ◆◆ , (2) and c0 = (|SA| + 1) ⇣ 1 + log2 l 1 1−γ ln (1−γ)Qmax ✏a m⌘l 1 1−γ ln (1−γ)Qmax ✏a m 1 − s 2 l 1 1−γ ln (1−γ)Qmax ✏a m 2 ln log2 2k km δ km|SA|+1 . If k = 2ikm where i is the smallest integer such that 2i ≥4σ2 ✏2a , and ✏0 = (1 −γ)✏a, then with probability at least 1 −δ, for all t V ⇤(st) −V ˜⇡(st) ✏0 + ✏e(t), (3) where5 1 X t=0 ✏e(t) ⇡˜O ✓✓ σ2 ✏0(1 −γ)2 + Qmax 1 −γ ◆ |SA| ◆ . (4) Note that the probability of success holds for all timesteps simultaneously, and P1 t=0 ✏e(t) is an undiscounted infinite sum. Proof. The detailed proof of this theorem is deferred to the appendix. Here we provide a proof sketch: The non-stationary policy of the algorithm can be broken up into fixed policy (and fixed approximate value function) segments. The first step in proving theorem 5.4 is to show that the Bellman error of each state-action at a particular fixed approximate value function segment is acceptable with respect to the number of samples currently available for that state-action with high probability. We use Cantelli’s and McDiarmid’s inequalities to prove this point. This is where the median of means 5f(n) = ˜O(g(n)) is a shorthand for f(n) = O(g(n) logc g(n)) for some constant c. 6 becomes useful, and the main difference between our work and earlier work. We then combine the result from the median of means, the fact that there are only a small number of possible policy and approximate value function changes that can happen during the lifetime of the algorithm, and the union bound, to prove that the Bellman error of all state-actions during all timesteps is acceptable with high probability. We subsequently prove that due to the optimistic nature of Median-PAC, at every time-step it will either perform well, or learn something new about the environment with high probability. Since there is only a finite number of things it can learn, the total cost of exploration for Median-PAC will be small with high probability. A typical “number of suboptimal steps” sample complexity bound follows as a simple corollary of theorem 5.4. If the total cost of exploration is P1 t=0 ✏e(t) for an ✏0-optimal policy, there can be no more than P1 t=0 ✏e(t) ✏1 steps that are more than (✏0 + ✏1)-suboptimal. Note that the sample complexity of Median-PAC depends log-linearly on Qmax, which can be finite even if Rmax is infinite. Consider for example an MDP for which the reward at every state-action follows a Gaussian distribution (for discrete MDPs this example requires rewards to be stochastic, while for continuous MDPs rewards can be a deterministic function of state-action-nextstate since there can be an infinite number of possible nextstates for every state-action). If the mean of the reward for every state-action is bounded above by c, Qmax is bounded above by c 1−γ , even though Rmax is infinite. As we can see from theorem 5.4, apart from being the first PAC exploration algorithm that can be applied to MDPs with unbounded rewards, Median-PAC offers significant advantages over the current state of the art for MDPs with bounded rewards. Until recently, the algorithm with the best known sample complexity for the discrete state-action setting was MORMAX, an algorithm by Szita and Szepesvári [16]. Theorem 5.4 offers an improvement of 1 (1−γ)2 even in the worst case, and trades a factor of Q2 max for a (potentially much smaller) factor of σ2. A recent algorithm by Pazis and Parr [12] currently offers the best known bounds for PAC exploration without additional assumptions on the number of states that each action can transition to. Compared to that work we trade a factor of Q2 max for a factor of σ2. 5.1 Using Median-PAC when σ is not known In many practical situations σ will not be known. Instead the user will have a fixed exploration cost budget, a desired maximum probability of failure δ, and a desired maximum error ✏a. Given δ we can solve for the number of sets as km = & 50 9 ln 4 log2 4Q2 max ✏2a |SA|2 δ ' , at which point all variables in equation 2 except for k are known, and we can solve for k. When the sampling budget is large enough such that k ≥4σ2km ✏2 a , then ✏u in equation 1 will be zero. Otherwise ✏u = σp4km −✏a p k. 5.2 Beyond the discrete state-action setting Recent work has extended PAC exploration to the continuous state [11] concurrent exploration [4] and delayed update [12] settings. The goal in the concurrent exploration setting is to explore in multiple identical or similar MDPs and incur low aggregate exploration cost over all MDPs. For a concurrent algorithm to offer an improvement over non-concurrent exploration, the aggregate cost must be lower than the cost of non-concurrent exploration times the number of tasks. The delayed update setting takes into account the fact that in real world domains, reaching a fixed point after collecting a new sample can take longer that the time between actions. Contrary to other work that has exploited the variance of MDPs to improve bounds on PAC exploration [7, 3] our analysis does not make assumptions about the number of possible next states from a given action. As such, Median-PAC and its bounds are easily extensible to the continuous state, concurrent exploration, delayed update setting. Replacing the average over samples in an approximation unit with the median of means over samples in an approximation unit in the algorithm of Pazis and Parr [12], improves their bounds (which are the best published bounds for PAC exploration in these settings) by (Rmax + γQmax)2 while introducing a factor of σ2. 7 6 Experimental evaluation We compared Median-PAC against the algorithm of Pazis and Parr [12] on a simple 5 by 5 gridworld (see appendix for more details). The agent has four actions: move one square up, down, left, or right. All actions have a 1% probability of self-transition with a reward of 100. Otherwise the agent moves in the chosen direction and receives a reward of 0, unless its action causes it to land on the top-right corner, in which case it receives a reward of 1. The world wraps around and the agent always starts at the center. The optimal policy for this domain is to take the shortest path to the top-right corner if at a state other than the top-right corner, and take any action while at the top-right corner. While the probability of any individual sample being a self-transition is small, unless the number of samples per state-action is very large, the probability that there will exist at least one state-action with significantly more than 1 100 sampled self-transitions is high. As a result, the naive average algorithm frequently produced a policy that maximized the probability of encountering state-actions with more than 1 100 sampled self-transitions. By contrast, it is far less likely that there will exist a state-action for which at least half of the sets used by the median of means have more than 1 100 sampled self-transitions. Median-PAC was able to consistently find the optimal policy. 7 Related Work Maillard, Mann, and Mannor [8] present the distribution norm, a measure of hardness of an MDP. Similarly to our definition of the variance of the Bellman operator, the distribution norm does not directly depend on the stochasticity of the underlying transition model. It would be interesting to see if the distribution norm (or a similar concept) can be used to improve PAC exploration bounds for “easy” MDPs. While to the best our knowledge our work is the first in PAC exploration for MDPs that introduces a measure of hardness for MDPs (the variance of the Bellman operator), measures of hardness have been previously used in regret analysis [6]. Such measures include the diameter of an MDP [6], the one way diameter [2], as well as the span [2]. These measures express how hard it is to reach any state of an MDP from any other state. A major advantage of sample complexity over regret is that finite diameter is not required to prove PAC bounds. Nevertheless, if introducing a requirement for a finite diameter could offer drastically improved PAC bounds, it may be worth the trade-off for certain classes of problems. Note that variance and diameter of an MDP appear to be orthogonal. One can construct examples of arbitrary diameter and then manipulate the variance by changing the reward function and/or discount factor. Another measure of hardness which was recently introduced in regret analysis is the Eluder dimension. Osband and Van Roy [10] show that if an MDP can be parameterized within some known function class, regret bounds that scale with the dimensionality, rather than cardinality of the underlying MDP can be obtained. Like the diameter, the Eluder dimension appears to be orthogonal to the variance of the Bellman operator, potentially allowing for the two concepts to be combined. Lattimore and Hutter [7] have presented an algorithm that can match the best known lower bounds for PAC exploration up to logarithmic factors for the case of discrete MDPs where every state-action can transition to at most two next states. To the best of our knowledge there has been no work in learning with unbounded rewards. Harrison [5] has examined the feasibility of planning with unbounded rewards. Acknowledgments We would like to thank Emma Brunskill, Tor Lattimore, and Christoph Dann for spotting an error in an earlier version of this paper, as well as the anonymous reviewers for helpful comments and suggestions. This material is based upon work supported in part by The Boeing Company, by ONR MURI Grant N000141110688, and by the National Science Foundation under Grant No. IIS1218931. Opinions, findings, conclusions or recommendations herein are those of the authors and not necessarily those of the NSF. 8 References [1] N Alon, Y Matias, and M Szegedy. The space complexity of approximating the frequency moments. Journal of Computer and System Sciences - JCSS (special issue of selected papers from STOC’96), 58:137–147, 1999. [2] Peter L. Bartlett and Ambuj Tewari. REGAL: A regularization based algorithm for reinforcement learning in weakly communicating MDPs. In Proceedings of the 25th Conference on Uncertainty in Artificial Intelligence (UAI2009), pages 35–42, June 2009. [3] Christoph Dann and Emma Brunskill. Sample complexity of episodic fixed-horizon reinforcement learning. Advances in Neural Information Processing Systems, 2015. [4] Zhaohan Guo and Emma Brunskill. Concurrent PAC RL. In AAAI Conference on Artificial Intelligence, pages 2624–2630, 2015. [5] J. Michael Harrison. Discrete dynamic programming with unbounded rewards. The Annals of Mathematical Statistics, 43(2):636–644, 04 1972. [6] Thomas Jaksch, Ronald Ortner, and Peter Auer. Near-optimal regret bounds for reinforcement learning. Journal of Machine Learning Research, 11:1563–1600, August 2010. [7] Tor Lattimore and Marcus Hutter. PAC bounds for discounted MDPs. In Proceedings of the 23th International Conference on Algorithmic Learning Theory, volume 7568 of Lecture Notes in Computer Science, pages 320–334. Springer Berlin / Heidelberg, 2012. [8] Odalric-Ambrym Maillard, Timothy A Mann, and Shie Mannor. How hard is my MDP?” the distribution-norm to the rescue”. In Advances in Neural Information Processing Systems 27, page 1835–1843. 2014. [9] C. McDiarmid. On the method of bounded differences. In Surveys in Combinatorics, number 141 in London Mathematical Society Lecture Note Series, pages 148–188. Cambridge University Press, August 1989. [10] Ian Osband and Benjamin Van Roy. Model-based reinforcement learning and the eluder dimension. In Z. Ghahramani, M. Welling, C. Cortes, N. D. Lawrence, and K. Q. Weinberger, editors, Advances in Neural Information Processing Systems 27, pages 1466–1474. 2014. [11] Jason Pazis and Ronald Parr. PAC optimal exploration in continuous space Markov decision processes. In AAAI Conference on Artificial Intelligence, pages 774–781, July 2013. [12] Jason Pazis and Ronald Parr. Efficient PAC-optimal exploration in concurrent, continuous state MDPs with delayed updates. In AAAI Conference on Artificial Intelligence, February 2016. [13] Martin L. Puterman. Markov Decision Processes: Discrete Stochastic Dynamic Programming. Wiley-Interscience, April 1994. [14] Alexander L. Strehl, Lihong Li, and Michael L. Littman. Reinforcement learning in finite MDPs: PAC analysis. Journal of Machine Learning Research, 10:2413–2444, December 2009. [15] Richard Sutton and Andrew Barto. Reinforcement Learning: An Introduction. The MIT Press, Cambridge, Massachusetts, 1998. [16] Istvan Szita and Csaba Szepesvári. Model-based reinforcement learning with nearly tight exploration complexity bounds. In International Conference on Machine Learning, pages 1031–1038, 2010. 9 | 2016 | 47 |
6,405 | f-GAN: Training Generative Neural Samplers using Variational Divergence Minimization Sebastian Nowozin, Botond Cseke, Ryota Tomioka Machine Intelligence and Perception Group Microsoft Research {Sebastian.Nowozin, Botond.Cseke, ryoto}@microsoft.com Abstract Generative neural samplers are probabilistic models that implement sampling using feedforward neural networks: they take a random input vector and produce a sample from a probability distribution defined by the network weights. These models are expressive and allow efficient computation of samples and derivatives, but cannot be used for computing likelihoods or for marginalization. The generativeadversarial training method allows to train such models through the use of an auxiliary discriminative neural network. We show that the generative-adversarial approach is a special case of an existing more general variational divergence estimation approach. We show that any f-divergence can be used for training generative neural samplers. We discuss the benefits of various choices of divergence functions on training complexity and the quality of the obtained generative models. 1 Introduction Probabilistic generative models describe a probability distribution over a given domain X, for example a distribution over natural language sentences, natural images, or recorded waveforms. Given a generative model Q from a class Q of possible models we are generally interested in performing one or multiple of the following operations: • Sampling. Produce a sample from Q. By inspecting samples or calculating a function on a set of samples we can obtain important insight into the distribution or solve decision problems. • Estimation. Given a set of iid samples {x1, x2, . . . , xn} from an unknown true distribution P, find Q ∈Q that best describes the true distribution. • Point-wise likelihood evaluation. Given a sample x, evaluate the likelihood Q(x). Generative-adversarial networks (GAN) in the form proposed by [10] are an expressive class of generative models that allow exact sampling and approximate estimation. The model used in GAN is simply a feedforward neural network which receives as input a vector of random numbers, sampled, for example, from a uniform distribution. This random input is passed through each layer in the network and the final layer produces the desired output, for example, an image. Clearly, sampling from a GAN model is efficient because only one forward pass through the network is needed to produce one exact sample. Such probabilistic feedforward neural network models were first considered in [22] and [3], here we call these models generative neural samplers. GAN is also of this type, as is the decoder model of a variational autoencoder [18]. In the original GAN paper the authors show that it is possible to estimate neural samplers by approximate minimization of the symmetric Jensen-Shannon divergence, DJS(P∥Q) = 1 2DKL(P∥1 2(P + Q)) + 1 2DKL(Q∥1 2(P + Q)), (1) where DKL denotes the Kullback-Leibler divergence. The key technique used in the GAN training is that of introducing a second “discriminator” neural networks which is optimized simultaneously. 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. Because DJS(P∥Q) is a proper divergence measure between distributions this implies that the true distribution P can be approximated well in case there are sufficient training samples and the model class Q is rich enough to represent P. In this work we show that the principle of GANs is more general and we can extend the variational divergence estimation framework proposed by Nguyen et al. [25] to recover the GAN training objective and generalize it to arbitrary f-divergences. More concretely, we make the following contributions over the state-of-the-art: • We derive the GAN training objectives for all f-divergences and provide as example additional divergence functions, including the Kullback-Leibler and Pearson divergences. • We simplify the saddle-point optimization procedure of Goodfellow et al. [10] and provide a theoretical justification. • We provide experimental insight into which divergence function is suitable for estimating generative neural samplers for natural images. 2 Method We first review the divergence estimation framework of Nguyen et al. [25] which is based on f-divergences. We then extend this framework from divergence estimation to model estimation. 2.1 The f-divergence Family Statistical divergences such as the well-known Kullback-Leibler divergence measure the difference between two given probability distributions. A large class of different divergences are the so called f-divergences [5, 21], also known as the Ali-Silvey distances [1]. Given two distributions P and Q that possess, respectively, an absolutely continuous density function p and q with respect to a base measure dx defined on the domain X, we define the f-divergence, Df(P∥Q) = Z X q(x)f p(x) q(x) dx, (2) where the generator function f : R+ →R is a convex, lower-semicontinuous function satisfying f(1) = 0. Different choices of f recover popular divergences as special cases in (2). We illustrate common choices in Table 1. See supplementary material for more divergences and plots. 2.2 Variational Estimation of f-divergences Nguyen et al. [25] derive a general variational method to estimate f-divergences given only samples from P and Q. An equivalent result has also been derived by Reid and Williamson [28]. We will extend these results from merely estimating a divergence for a fixed model to estimating model parameters. We call this new method variational divergence minimization (VDM) and show that generative-adversarial training is a special case of our VDM framework. For completeness, we first provide a self-contained derivation of Nguyen et al’s divergence estimation procedure. Every convex, lower-semicontinuous function f has a convex conjugate function f ∗, also known as Fenchel conjugate [15]. This function is defined as f ∗(t) = sup u∈domf {ut −f(u)} . (3) The function f ∗is again convex and lower-semicontinuous and the pair (f, f ∗) is dual to another in the sense that f ∗∗= f. Therefore, we can also represent f as f(u) = supt∈domf∗{tu −f ∗(t)}. Nguyen et al. leverage the above variational representation of f in the definition of the f-divergence to obtain a lower bound on the divergence, Df(P∥Q) = R X q(x) sup t∈domf∗ n t p(x) q(x) −f ∗(t) o dx ≥supT ∈T R X p(x) T(x) dx − R X q(x) f ∗(T(x)) dx = sup T ∈T (Ex∼P [T(x)] −Ex∼Q [f ∗(T(x))]) , (4) 2 Name Df(P∥Q) Generator f(u) T ∗(x) Kullback-Leibler R p(x) log p(x) q(x) dx u log u 1 + log p(x) q(x) Reverse KL R q(x) log q(x) p(x) dx −log u −q(x) p(x) Pearson χ2 R (q(x)−p(x))2 p(x) dx (u −1)2 2( p(x) q(x) −1) Squared Hellinger R p p(x) − p q(x) 2 dx (√u −1)2 ( q p(x) q(x) −1) · q q(x) p(x) Jensen-Shannon 1 2 R p(x) log 2p(x) p(x)+q(x) + q(x) log 2q(x) p(x)+q(x) dx −(u + 1) log 1+u 2 + u log u log 2p(x) p(x)+q(x) GAN R p(x) log 2p(x) p(x)+q(x) + q(x) log 2q(x) p(x)+q(x) dx −log(4) u log u −(u + 1) log(u + 1) log p(x) p(x)+q(x) Table 1: List of f-divergences Df(P∥Q) together with generator functions. Part of the list of divergences and their generators is based on [26]. For all divergences we have f : domf →R ∪{+∞}, where f is convex and lower-semicontinuous. Also we have f(1) = 0 which ensures that Df(P∥P) = 0 for any distribution P. As shown by [10] GAN is related to the Jensen-Shannon divergence through DGAN = 2DJS −log(4). where T is an arbitrary class of functions T : X →R. The above derivation yields a lower bound because the class of functions T may contain only a subset of all possible functions. By taking the variation of the lower bound in (4) w.r.t. T, we find that under mild conditions on f [25], the bound is tight for T ∗(x) = f ′ p(x) q(x) , (5) where f ′ denotes the first order derivative of f. This condition can serve as a guiding principle for choosing f and designing the class of functions T . For example, the popular reverse Kullback-Leibler divergence corresponds to f(u) = −log(u) resulting in T ∗(x) = −q(x)/p(x), see Table 1. We list common f-divergences in Table 1 and provide their Fenchel conjugates f ∗and the domains domf ∗in Table 2. We provide plots of the generator functions and their conjugates in the supplementary materials. 2.3 Variational Divergence Minimization (VDM) We now use the variational lower bound (4) on the f-divergence Df(P∥Q) in order to estimate a generative model Q given a true distribution P. To this end, we follow the generative-adversarial approach [10] and use two neural networks, Q and T. Q is our generative model, taking as input a random vector and outputting a sample of interest. We parametrize Q through a vector θ and write Qθ. T is our variational function, taking as input a sample and returning a scalar. We parametrize T using a vector ω and write Tω. We can train a generative model Qθ by finding a saddle-point of the following f-GAN objective function, where we minimize with respect to θ and maximize with respect to ω, F(θ, ω) = Ex∼P [Tω(x)] −Ex∼Qθ [f ∗(Tω(x))] . (6) To optimize (6) on a given finite training data set, we approximate the expectations using minibatch samples. To approximate Ex∼P [·] we sample B instances without replacement from the training set. To approximate Ex∼Qθ[·] we sample B instances from the current generative model Qθ. 2.4 Representation for the Variational Function To apply the variational objective (6) for different f-divergences, we need to respect the domain domf ∗of the conjugate functions f ∗. To this end, we assume that variational function Tω is represented in the form Tω(x) = gf(Vω(x)) and rewrite the saddle objective (6) as follows: F(θ, ω) = Ex∼P [gf(Vω(x))] + Ex∼Qθ [−f ∗(gf(Vω(x)))] , (7) where Vω : X →R without any range constraints on the output, and gf : R →domf ∗is an output activation function specific to the f-divergence used. In Table 2 we propose suitable output activation functions for the various conjugate functions f ∗and their domains.1 Although the choice of gf is somewhat arbitrary, we choose all of them to be monotone increasing functions so that a large output 1Note that for numerical implementation we recommend directly implementing the scalar function f ∗(gf(·)) robustly instead of evaluating the two functions in sequence; see Figure 1. 3 Name Output activation gf domf ∗ Conjugate f ∗(t) f ′(1) Kullback-Leibler (KL) v R exp(t −1) 1 Reverse KL −exp(−v) R− −1 −log(−t) −1 Pearson χ2 v R 1 4t2 + t 0 Squared Hellinger 1 −exp(−v) t < 1 t 1−t 0 Jensen-Shannon log(2) −log(1 + exp(−v)) t < log(2) −log(2 −exp(t)) 0 GAN −log(1 + exp(−v)) R− −log(1 −exp(t)) −log(2) Table 2: Recommended final layer activation functions and critical variational function level defined by f ′(1). The critical value f ′(1) can be interpreted as a classification threshold applied to T(x) to distinguish between true and generated samples. −6 −4 −2 0 2 4 6 −10 −5 0 5 10 gf(v) KL Reverse KL Pearson Â2 Squared Hellinger Jensen-Shannon GAN −6 −4 −2 0 2 4 6 −10 −5 0 5 10 ¡f ¤ (gf(v)) KL Reverse KL Pearson Â2 Squared Hellinger Jensen-Shannon GAN Figure 1: The two terms in the saddle objective (7) are plotted as a function of the variational function Vω(x). Vω(x) corresponds to the belief of the variational function that the sample x comes from the data distribution P as in the GAN case; see Figure 1. It is also instructive to look at the second term −f ∗(gf(v)) in the saddle objective (7). This term is typically (except for the Pearson χ2 divergence) a decreasing function of the output Vω(x) favoring variational functions that output negative numbers for samples from the generator. We can see the GAN objective, F(θ, ω) = Ex∼P [log Dω(x)] + Ex∼Qθ [log(1 −Dω(x))] , (8) as a special instance of (7) by identifying each terms in the expectations of (7) and (8). In particular, choosing the last nonlinearity in the discriminator as the sigmoid Dω(x) = 1/(1 + e−Vω(x)), corresponds to output activation function is gf(v) = −log(1 + e−v); see Table 2. 2.5 Example: Univariate Mixture of Gaussians To demonstrate the properties of the different f-divergences and to validate the variational divergence estimation framework we perform an experiment similar to the one of [24]. Setup. We approximate a mixture of Gaussians by learning a Gaussian distribution. We represent our model Qθ using a linear function which receives a random z ∼N(0, 1) and outputs Gθ(z) = µ+σz, where θ = (µ, σ) are the two scalar parameters to be learned. For the variational function Tω we use a neural network with two hidden layers having 64 units each and tanh activations. We optimize the objective F(ω, θ) by using the single-step gradient method presented in Section 3. In each step we sample batches of size 1024 from p(x) and p(z) and we use a step-size of η = 0.01 for updating both ω and θ. We compare the results to the best fit provided by the exact optimization of Df(P∥Qθ) w.r.t. θ, which is feasible in this case by solving the required integrals in (2) numerically. We use (ˆω, ˆθ) (learned) and θ∗(best fit) to distinguish the parameters sets used in these two approaches. Results. The left side of Table 3 shows the optimal divergence and objective values Df(P||Qθ∗) and F(ˆω, ˆθ) as well as the corresponding (optimal) means and standard deviations. Note that the results are in line with the lower bound property, having Df(P||Qθ∗) ≥F(ˆω, ˆθ). There is a good correspondence between the gap in objectives and the difference between the fitted means and standard deviations. The right side of Table 3 shows the results of the following experiment: (1) we train Tω and Qθ using a particular divergence, then (2) we estimate the divergence and re-train Tω while keeping Qθ fixed. As expected, Qθ performs best on the divergence it was trained with. We present further details and plots of the fitted Gaussians and variational functions in the supplementary materials. 4 KL KL-rev JS Jeffrey Pearson Df (P ||Qθ∗) 0.2831 0.2480 0.1280 0.5705 0.6457 F (ˆω, ˆθ) 0.2801 0.2415 0.1226 0.5151 0.6379 µ∗ 1.0100 1.5782 1.3070 1.3218 0.5737 ˆµ 1.0335 1.5624 1.2854 1.2295 0.6157 σ∗ 1.8308 1.6319 1.7542 1.7034 1.9274 ˆσ 1.8236 1.6403 1.7659 1.8087 1.9031 train \ test KL KL-rev JS Jeffrey Pearson KL 0.2808 0.3423 0.1314 0.5447 0.7345 KL-rev 0.3518 0.2414 0.1228 0.5794 1.3974 JS 0.2871 0.2760 0.1210 0.5260 0.92160 Jeffrey 0.2869 0.2975 0.1247 0.5236 0.8849 Pearson 0.2970 0.5466 0.1665 0.7085 0.648 Table 3: Gaussian approximation of a mixture of Gaussians. Left: optimal objectives, and the learned mean and the standard deviation: ˆθ = (ˆµ, ˆσ) (learned) and θ∗= (µ∗, σ∗) (best fit). Right: objective values to the true distribution for each trained model. For each divergence, the lowest objective function value is achieved by the model that was trained for this divergence. In summary, our results demonstrate that when the generative model is misspecified, the divergence function used for estimation has a strong influence on which model is learned. 3 Algorithms for Variational Divergence Minimization (VDM) We now discuss numerical methods to find saddle points of the objective (6). To this end, we distinguish two methods; first, the alternating method originally proposed by Goodfellow et al. [10], and second, a more direct single-step optimization procedure. In our variational framework, the alternating gradient method can be described as a double-loop method; the internal loop tightens the lower bound on the divergence, whereas the outer loop improves the generator model. While the motivation for this method is plausible, in practice a popular choice is taking a single step in the inner loop, requiring two backpropagation passes for one outer iteration. Goodfellow et al. [10] provide a local convergence guarantee. 3.1 Single-Step Gradient Method Motivated by the success of the alternating gradient method with a single inner step, we propose an even simpler algorithm shown in Algorithm 1. The algorithm differs from the original one in that there is no inner loop and the gradients with respect to ω and θ are computed in a single back-propagation. Algorithm 1 Single-Step Gradient Method 1: function SINGLESTEPGRADIENTITERATION(P, θt, ωt, B, η) 2: Sample XP = {x1, . . . , xB} and XQ = {x′ 1, . . . , x′ B}, from P and Qθt, respectively. 3: Update: ωt+1 = ωt + η ∇ωF(θt, ωt). 4: Update: θt+1 = θt −η ∇θF(θt, ωt). 5: end function Analysis. Here we show that Algorithm 1 geometrically converges to a saddle point (θ∗, ω∗) if there is a neighborhood around the saddle point in which F is strongly convex in θ and strongly concave in ω. These assumptions are similar to those made in [10]. Formally, we assume: ∇θF(θ∗, ω∗) = 0, ∇ωF(θ∗, ω∗) = 0, ∇2 θF(θ, ω) ⪰δI, ∇2 ωF(θ, ω) ⪯−δI, (9) for (θ, ω) in the neighborhood of (θ∗, ω∗). Note that although there could be many saddle points that arise from the structure of deep networks [6], they would not qualify as the solution of our variational framework under these assumptions. For convenience, let’s define πt = (θt, ωt). Now the convergence of Algorithm 1 can be stated as follows (the proof is given in the supplementary material): Theorem 1. Suppose that there is a saddle point π∗= (θ∗, ω∗) with a neighborhood that satisfies conditions (9). Moreover, we define J(π) = 1 2∥∇F(π)∥2 2 and assume that in the above neighborhood, F is sufficiently smooth so that there is a constant L > 0 such that ∥∇J(π′)−∇J(π)∥2 ≤L∥π′−π∥2 for any π, π′ in the neighborhood of π∗. Then using the step-size η = δ/L in Algorithm 1, we have J(πt) ≤ 1 −δ2 L t J(π0). 5 That is, the squared norm of the gradient ∇F(π) decreases geometrically. 3.2 Practical Considerations Here we discuss principled extensions of the heuristic proposed in [10] and real/fake statistics discussed by Larsen and Sønderby2. Furthermore we discuss practical advice that slightly deviate from the principled viewpoint. Goodfellow et al. [10] noticed that training GAN can be significantly sped up by maximizing Ex∼Qθ [log Dω(x)] instead of minimizing Ex∼Qθ [log (1 −Dω(x))] for updating the generator. In the more general f-GAN Algorithm (1) this means that we replace line 4 with the update θt+1 = θt + η ∇θEx∼Qθt [gf(Vωt(x))], (10) thereby maximizing the variational function output on the generated samples. We can show that this transformation preserves the stationary point as follows (which is a generalization of the argument in [10]): note that the only difference between the original direction (line 4) and (10) is the scalar factor f ∗′(Tω(x)), which is the derivative of the conjugate function f ∗. Since f ∗′ is the inverse of f ′ (see Cor. 1.4.4, Chapter E, [15]), if T = T ∗, using (5), we can see that this factor would be the density ratio p(x)/q(x), which would be one at the stationary point. We found this transformation useful also for other divergences. We found Adam [17] and gradient clipping to be useful especially in the large scale experiment on the LSUN dataset. The original implementation [10] of GANs3 and also Larsen and Sønderby monitor certain real and fake statistics, which are defined as the true positive and true negative rates of the variational function viewing it as a binary classifier. Since our output activation gf are all monotone, we can derive similar statistics for any f-divergence by only changing the decision threshold. Due to the link between the density ratio and the variational function (5), the threshold lies at f ′(1) (see Table 2). That is, we can interpret the output of the variational function as classifying the input x as a true sample if the variational function Tω(x) is larger than f ′(1), and classifying it as a generator sample otherwise. 4 Experiments We now train generative neural samplers based on VDM on the MNIST and LSUN datasets. MNIST Digits. We use the MNIST training data set (60,000 samples, 28-by-28 pixel images) to train the generator and variational function model proposed in [10] for various f-divergences. With z ∼Uniform100(−1, 1) as input, the generator model has two linear layers each followed by batch normalization and ReLU activation and a final linear layer followed by the sigmoid function. The variational function Vω(x) has three linear layers with exponential linear unit [4] in between. The final activation is specific to each divergence and listed in Table 2. As in [27] we use Adam with a learning rate of α = 0.0002 and update weight β = 0.5. We use a batchsize of 4096, sampled from the training set without replacement, and train each model for one hour. We also compare against variational autoencoders [18] with 20 latent dimensions. Results and Discussion. We evaluate the performance using the kernel density estimation (Parzen window) approach used in [10]. To this end, we sample 16k images from the model and estimate a Parzen window estimator using an isotropic Gaussian kernel bandwidth using three fold cross validation. The final density model is used to evaluate the average log-likelihood on the MNIST test set (10k samples). We show the results in Table 4, and some samples from our models in Figure 2. The use of the KDE approach to log-likelihood estimation has known deficiencies [33]. In particular, for the dimensionality used in MNIST (d = 784) the number of model samples required to obtain accurate log-likelihood estimates is infeasibly large. We found a large variability (up to 50 nats) between multiple repetitions. As such the results are not entirely conclusive. We also trained the same KDE estimator on the MNIST training set, achieving a significantly higher holdout likelihood. However, it is reassuring to see that the model trained for the Kullback-Leibler divergence indeed achieves a high holdout likelihood compared to the GAN model. 2http://torch.ch/blog/2015/11/13/gan.html 3Available at https://github.com/goodfeli/adversarial 6 Training divergence KDE ⟨LL⟩(nats) ± SEM Kullback-Leibler 416 5.62 Reverse Kullback-Leibler 319 8.36 Pearson χ2 429 5.53 Neyman χ2 300 8.33 Squared Hellinger -708 18.1 Jeffrey -2101 29.9 Jensen-Shannon 367 8.19 GAN 305 8.97 Variational Autoencoder [18] 445 5.36 KDE MNIST train (60k) 502 5.99 Table 4: Kernel Density Estimation evaluation on the MNIST test data set. Each KDE model is build from 16,384 samples from the learned generative model. We report the mean log-likelihood on the MNIST test set (n = 10, 000) and the standard error of the mean. The KDE MNIST result is using 60,000 MNIST training images to fit a single KDE model. Figure 2: MNIST model samples trained using KL, reverse KL, Hellinger, Jensen from top to bottom. LSUN Natural Images. Through the DCGAN work [27] the generative-adversarial approach has shown real promise in generating natural looking images. Here we use the same architecture as as in [27] and replace the GAN objective with our more general f-GAN objective. We use the large scale LSUN database [35] of natural images of different categories. To illustrate the different behaviors of different divergences we train the same model on the classroom category of images, containing 168,103 images of classroom environments, rescaled and center-cropped to 96-by-96 pixels. Setup. We use the generator architecture and training settings proposed in DCGAN [27]. The model receives z ∈Uniformdrand(−1, 1) and feeds it through one linear layer and three deconvolution layers with batch normalization and ReLU activation in between. The variational function is the same as the discriminator architecture in [27] and follows the structure of a convolutional neural network with batch normalization, exponential linear units [4] and one final linear layer. Results. Figure 3 shows 16 random samples from neural samplers trained using GAN, KL, and squared Hellinger divergences. All three divergences produce equally realistic samples. Note that the difference in the learned distribution Qθ arise only when the generator model is not rich enough. (a) GAN (b) KL (c) Squared Hellinger Figure 3: Samples from three different divergences. 5 Related Work We now discuss how our approach relates to existing work. Building generative models of real world distributions is a fundamental goal of machine learning and much related work exists. We only discuss work that applies to neural network models. 7 Mixture density networks [2] are neural networks which directly regress the parameters of a finite parametric mixture model. When combined with a recurrent neural network this yields impressive generative models of handwritten text [12]. NADE [19] and RNADE [34] perform a factorization of the output using a predefined and somewhat arbitrary ordering of output dimensions. The resulting model samples one variable at a time conditioning on the entire history of past variables. These models provide tractable likelihood evaluations and compelling results but it is unclear how to select the factorization order in many applications . Diffusion probabilistic models [31] define a target distribution as a result of a learned diffusion process which starts at a trivial known distribution. The learned model provides exact samples and approximate log-likelihood evaluations. Noise contrastive estimation (NCE) [14] is a method that estimates the parameters of unnormalized probabilistic models by performing non-linear logistic regression to discriminate the data from artificially generated noise. NCE can be viewed as a special case of GAN where the discriminator is constrained to a specific form that depends on the model (logistic regression classifier) and the generator (kept fixed) is providing the artificially generated noise (see supplementary material). The generative neural sampler models of [22] and [3] did not provide satisfactory learning methods; [22] used importance sampling and [3] expectation maximization. The main difference to GAN and to our work really is in the learning objective, which is effective and computationally inexpensive. Variational auto-encoders (VAE) [18, 29] are pairs of probabilistic encoder and decoder models which map a sample to a latent representation and back, trained using a variational Bayesian learning objective. The advantage of VAEs is in the encoder model which allows efficient inference from observation to latent representation and overall they are a compelling alternative to f-GANs and recent work has studied combinations of the two approaches [23] As an alternative to the GAN training objective the work [20] and independently [7] considered the use of the kernel maximum mean discrepancy (MMD) [13, 9] as a training objective for probabilistic models. This objective is simpler to train compared to GAN models because there is no explicitly represented variational function. However, it requires the choice of a kernel function and the reported results so far seem slightly inferior compared to GAN. MMD is a particular instance of a larger class of probability metrics [32] which all take the form D(P, Q) = supT ∈T |Ex∼P [T(x)] −Ex∼Q[T(x)]|, where the function class T is chosen in a manner specific to the divergence. Beyond MMD other popular metrics of this form are the total variation metric (also an f-divergence), the Wasserstein distance, and the Kolmogorov distance. A previous attempt to enable minimization of the KL-divergence in deep generative models is due to Goodfellow et al. [11], where an approximation to the gradient of the KL divergence is derived. In [16] another generalization of the GAN objective is proposed by using an alternative JensenShannon divergence that interpolates between the KL and the reverse KL divergence and has JensenShannon as its mid-point. We discuss this work in more detail in the supplementary materials. 6 Discussion Generative neural samplers offer a powerful way to represent complex distributions without limiting factorizing assumptions. However, while the purely generative neural samplers as used in this paper are interesting their use is limited because after training they cannot be conditioned on observed data and thus are unable to provide inferences. We believe that in the future the true benefits of neural samplers for representing uncertainty will be found in discriminative models and our presented methods extend readily to this case by providing additional inputs to both the generator and variational function as in the conditional GAN model [8]. We hope that the practical difficulties of training with saddle point objectives are not an underlying feature of the model but instead can be overcome with novel optimization algorithms. Further investigations, such as [30], are needed to investigate and hopefully overcome these difficulties. Acknowledgements. We thank Ferenc Husz´ar for discussions on the generative-adversarial approach. 8 References [1] S. M. Ali and S. D. Silvey. A general class of coefficients of divergence of one distribution from another. JRSS (B), pages 131–142, 1966. [2] C. M. Bishop. Mixture density networks. Technical report, Aston University, 1994. [3] C. M. Bishop, M. Svens´en, and C. K. I. Williams. GTM: The generative topographic mapping. Neural Computation, 10(1):215–234, 1998. [4] D. A. Clevert, T. Unterthiner, and S. Hochreiter. Fast and accurate deep network learning by exponential linear units (ELUs). arXiv:1511.07289, 2015. [5] I. Csisz´ar and P. C. Shields. Information theory and statistics: A tutorial. Foundations and Trends in Communications and Information Theory, 1:417–528, 2004. [6] Y. N. Dauphin, R. Pascanu, C. Gulcehre, K. Cho, S. Ganguli, and Y. Bengio. Identifying and attacking the saddle point problem in high-dimensional non-convex optimization. In NIPS, pages 2933–2941, 2014. [7] G. K. Dziugaite, D. M. Roy, and Z. Ghahramani. Training generative neural networks via maximum mean discrepancy optimization. In UAI, pages 258–267, 2015. [8] J. Gauthier. Conditional generative adversarial nets for convolutional face generation. Class Project for Stanford CS231N: Convolutional Neural Networks for Visual Recognition, Winter semester 2014, 2014. [9] T. Gneiting and A. E. Raftery. Strictly proper scoring rules, prediction, and estimation. JASA, 102(477): 359–378, 2007. [10] I. Goodfellow, J. Pouget-Abadie, M. Mirza, B. Xu, D. Warde-Farley, S. Ozair, A. Courville, and Y. Bengio. Generative adversarial nets. In NIPS, pages 2672–2680, 2014. [11] I. J. Goodfellow. On distinguishability criteria for estimating generative models. In International Conference on Learning Representations (ICLR2015), 2015. arXiv:1412.6515. [12] A. Graves. Generating sequences with recurrent neural networks. arXiv:1308.0850, 2013. [13] A. Gretton, K. Fukumizu, C. H. Teo, L. Song, B. Sch¨olkopf, and A. J. Smola. A kernel statistical test of independence. In NIPS, pages 585–592, 2007. [14] M. Gutmann and A. Hyv¨arinen. Noise-contrastive estimation: A new estimation principle for unnormalized statistical models. In AISTATS, pages 297–304, 2010. [15] J. B. Hiriart-Urruty and C. Lemar´echal. Fundamentals of convex analysis. Springer, 2012. [16] F. Husz´ar. How (not) to train your generative model: scheduled sampling, likelihood, adversary? arXiv:1511.05101, 2015. [17] D. Kingma and J. Ba. Adam: A method for stochastic optimization. arXiv:1412.6980, 2014. [18] D. P. Kingma and M. Welling. Auto-encoding variational Bayes. arXiv:1402.0030, 2013. [19] H. Larochelle and I. Murray. The neural autoregressive distribution estimator. In AISTATS, 2011. [20] Y. Li, K. Swersky, and R. Zemel. Generative moment matching networks. In ICML, 2015. [21] F. Liese and I. Vajda. On divergences and informations in statistics and information theory. Information Theory, IEEE, 52(10):4394–4412, 2006. [22] D. J. C. MacKay. Bayesian neural networks and density networks. Nucl. Instrum. Meth. A, 354(1):73–80, 1995. [23] A. Makhzani, J. Shlens, N. Jaitly, and I. Goodfellow. Adversarial autoencoders. arXiv:1511.05644, 2015. [24] T. Minka. Divergence measures and message passing. Technical report, Microsoft Research, 2005. [25] X. Nguyen, M. J. Wainwright, and M. I. Jordan. Estimating divergence functionals and the likelihood ratio by convex risk minimization. Information Theory, IEEE, 56(11):5847–5861, 2010. [26] F. Nielsen and R. Nock. On the chi-square and higher-order chi distances for approximating f-divergences. Signal Processing Letters, IEEE, 21(1):10–13, 2014. [27] A. Radford, L. Metz, and S. Chintala. Unsupervised representation learning with deep convolutional generative adversarial networks. arXiv:1511.06434, 2015. [28] M. D. Reid and R. C. Williamson. Information, divergence and risk for binary experiments. Journal of Machine Learning Research, 12(Mar):731–817, 2011. [29] D. J. Rezende, S. Mohamed, and D. Wierstra. Stochastic backpropagation and approximate inference in deep generative models. In ICML, pages 1278–1286, 2014. [30] T. Salimans, I. Goodfellow, W. Zaremba, V. Cheung, A. Radford, and X. Chen. Improved techniques for training GANs. In NIPS, 2016. [31] J. Sohl-Dickstein, E. A. Weiss, N. Maheswaranathan, and S. Ganguli. Deep unsupervised learning using non-equilibrium thermodynamics. ICML, pages 2256–2265, 2015. [32] B. K. Sriperumbudur, A. Gretton, K. Fukumizu, B. Sch¨olkopf, and G. Lanckriet. Hilbert space embeddings and metrics on probability measures. JMLR, 11:1517–1561, 2010. [33] L. Theis, A. v.d. Oord, and M. Bethge. A note on the evaluation of generative models. arXiv:1511.01844, 2015. [34] B. Uria, I. Murray, and H. Larochelle. RNADE: The real-valued neural autoregressive density-estimator. In NIPS, pages 2175–2183, 2013. [35] F. Yu, Y. Zhang, S. Song, A. Seff, and J. Xiao. LSUN: Construction of a large-scale image dataset using deep learning with humans in the loop. arXiv:1506.03365, 2015. 9 | 2016 | 470 |
6,406 | Nearly Isometric Embedding by Relaxation James McQueen Department of Statistics University of Washington Seattle, WA 98195 jmcq@u.washington.edu Marina Meil˘a Department of Statistics University of Washington Seattle, WA 98195 mmp@stat.washington.edu Dominique Perrault-Joncas Google Seattle, WA 98103 dcpjoncas@gmail.com Abstract Many manifold learning algorithms aim to create embeddings with low or no distortion (isometric). If the data has intrinsic dimension d, it is often impossible to obtain an isometric embedding in d dimensions, but possible in s > d dimensions. Yet, most geometry preserving algorithms cannot do the latter. This paper proposes an embedding algorithm to overcome this. The algorithm accepts as input, besides the dimension d, an embedding dimension s ≥d. For any data embedding Y, we compute a Loss(Y), based on the push-forward Riemannian metric associated with Y, which measures deviation of Y from from isometry. Riemannian Relaxation iteratively updates Y in order to decrease Loss(Y). The experiments confirm the superiority of our algorithm in obtaining low distortion embeddings. 1 Introduction, background and problem formulation Suppose we observe data points sampled from a smooth manifold M with intrinsic dimension d which is itself a submanifold of D-dimensional Euclidean space M ⊂RD. The task of manifold learning is to provide a mapping φ : M →N (where N ⊂Rs) of the manifold into lower dimensional space s ≪D. According to the Whitney Embedding Theorem [11] we know that M can be embedded smoothly into R2d using one homeomorphism φ. Hence we seek one smooth map φ : M →Rs with d ≤s ≤2d ≪D. Smooth embeddings preserve the topology of the original M. Nevertheless, in general, they distort the geometry. Theoretically speaking1, preserving the geometry of an embedding is embodied in the concepts of Riemannian metric and isometric embedding. A Riemannian metric g is a symmetric positive definite tensor field on M which defines an inner product <, >g on the tangent space TpM for every point p ∈M. A Riemannian manifold is a smooth manifold with a Riemannian metric at every point. A diffeomorphism φ : M →N is called an isometry iff for all p ∈M, u, v ∈TpM we have < u, v >gp=< dφpu, dφpv >hφ(p). By Nash’s Embedding Theorem [13], it is known that any smooth manifold of class Ck, k ≥3 and intrinsic dimension d can be embedded isometrically in the Euclidean space Rs with s polynomial in d. In unsupervised learning, it is standard to assume that (M, g0) is a submanifold of RD and that it inherits the Euclidean metric from it2. An embedding φ : M →φ(M) = N defines a metric g on N given by < u, v >g(φ(p))=< dφ−1u, dφ−1v >g0(p) called the pushforward Riemannian metric; (M, g0) and (N, g) are isometric. Much previous work in non-linear dimension reduction[16, 20, 19] has been driven by the desire to find smooth embeddings of low dimension that are isometric in the limit of large n. This work has met with mixed success. There exists the constructive implementation [19] of Nash’s proof 1For a more complete presentation the reader is referred to [8] or [15] or [10]. 2Sometimes the Riemannian metric on M is not inherited, but user-defined via a kernel or distance function. 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. technique, which guarantees consistence and isometry. However, the algorithm presented falls short of being practical, as the embedding dimension s it requires is significantly higher than the minimum necessary, a major drawback in practice. Overall, the algorithm leads to mappings φ that, albeit having the desired properties, are visually unintuitive, even for intrinsic dimensions as low as d = 1. There are many algorithms, too many for an exhaustive list, which map the data using a cleverly chosen reconstruction criterion. The criterion is chosen so that the mapping φ can be obtained as the unique solution of a “classic” optimization problem, e.g. Eigendecomposition for Laplacian Eigenmaps [2], Diffusion Maps [12] and LTSA [21], Semidefinite Programming for Maximum Variance Unfolding [20] or Multidimensional Scaling for Isomap [3]. These embedding algorithms sometimes come with guarantees of consistency [2] and, only in restricted cases, isometry [3]. In this paper we propose an approach which departs from both these existing directions. The main difference, from the algorithmic point of view, is that the loss function we propose does not have a form amenable to a standard solver (and is not even guaranteed to be convex or unimodal). Thus, we do not obtain a mapping φ in “one shot”, as the previous algorithms do, but by the gradual improvements of an initial guess, i.e. by gradient descent. Nevertheless, the loss we define directly measures the deviation from isometry; therefore, when this loss is (near) 0, (near) isometry is achieved. The algorithm is initialized with a smooth embedding Y = φ(M) ⊆Rs, s ≥d; we define the objective function Loss(Y) as the averaged deviation of the pushforward metric from isometry. Then Y is iteratively changed in a direction that decreases Loss. To construct this loss function, we exploit the results of [15] who showed how a pushforward metric can be estimated, for finite samples and in any given coordinates, using a discrete estimator of the Laplace-Beltrami operator ∆M. The optimization algorithm is outlined in Algorithm 1. Input :data X ∈Rn×D, kernel function Kh(), weights w1:n, intrinsic dimension d, embedding dimension s Initial coordinates Y ∈Rn×s, with Yk,: representing the coordinates of point k. Init :Compute Laplacian matrix L ∈Rn×n using X and Kh(). while not converged do Compute H = [Hk]k=1:n ∈Rn×s×s the (dual) pushforward metric at data points from Y and L. Compute Loss(H1:n) and ∇Y Loss(H) Take a gradient step Y ←Y −η∇Y Loss(H) end Output:Y Algorithm 1: Outline of the Riemannian Relaxation Algorithm. A remark on notation is necessary. Throughout the paper, we denote by M, p∈M, TpM, ∆M a manifold, a point on it, the tangent subspace at p, and the Laplace-Beltrami operator in the abstract, coordinate free form. When we describe algorithms acting on data, we will use coordinate and finite sample representations. The data is X ∈Rn×D, and an embedding thereof is denoted Y ∈Rn×s; rows k of X, Y, denoted Xk, Yk are coordinates of data point k, while the columns, e.g Yj represent functions of the points, i.e restrictions to the data of functions on M. The construction of L (see below) requires a kernel, which can be the (truncated) gaussian kernel Kh(z) = exp(z2/h), |z| < rh for some fixed r > 0 [9, 17]. Besides these, the algorithm is given a set of weights w1:n, P k wk = 1. The construction of the loss is based on two main sets of results that we briefly review here. First, an estimator L of the Laplace-Beltrami operator ∆M of M, and second, an estimator of the pushforward metric g in the current coordinates Y. To construct L we use the method of [4], which guarantees that, if the data are sampled from a manifold M, L converges to ∆M [9, 17]. Given a set of points in high-dimensional Euclidean space RD, represented by the n×D matrix X, construct a weighted neighborhood graph G = ({1 : n}, W) over them, with W = [Wkl]k,l=1:n. The weight Wkl between Xk: and Xl: is the heat kernel [2] Wkl ≡Kh(||Xk: −Xl:||) with h a bandwidth parameter fixed by the user, and || || the Euclidean norm. Next, construct L = [Lkl]ij of G by D= diag(W1) , ˜W = D−1WD−1 , ˜D = diag( ˜W1) , and L = ˜D −1 ˜W (1) Equation (1) represents the discrete versions of the renormalized Laplacian construction from [4]. Note that W, D, ˜D, ˜W, L all depend on the bandwidth h via the heat kernel. The consistency of L has been proved in e.g [9, 17]. 2 The second fact we use is the relationship between the Laplace-Beltrami operator and the Riemannian metric on a manifold [11]. Based on this, [15] gives a a construction method for a discrete estimator of the Riemannian metric g, in any given coordinate system, from an estimate L of ∆M. In a given coordinate representation Y, a Riemannian metric g at each point is an s × s positive semidefinite matrix of rank d. The method of [15] obtains the matrix Moore-Penrose pseudoinverse of this metric (which must be therefore inverted to obtain the pushforward metric). We denote this inverse at point k by Hk; let H = [Hk, k = 1, . . . n] be the three dimensional array containing the inverse for each data point. Note that H is itself the (discrete estimate of) a Riemannian metric, called the dual (pushforward) metric. With these preliminaries, the method of [15] computes H by Hij = 1 2 h L(Yi · Yj) −Yi · (LYj) −Yj · (LYi) i (2) Where here Hij is the vector whose kth entry is the ijth element of the dual pushforward metric H at the point k and · denotes element-by-element multiplication. 2 The objective function Loss The case s = d (embedding dimension equals intrinsic dimension). Under this condition, it can be shown [10] that φ : M →Rd is an isometry iff gp, p ∈M expressed in a normal coordinate system equals the unit matrix Id. Based on this observation, it is natural to measure the quality of the data embedding Y as the departure of the Riemannian metric obtained via (2) from the unit matrix. This is the starting idea for the distortion measure we propose to optimize. We develop it further as follows. First, we choose to use the dual of g, evaluated by H instead of pushforward metric itself. Naturally Hk = Id iff H−1 k = Id, so the dual metric identifies isometry as well. When no isometric transformation exists, it is likely that optimizing w.r.t g and optimizing w.r.t h will arrive to different embeddings. There is no mathematically compelling reason, however, to prefer optimizing one over the other. We choose to optimize w.r.t h for three reasons; (1) it is computationally faster, (2) it is numerically more stable, and (3) in our experience users find H more interpretable. 3 Second, we choose to measure the distortion of Hk by ||Hk−I|| where || || denotes the matrix spectral norm. This choice will be motivated shortly. Third, we choose the weights w1:n to be proportional to ˜D from (1). As [4] show, these values converge to the sampling density π on M. Putting these together, we obtain the loss function Loss(Y; L, w) = n X k=1 wk ||Hk −Id||2 . (3) To motivate the choice of a “squared loss” instead of simply using ||Hk −Id||, notice (the proofs are straightforward) that || || is not differentiable at 0, but || ||2 is. A natural question to ask about Loss is if it is convex. The following proposition proved in the Supplement summarizes a set of relevant convexity facts. Proposition 1 Denote by λ1:d(Hk) ≥0 the eigenvalues of Hk, in decreasing order and assume Y is in a compact, convex set. Then 1. λ1(Hk), λ1(Hk) −λd(Hk) and λ1(Hk) −Pd d′=1 λd′(Hk) are convex in Y. 2. ||Hk −Id|| is convex in Y for (λ1(Hk) + λd(Hk))/2 ≥1 and concave otherwise. 3. ||Hk −Id||2 is convex in Y whenever ||Hk −Id|| is convex and differentiable in Y. This proposition shows that Loss may not be convex near its minimum, and moreover that squaring the loss only improves convexity. Choosing the right measure of distortion The norm of a Hermitian bilinear functional (i.e symmetric tensor of order 2) g : Rs × Rs →R is defined as supu̸=0 |g(u, u)|/||u||. In a fixed orthonormal base of Rs, g(u, v) = u′Gv, ||g|| = supu̸=0 |u′Gu|. One can define norms with respect to any metric g0 on Rs (where g0 is represented in coordinates by G0, a symmetric, positive definite matrix), by ||u||G0 = u′G0u, respectively ||g||G0 = supu̸=0 |u′Gu|/||u||G0 = 3Hk represents the direction & degree of distortion as opposed to the scaling required to “correct" the space. 3 sup˜u̸=0 |˜u′G−1/2 0 GG−1/2 0 ˜u|/||˜u|| = λmax(G−1/2 0 GG−1/2 0 ). In particular, since any Riemannian metric at a point k is a g as above, setting g and g0 respectively to Hk and Id we measure the operator norm of the distortion by ||Hk −Id||. In other words, the appropriate operator norm we seek can be expresed as a matrix spectral norm. The expected loss over the data set, given a distribution represented by the weights w1:n is then identical to the expression of Loss in (3). If the weights are computed as in (1), it is easy to see that the loss function in (3) is the finite sample version of the squared L2 distance between h and g0 on the space of Riemannian metrics on M, w.r.t base measure πdVg0 ||h −g0||2 g0 = Z M ||h −g0||2 g0πdVg0, with dVg0volume element on M. (4) Defining Loss for embeddings with s > d dimensions Consider G, G0 ∈Rs×s, two symmetric matrices with G0 semipositive definite of rank d < s. We would like to extend the G0 norm of G to this case. We start with the family of norms ||||G0+εIs for ǫ > 0 and we define ||G||G0 = lim ǫ→0 ||G||G0+εIs. (5) Proposition 2 Let G, G0 ∈Rs×s be symmetric matrices, with G0 semipositive definite of rank d < s, and let ǫ > 0, γ(u, ε) = u′Gu u′G0u+ǫ||u||2 . Then, 1. ||G||G0+εIs = ||˜G||2 with ˜G = (G0 + ǫI)−1/2G(G0 + ǫI)−1/2. 2. If ||G||G0+εIs < r, then λ†(G) < ǫr with λ†(G) = supv∈Null(G0) γ(v, ε), 3. ||||G0 is a matrix norm that takes infinite values when Null G0 ̸⊆Null G. Hence, || ||G0+εIs can be computed as the spectral norm of a matrix. The computation of || ||G0 is similar, with the additional step of checking first if Null G0 ̸⊆Null G, in which case we output the value ∞. Let Bǫ(0, r) (B(0, r)) denote the r-radius ball centered at 0 in the || ||G0+εIs (|| ||G0). From Proposition 2 it follows that if G ∈Bǫ(0, r) then λ†(G) < ǫr and if G ∈B(0, r) then Null(G0) ⊆Null(G). In particular, if rank G = rank G0 then Null(G) = Null(G0). To define the loss for s > d we set G = Hk and G0 = UkU′ k, with Uk an orthonormal basis for TkM the tangent subspace at k. The norms || ||G0+εIs, || ||G0 act as soft and hard barrier functions constraining the span of Hk to align with the tangent subspace of the data manifold. Loss(Y; L, w, d, εorth) = n X k=1 wk|| (UkU′ k + ε2 orthIs)−1/2 Hk −UkU′ k (UkU′ k + ε2 orthIs)−1/2 | {z } ˜Gk ||2. (6) 3 Optimizing the objective Let Lk denote the kth row of L, then Hk can be rewritten in the convenient form Hk(Y) = 1 2Y′[trace(Lk) −(eke′ kL) −(eke′ kL)′]Y ≡1 2Y′LkY (7) where ek refers to the kth standard basis vector of Rn and Lk is a symmetric positive semi-definite matrix precomputed from entries in L; Lk has non-zero rows only for the neighbors of k. Proposition 3 Let Lossk denote term k of Loss. If s = d, the gradient of Lossk as given by (3) is ∂Lossk ∂Y = 2wkλ∗ kLkYuku′ k, (8) with λ∗ k the largest eigenvalue of Hk −Id and uk is the corresponding eigenvector. If s > d, the gradient of Lossk of (6) is ∂Lossk ∂Y = 2wkλ∗ kLkYΠkuku′ kΠ′ k (9) where Πk = (UkU′ k + (εorth)kIs)−1/2, λ∗ k is the largest eigenvalue of ˜Gk of (6) and uk is the corresponding eigenvector. 4 When embedding in s > d dimensions, the loss function depends at each point k on finding the d-dimensional subspace Uk. Mathematically, this subspace coincides with the span of the Jacobian DYk which can be identified with the d-principal subspace of Hk. When computing the gradient of Loss we assume that U1:n are fixed. Since the derivatives w.r.t Y are taken only of H and not of the tangent subspace Uk, the algorithm below is actually an alternate minimization algorithm, which reduces the cost w.r.t Y in one step, and w.r.t U1:n in the alternate step. 3.1 Algorithm We optimize the loss (3) or (6) by projected gradient descent with line search (subject to the observation above). The projection consists of imposing P k Yk = 0, which we enforce by centering ∇Y before taking a step. This eliminates the degeneracy of the Loss in (3) and (6) w.r.t constant shift in Y. To further improve the good trade-off between time per iteration and number of iterations, we found that a heavy-ball method with parameter α is effective. At each iteration computing the gradient is O((S + s3)n) where S is the number of nonzero entries of L. Input :data X, kernel function Kh(), initial coordinates Y0, weights w1:n, intrinsic dimension d, orthonormal tolerance εorth, heavy ball parameter α ∈[0, 1) Init :Compute: graph Laplacian L by (1), matrices L1:n as in (7). Set S = 0 while not converged do Compute ∇Loss: for all k do 1. Calculate Hk via (2); 2. If s > d (a) Compute Uk by SVD from Hk; (b) Compute gradient of ∇Lossk(Y) using (9); 3. Else (s = d): calculate gradient ∇Lossk(Y) using (8); 4. Add ∇Lossk(Y) to the total gradient; end Take a step in Y: 1. Compute projected direction S and project S ←(In −ene′ n)∇Loss +αS; 2. Find step size η by line search and update Y ←Y −ηS; end Output:Y Algorithm 2: RIEMANNIANRELAXATION (RR) 3.2 For large or noisy data Here we describe an extension of the RR Algorithm which can naturally adapt to large or noisy data, where the manifold assumption holds only approximately. The idea is to subsample the data, but in a highly non-uniform way that improves the estimation of the geometry. A simple peliminary observation is that, when an embedding is smooth, optimizing the loss on a subset of the data will be sufficient. Let I ⊂{1, . . . n} be set of size n′ < n. The subsampled loss LossI will be computed only for the points k′ ∈I. If every point k has O(d) neighbors in I, this assures that the gradient of LossI will be a good approximation of ∇Loss at point k, even if k ̸∈I, and does not have a term containing Hk in LossI. To optimize LossI by RR, it is sufficient to run the “for” loop over k′ ∈I. Algorithm PCS-RR below describes how we choose a “good" subsample I, with the help of the PRINCIPALCURVES algorithm of [14]. Input :data X, kernel function Kh(), initial coordinates Y0, intrinsic dimension d, subsample size n′, other parameters for RR Compute ˆX = PRINCIPALCURVES(X, Kh, d) Take a uniform sample I0 of size n′ from {1, . . . n} (without replacement). for k′ in I0 do Find Xl the nearest neigbor in X of ˆXk′, and add l to I (removing duplicates) end Output:Y = RR(Y0, Kh, d, I, . . .) Algorithm 3: PRINCIPALCURVES-RIEMANNIANRELAXATION (PCS-RR) 5 sphere + noise hourglass + noise final embedding 0 0.005 0.01 0.015 0.02 0.025 −4 −3.5 −3 −2.5 −2 −1.5 −1 noise standard deviation sigma vs. (log10) loss and MSE log10(MSE) log10(loss) Figure 1: Hourglass to sphere. From left to right: target Y (noisy sphere), initialization Y0 of RR (noisy hourglass), output of RR, mean-squared error and Loss vs. noise level σ (on a log10 scale). Convergence of RR was achieved after 400 iterations. Informally speaking, PRINCIPALCURVES uses a form of Mean-Shift to obtain points in the ddimensional manifold of highest density in the data. The result is generally biased, however [7] have shown that this algorithm offers a very advantageous bias-variance trade-off in case of manifolds with noise. We use the output ˆY of PRINCIPALCURVES to find a subset of points that (1) lie in a high density region relative to most directions in RD and (2) are “in the middle” of their neighbors, or more formally, have neighborhoods of dimension at least d. In other words, this is a good heuristic to avoid “border effects”, or other regions where the d-manifold assumption is violated. 4 Experimental evaluation Hourglass to sphere illustrates how the algorithm works for s = 3, d = 2. The data X is sampled uniformly from a sphere of radius 1 with intrinsic dimension d = 2. We sample n = 10000 points from the sphere and add i.i.d. Gaussian noise with Σ = σ2/sIs4, estimating the Laplacian L on the noisy data X. We initialize with a noisy “hourglass” shape in s = 3 dimensions, with the same noise distribution as the sphere. If the algorithm works correctly, by using solely the Laplacian and weights from X, it should morph the hourglass Y0 back into a sphere. The results after convergence at 400 iterations are shown in Fig. 1 (and an animation of this convergence in the Supplement). We see that RR not only recovers the sphere, but it also suppresses the noise. The next two experiments compare RR to several embedding algorithms w.r.t geometric recovery. The algorithms are Isomap, Laplacian Eigenmaps, HLLE[6], MVU 5 . The embeddings YLE,MV U,HLLE need to be rescaled before being evaluated, and we use a Procrustes transformation to the original data. The algorithms are compared w.r.t the dual metric distortion Loss, and w.r.t mean squared errror in pairwise distance (the loss optimized by Isomap 6 ). This is dis(Y, Ytrue) = 2/n(n−1) X k̸=k′ ||Yk −Yk′|| −||Ytrue k −Ytrue k′ || 2 (10) where Y is the embedding resulting from the chosen method and Ytrue are the true noiseless coordinates. Note that none of Isomap, MVU, HLLE could have been tested on the hourglass to sphere data of the previous example, because they work only for s = d. The sample size is n = 3000 in both experiments, and noise is added as described above. Flat “swiss roll” manifold, s = d = 2. The results are displayed in Fig. 2. Curved “half sphere” manifold, s = d = 2. Isometric embedding into 2D is not possible. We examine which of the algorithms achieves the smallest distortions in this scenario. The true distances were computed as arc-lengths on the half-sphere. The results are displayed in Fig 2. RR was initialized at each method. In almost every initalization and noise level, RR achieves a decrease in dis, in some cases significant decreases. Isomap also performs well and even though RR optimizes a different loss function it never increases dis and often improves on it. This demonstrates the ability of the Riemannian Metric to encode simultaneously all aspects of manifold geom4For this artificial noise, adding dimensions beyond s has no effect except to increase σ. 5embeddings were computed using drtoolbox: https://lvdmaaten.github.io/drtoolbox/ 6Isomap estimates the true distances using graph shortest path 6 Isomap RR Laplacian Eigenmaps RR MVU RR HLLE RR 0 0.2 0.4 0.6 0.8 1 1.36 1.38 1.4 1.42 1.44 1.46 1.48 1.5 1.52 1.54 σ average distortion (log10) Leigs Isomap HLLE MVU 0 0.02 0.04 0.06 0.08 0.1 0.12 0.14 0.16 −0.9 −0.8 −0.7 −0.6 −0.5 −0.4 −0.3 −0.2 −0.1 0 σ average distortion (log10) Leigs Isomap HLLE MVU 0 0.2 0.4 0.6 0.8 1 −1 −0.5 0 0.5 1 1.5 σ average loss (log10) Leigs Isomap HLLE MVU 0 0.02 0.04 0.06 0.08 0.1 0.12 0.14 0.16 −0.9 −0.8 −0.7 −0.6 −0.5 −0.4 −0.3 −0.2 −0.1 σ average loss (log10) Leigs Isomap HLLE MVU Figure 2: Swiss hole (left) & half sphere (right). Top plots display example initial embeddings and their Riemannian Relaxed versions. Middle row displays dis value vs. noise level σ. Bottom row displays Loss value vs. noise level σ. As RR was initialized at each method dashed lines indicated relaxed embeddings etry. Convergence of RR varies with the initialization but was in all cases faster than Isomap. The extension of RR to PCS-RR allows for scaling to much larger data sets. 4.1 Visualizing the main SDSS galaxy sample in spectra space The data consists of spectra of galaxies from the Sloan Digital Sky Survey7 [1]. We extracted a subset of spectra whose SNR was sufficiently high, known as the main sample. This set contains 675,000 galaxies observed in D = 3750 spectral bins, preprocessed by first moving them to a common rest-frame wavelength and filling-in missing data following [18] but using the more sophisticated weighted PCA algorithm of [5], before computing a sparse neighborhood graph and pairwise distances between neighbors in this graph. A log-log plot of the average number neighbors m(r) vs. neighborhood radius r (shown in the Supplement), indicates that the intrinsic dimension of these data varies with the scale r. In particular, in order to support m = O(d) neighbors, the radius must be above 60, in which case d ≤3. We embedded the whole data set by Laplacian Eigenmaps, obtaining the graph in Fig. 3 a. This figure strongly suggests that d is not constant for this data cloud, and that the embedding is not isometric (Fig 3, b). We “rescaled” the data along the three evident 7 www.sdss.org 7 a -2 -1.5 -1 -0.5 0 0.5 1 1.5 2 2.5 3 log10(||H||) b c -2 -1.5 -1 -0.5 0 0.5 1 1.5 2 2.5 3 log10(||H||) 0 0.5 1 1.5 2 2.5 3 3.5 4 log10(H α Emission) d Figure 3: a: Initial LE embedding from D = 3750 to s = 3 dimensions, with the principal curves ˆY superimposed. For clarity, we only show a small subsample of the Y0; a larger one is in the Supplement; b: same embedding, only points “on” principal curves, colored by log10 ||Hk|| (hence, 0 represents isometry); c: same points as in (b), after RR(color on the same scale as in (b)); d: 40,000 galaxies in the coordinates from (c), colored by the strength of Hydrogen α emission, a very nonlinear feature which requires dozens of dimensions to be captured in a linear embedding. Convergence of PCS-RR was achieved after 1000 iterations and took 2.5 hours optimizing a Loss with n′ = 2000 terms over the n × s = 105 × 3 coordinates, corresponding to the highest density points. (Please zoom for better viewing) principal curves shown in Figure 3 a by running PCS-RR (Y, n = 105, n′ = 2000, s = 3, d = 1). In the new coordinates (Fig 3, c), Y is now close to isometric along the selected curves, while in Fig. 3,b, ||Hk|| was in the thousands on the uppermost “arm”. This means that, at the largest scale, the units of distance in the space of galaxy spectra are being preserved (almost) uniformly along the sequences, and that they correspond to the distances in the original D = 3750 data. Moreover, we expect the distances along the final embedding to be closer on average to the true distance, because of the denoising effect of the embedding. Interpreting the coordinates along these “arms” is in progress. As a next step of the analysis, RR with s = d = 3 will be used to rescale the high-density region at the confluence of the three principal curves. 5 Discussion Contributions: we propose a new, natural, way to measure the distortion from isometry of any embedding Y ∈Rn×s of a data set X ∈Rn×D, and study its properties. The distortion loss is based on an estimate of the push-forward Riemannian metric into Euclidean space Rs. The RR we propose departs from existing non-linear embedding algorithms in several ways. First, instead of a heuristically chosen loss, like pairwise distances, or local linear reconstruction error, it directly optimizes the (dual) Riemannian metric of the embedding Y. When this is successful, and the loss is 0 all geometric properties (lengths, angles, volumes) are preserved simultaneously. From the computational point of view, the non-convex loss is optimized iteratively by projected gradient. Third, our algorithm explicitly requires both an embedding dimension s and an intrinsic dimension d as inputs. Estimating the intrinsic dimension of a data set is not a solved problem, and beyond the scope of this work. However, as a rule of thumb, we propose chosing the smallest d for which Loss is not too large, for s fixed, or, if d is known (something that all existing algorithms assume), increasing s until the loss becomes almost 0. Most existing embedding algorithms, as Isomap, LLE, HLLE, MVU, LTSA only work in the case s = d, while Laplacian Eigenmaps/Diffusion Maps requires only s but does not attempt to preserve geometric relations. Finally, RR is computationally competitive with existing algorithms, and can be seamlessly adapted to a variety of situations arising in the analysis of real data sets. 8 References [1] K. N. Abazajian et al. The Seventh Data Release of the Sloan Digital Sky Survey. Astrophysical Journal Supplement Series, 182:543–558, June 2009. [2] M. Belkin and P. Niyogi. Laplacian eigenmaps for dimensionality reduction and data representation. Neural Computation, 15:1373–1396, 2002. [3] M. Bernstein, V. deSilva, J. C. Langford, and J. Tennenbaum. Graph approximations to geodesics on embedded manifolds. Science, 290, 2000. [4] R. R. Coifman and S. Lafon. Diffusion maps. Applied and Computational Harmonic Analysis, 21(1):6–30, 2006. [5] L. Delchambre. Weighted principal component analysis: a weighted covariance eigendecomposition approach. Monthly Notices of the Royal Astronomical Society, 446(4):3545–3555, 2015. [6] David L. Donoho and Carrie Grimes. Hessian eigenmaps: Locally linear embedding techniques for high-dimensional data. Proc Natl Acad Sci, 100(10):5591–5596, May 2003. [7] Christopher Genovese, Marco Perone-Pacifico, Isabella Verdinelli, and Larry Wasserman. Minimax manifold estimation. Journal of Machine Learning Research, 13:1263â´LŠ–1291, May 2012. [8] M. Hein and J.-Y. Audibert. Intrinsic dimensionality estimation of submanifolds in Rd. In Proceedings of the 22nd international conference on Machine learning, ICML, pages 289– 296, 2005. [9] M. Hein, J.-Y. Audibert, and U. von Luxburg. Graph Laplacians and their Convergence on Random Neighborhood Graphs. Journal of Machine Learning Research, 8:1325–1368, 2007. [10] J. M. Lee. Riemannian Manifolds: An Introduction to Curvature, volume M. Springer, New York, 1997. [11] J. M. Lee. Introduction to Smooth Manifolds. Springer, New York, 2003. [12] B. Nadler, S. Lafon, R. R. Coifman, and Kevrekidis. Diffusion maps, spectral clustering and reaction coordiantes of dynamical systems. Applied and Computational Harmonic Analysis, 21:113–127, 2006. [13] J. Nash. The imbedding problem for Riemannian manifolds. Annals of Mathematics, 63, pages 20–63, 1956. [14] Umut Ozertem and Deniz Erdogmus. Locally defined principal curves and surfaces. Journal of Machine Learning Research, 12:1249–1286, 2011. [15] Dominique Perrault-Joncas and Marina Meila. Non-linear dimention reduction: Riemannian metric estimation and the problem of geometric recovery. arXiv:1305.7255v1, 2013. [16] J. Tenenbaum, V. deSilva, and J. C. Langford. A global geometric framework for nonlinear dimensionality reduction. Science, 290:2319–2323, 2000. [17] D. Ting, L Huang, and M. I. Jordan. An analysis of the convergence of graph Laplacians. In ICML, pages 1079–1086, 2010. [18] Jake Vanderplas and Andrew Connolly. Reducing the dimensionality of data: Locally linear embedding of sloan galaxy spectra. The Astronomical Journal, 138(5):1365, 2009. [19] Nakul Verma. Distance preserving embeddings for general n-dimensional manifolds. Journal of Machine Learning Research, 14:2415–2448, 2013. [20] K.Q. Weinberger and L.K. Saul. Unsupervised learning of image manifolds by semidefinite programming. International Journal of Computer Vision, 70:77–90, 2006. 10.1007/s11263005-4939-z. [21] Z. Zhang and H. Zha. Principal manifolds and nonlinear dimensionality reduction via tangent space alignment. SIAM J. Scientific Computing, 26(1):313–338, 2004. 9 | 2016 | 471 |
6,407 | DECOrrelated feature space partitioning for distributed sparse regression Xiangyu Wang Dept. of Statistical Science Duke University wwrechard@gmail.com David Dunson Dept. of Statistical Science Duke University dunson@stat.duke.edu Chenlei Leng Dept. of Statistics University of Warwick C.Leng@warwick.ac.uk Abstract Fitting statistical models is computationally challenging when the sample size or the dimension of the dataset is huge. An attractive approach for down-scaling the problem size is to first partition the dataset into subsets and then fit using distributed algorithms. The dataset can be partitioned either horizontally (in the sample space) or vertically (in the feature space). While the majority of the literature focuses on sample space partitioning, feature space partitioning is more effective when p ≫n. Existing methods for partitioning features, however, are either vulnerable to high correlations or inefficient in reducing the model dimension. In this paper, we solve these problems through a new embarrassingly parallel framework named DECO for distributed variable selection and parameter estimation. In DECO, variables are first partitioned and allocated to m distributed workers. The decorrelated subset data within each worker are then fitted via any algorithm designed for high-dimensional problems. We show that by incorporating the decorrelation step, DECO can achieve consistent variable selection and parameter estimation on each subset with (almost) no assumptions. In addition, the convergence rate is nearly minimax optimal for both sparse and weakly sparse models and does NOT depend on the partition number m. Extensive numerical experiments are provided to illustrate the performance of the new framework. 1 Introduction In modern science and technology applications, it has become routine to collect complex datasets with a huge number p of variables and/or enormous sample size n. Most of the emphasis in the literature has been on addressing large n problems, with a common strategy relying on partitioning data samples into subsets and fitting a model containing all the variables to each subset [1, 2, 3, 4, 5, 6]. In scientific applications, it is much more common to have huge p small n data sets. In such cases, a sensible strategy is to break the features into groups, fit a model separately to each group, and combine the results. We refer to this strategy as feature space partitioning, and to the large n strategy as sample space partitioning. There are several recent attempts on parallel variable selection by partitioning the feature space. [7] proposed a Bayesian split-and-merge (SAM) approach in which variables are first partitioned into subsets and then screened over each subset. A variable selection procedure is then performed on the variables that survive for selecting the final model. One caveat for this approach is that the algorithm cannot guarantee the efficiency of screening, i.e., the screening step taken on each subset might select a large number of unimportant but correlated variables [7], so SAM could be ineffective in reducing the model dimension. Inspired by a group test, [8] proposed a parallel feature selection algorithm by repeatedly fitting partial models on a set of re-sampled features, and then aggregating the residuals to 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. form scores for each feature. This approach is generic and efficient, but the performance relies on a strong condition that is almost equivalent to an independence assumption on the design. Intuitively, feature space partitioning is much more challenging than sample space partitioning, mainly because of the correlations between features. A partition of the feature space would succeed only when the features across the partitioned subsets were mutually independent. Otherwise, it is highly likely that any model posed on the subsets is mis-specified and the results are biased regardless of the sample size. In reality, however, mutually independent groups of features may not exist; Even if they do, finding these groups is likely more challenging than fitting a high-dimensional model. Therefore, although conceptually attractive, feature space partitioning is extremely challenging. On the other hand, feature space partitioning is straightforward if the features are independent. Motivated by this key fact, we propose a novel embarrassingly-parallel framework named DECO by decorrelating the features before partitioning. With the aid of decorrelation, each subset of data after feature partitioning can now produce consistent estimates even though the model on each subset is intrinsically mis-specified due to missing features. To the best of our knowledge, DECO is the first embarrassingly parallel framework accommodating arbitrary correlation structures in the features. We show, quite surprisingly, that the DECO estimate, by leveraging the estimates from subsets, achieves the same convergence rate in ℓ2 norm and ℓ∞norm as the estimate obtained by using the full dataset, and that the rate does not depend on the number of partitions. In view of the huge computational gain and the easy implementation, DECO is extremely attractive for fitting large-p data. The most related work to DECO is [9], where a similar procedure was introduced to improve lasso. Our work differs substantially in various aspects. First, our motivation is to develop a parallel computing framework for fitting large-p data by splitting features, which can potentially accommodate any penalized regression methods, while [9] aim solely at complying with the irrepresentable condition for lasso. Second, the conditions posed on the feature matrix are more flexible in DECO, and our theory, applicable for not only sparse signals but also those in lr balls, can be readily applied to the preconditioned lasso in [9]. The rest of the paper is organized as follows. In Section 2, we detail the proposed framework. Section 3 provides the theory of DECO. In particular, we show that DECO is consistent for both sparse and weakly sparse models. Section 4 presents extensive simulation studies to illustrate the performance of our framework. In Section 5, we outline future challenges and future work. All the technical details are relegated to the Appendix. 2 Motivation and the DECO framework Consider the linear regression model Y = Xβ + ε, (1) where X is an n × p feature (design) matrix, ε consists of n i.i.d random errors and Y is the response vector. A large class of approaches estimate β by solving the following optimization problem ˆβ = arg min β 1 n∥Y −Xβ∥2 2 + 2λnρ(β), where ∥· ∥2 is the ℓ2 norm and ρ(β) is a penalty function. In this paper, we specialize our discussion to the ℓ1 penalty where ρ(β) = Pp j=1 |βj| [10] to highlight the main message of the paper. As discussed in the introduction, a naive partition of the feature space will usually give unsatisfactory results under a parallel computing framework. That is why a decorrelation step is introduced. For data with p ≤n, the most intuitive way is to orthogonalize features via the singular value decomposition (SVD) of the design matrix as X = UDV T , where U is an n × p matrix, D is an p × p diagonal matrix and V an p × p orthogonal matrix. If we pre-multiply both sides of (1) by √pUD−1U T = (XXT /p) + 2 , where A+ denotes the Moore-Penrose pseudo-inverse, we get (XXT /p) + 2 Y | {z } ˜Y = √pUV T | {z } ˜ X β + (XXT /p) + 2 ε | {z } ˜ε . (2) It is obvious that the new features (the columns of √pUV T ) are mutually orthogonal. Define the new data as ( ˜Y , ˜X). The mutually orthogonal property allows us to decompose ˜X column-wisely to 2 m subsets ˜X(i), i = 1, 2, · · · , m, and still retain consistency if one fits a linear regression on each subset. To see this, notice that each sub-model now takes a form of ˜Y = ˜X(i)β(i) + ˜W (i) where ˜W (i) = ˜X(−i)β(−i) + ˜ε and X(−i) stands for variables not included in the ith subset. If, for example, we would like to compute the ordinary least squares estimates, it follows ˆβ(i) = ( ˜X(i)T ˜X(i))−1 ˜X(i) ˜Y = β(i) + ( ˜X(i)T ˜X(i))−1 ˜X(i) ˜W (i) = β(i) + ( ˜X(i)T ˜X(i))−1 ˜X(i)˜ε, where ˆβ(i) converges at the same rate as if the full dataset were used. When p is larger than n, the new features are no longer exactly orthogonal to each other due to the high dimension. Nevertheless, as proved later in the article, the correlations between different columns are roughly of the order p log p/n for random designs, making the new features approximately orthogonal when log(p) ≪n. This allows us to follow the same strategy of partitioning the feature space as in the low dimensional case. It is worth noting that when p > n, the SVD decomposition on X induces a different form on the three matrices, i.e., U is now an n × n orthogonal matrix, D is an n × n diagonal matrix, V is an n × p matrix, and XXT p + 2 becomes XXT p −1 2 . In this paper, we primarily focus on datasets where p is so large that a single computer is only able to store and perform operations on an n × q matrix (n < q < p) but not on an n × p matrix. Because the two decorrelation matrices yield almost the same properties, we will only present the algorithm and the theoretical analysis for (XXT /p)−1/2. The concrete DECO framework consists of two main steps. Assume X has been partitioned columnwisely into m subsets X(i), i = 1, 2, · · · , m (each with a maximum of q columns) and distributed onto m machines with Y . In the first stage, we obtain the decorrelation matrix (XXT /p)−1/2 or √pD−1U T by computing XXT in a distributed way as XXT = Pm i=1 X(i)X(i)T and perform the SVD decomposition on XXT on a central machine. In the second stage, each worker receives the decorrelation matrix, multiplies it to the local data (Y, X(i)) to obtain ( ˜Y , ˜X(i)), and fits a penalized regression. When the model is assumed to be exactly sparse, we can potentially apply a refinement step by re-estimating coefficients on all the selected variables simultaneously on the master machine via ridge regression. The details are provided in Algorithm 1. The entire Algorithm 1 contains only two map-reduce passes and is thus communication-efficient. Lines 14 - 18 in Algorithm 1 are added only for the data analysis in Section 5.3, in which p is massive compared to n in that log(p) is comparable to n, and the algorithm may not scale down the size of p sufficiently for even obtaining a ridge regression estimator afterwards. Thus, a further sparsification step is recommended. The condition in Line 16 is only triggered in our last experiment, but is crucial for improving the performance for extreme cases. In Line 5, the algorithm inverts XXT +r1I instead of XXT for robustness, because the rank of XXT after standardization will be n −1. Using ridge refinement instead of ordinary least squares is also for robustness. The precise choice of r1 and r2 will be discussed in the numerical section. Penalized regression fitted using regularization path usually involves a computational complexity of O(knp + kd2), where k is the number of path segmentations and d is the number of features selected. Although the segmentation number k could be as bad as (3p + 1)/2 in the worst case [11], real data experience suggests that k is on average O(n) [12], thus the complexity for DECO takes a form of O n3 + n2 p m + m in contrast to the full lasso which takes a form of O(n2p). 3 Theory In this section, we provide theoretical justification for DECO on random feature matrices. We specialize our attention to lasso due to page limits and will provide the theory on general penalties in the long version. We prove the consistency results for the estimator obtained after Stage 2 of DECO, while the consistency of Stage 3 will then follow immediately. For simplicity, we assume that ε follows a sub-Gaussian distribution and X ∼N(0, Σ) throughout this section, although the theory can be easily extended to the situation where X follows an elliptical distribution and ε is heavy-tailed. Recall that DECO fits the following linear regression on each worker ˜Y = ˜X(i)β(i) + ˜W (i), and ˜W (i) = ˜X(−i)β(−i) + ˜ε, 3 Algorithm 1 The DECO framework Initialization: 1: Input (Y, X), p, n, m, λn. Standardize X and Y to x and y with mean zero; 2: Partition (arbitrarily) (y, x) into m disjoint subsets (y, x(i)) and distribute to m machines; Stage 1 : Decorrelation 3: On each worker, compute x(i)x(i)T and push to the center machine; 4: On the center machine, compute F = Pm i=1 x(i)x(i)T ; 5: ¯F = √p F + r1Ip −1/2; 6: Push ¯F to each worker. 7: for i = 1 to m do 8: ˜y = ¯Fy and ˜x(i) = ¯Fx(i); # obtain decorrelated data 9: end for Stage 2 : Estimation 10: On each worker we estimate ˆβ(i) = arg minβ 1 n∥˜y −˜x(i)β∥2 2 + 2λnρ(β); 11: Push ˆβ(i) to the center machine and combine ˆβ = (ˆβ(1), ˆβ(2), · · · , ˆβ(m)); 12: ˆβ0 = mean(Y ) −mean(X)T ˆβ for intercept. Stage 3 : Refinement (optional) 13: if #{ˆβ ̸= 0} ≥n then 14: # Sparsification is needed before ridge regression. 15: M = {k : |ˆβk| ̸= 0}; 16: ˆβM = arg minβ 1 n∥˜y −˜xMβ∥2 2 + 2λnρ(β); 17: end if 18: M = {k : |ˆβk| ̸= 0}; 19: ˆβM = (XT MXM + r2I|M|)−1XT MY ; 20: Return ˆβ; where X(−i) stands for variables not included in the ith subset. Our proof relies on verifying each pair of ( ˜Y , ˜X(i)), i = 1, 2, · · · , m satisfies the consistency condition of lasso for the random features. Due to the page limit, we only state the main theorem in the article and defer all the proofs to the supplementary materials. Theorem 1 (s-sparse). Assume that β∗is an s-sparse vector. Define σ2 0 = var(Y ). For any A > 0 we choose λn = Aσ0 q log p n . Now if p > c0n for some c0 > 1 and 64C2 0A2s2 log p n ≤1, then with probability at least 1 −8p1−C1A2 −18pe−Cn we have ∥ˆβ −β∗∥∞≤5C0Aσ0 8 r log p n and ∥ˆβ −β∗∥2 2 ≤9C0A2σ2 0 8 s log p n , where C0 = 8c∗ c1c∗and C1 = min{ c∗c2 0 8c∗c2(1−c0)2 , c3 ∗ 8c2 4c∗2 } are two constants and c1, c2, c4, c∗, c∗, C are defined in Lemma 6 in the supplementary materials. Furthermore, if we have min βk̸=0 |βk| ≥C0Aσ0 4 r log p n , then ˆβ is sign consistent, i.e., sign(ˆβk) = sign(βk), ∀βk ̸= 0 and ˆβk = 0, ∀βk = 0. Theorem 1 looks a bit surprising since the convergence rate does not depend on m. This is mainly because the bounds used to verify the consistency conditions for lasso hold uniformly on all subsets of variables. For subsets where no true signals are allocated, lasso will estimate all coefficients to be zero, so that the loss on these subsets will be exactly zero. Thus, when summing over all subsets, we retrieve the s log p n rate. In addition, it is worth noting that Theorem 1 guarantees the ℓ∞convergence and sign consistency for lasso without assuming the irrepresentable condition [13]. A similar but weaker result was obtained in [9]. Theorem 2 (lr-ball). Assume that β∗∈B(r, R) and all conditions in Theorem 1 except that 64C2 0A2s2 log p n ≤1 are now replaced by 64C2 0A2R2 log p n 1−r ≤1. Then with probability at least 4 1 −8p1−C1A2 −18pe−Cn, we have ∥ˆβ −β∗∥∞≤3C0Aσ0 2 r log p n and ∥ˆβ −β∗∥2 2 ≤ 9C0 8 + 38 (Aσ0)2−rR log p n 1−r 2 . Note that σ2 0 = var(Y ) instead of σ appears in the convergence rate in both Theorem 1 and 2, which is inevitable due to the nonzero signals contained in ˜W. Compared to the estimation risk using full data, the results in Theorem 1 and 2 are similar up to a factor of σ2/σ2 0 = 1 −ˆR2, where ˆR2 is the coefficient of determination. Thus, for a model with an ˆR2 = 0.8, the risk of DECO is upper bounded by five times the risk of the full data inference. The rates in Theorem 1 and 2 are nearly minimax-optimal [14, 15], but the sample requirement n ≍s2 is slightly off the optimal. This requirement is rooted in the ℓ∞-convergence and sign consistency and is almost unimprovable for random designs. We will detail this argument in the long version of the paper. 4 Experiments In this section, we present the empirical performance of DECO via extensive numerical experiments. In particular, we compare DECO after 2 stage fitting (DECO-2) and DECO after 3 stage fitting (DECO-3) with the full data lasso (lasso-full), the full data lasso with ridge refinement (lasso-refine) and lasso with a naive feature partition without decorrelation (lasso-naive). This section consists of three parts. In the first part, we run DECO-2 on some simulated data and monitor its performance on one randomly chosen subset that contains part of the true signals. In the second part, we verify our claim in Theorem 1 and 2 that the accuracy of DECO does not depend on the subset number. In the last part, we provide a comprehensive evaluation of DECO’s performance by comparing DECO with other methods under various correlation structures. The synthetic datasets are from model (1) with X ∼N(0, Σ) and ε ∼N(0, σ2). The variance σ2 is chosen such that ˆR2 = var(Xβ)/var(Y ) = 0.9. We consider five different structures of Σ. Model (i) Independent predictors. The support of β is S = {1, 2, 3, 4, 5}. We generate Xi from a standard multivariate normal distribution with independent components. The coefficients are specified as βi = (−1)Ber(0.5) |N(0, 1)| + 5 q log p n i ∈S 0 i ̸∈S. Model (ii) Compound symmetry. All predictors are equally correlated with correlation ρ = 0.6. The coefficients are the same as those in Model (i). Model (iii) Group structure. This example is Example 4 in [16], for which we allocate the 15 true variables into three groups. Specifically, the predictors are generated as x1+3m = z1 + N(0, 0.01), x2+3m = z2 + N(0, 0.01) and x3+3m = z3 + N(0, 0.01), where m = 0, 1, 2, 3, 4 and zi ∼N(0, 1) are independent. The coefficients are set as βi = 3, i = 1, 2, · · · , 15; βi = 0, i = 16, · · · , p. Model (iv) Factor models. This model is considered in [17]. Let φj, j = 1, 2, · · · , k be independent standard normal variables. We set predictors as xi = Pk j=1 φjfij + ηi, where fij and ηi are independent standard normal random variables. The number of factors is chosen as k = 5 in the simulation while the coefficients are specified the same as in Model (i). Model (v) ℓ1-ball. This model takes the same correlation structure as Model (ii), with the coefficients drawn from Dirichlet distribution β ∼Dir 1 p, 1 p, · · · , 1 p × 10. This model is to test the performance under a weakly sparse assumption on β, since β is non-sparse satisfying ∥β∥1 = 10. Throughout this section, the performance of all the methods is evaluated in terms of four metrics: the number of false positives (# FPs), the number of false negatives (# FNs), the mean squared error ∥ˆβ −β∗∥2 2 (MSE) and the computational time (runtime). We use glmnet [18] to fit lasso and choose the tuning parameter using the extended BIC criterion [19] with γ fixed at 0.5. For DECO, the features are partitioned randomly in Stage 1 and the tuning parameter r1 is fixed at 1 for DECO-3. Since DECO-2 does not involve any refinement step, we choose r1 to be 10 to aid robustness. The ridge parameter r2 is chosen by 5-fold cross-validation for both DECO-3 and lasso-refine. All 5 sample size n 100 200 300 400 number of False positives 0 1 2 3 4 5 6 7 False positives DECO-2 lasso-full lasso-naive sample size n 100 200 300 400 number of False negatives 0 0.2 0.4 0.6 0.8 1 False negatives DECO-2 lasso-full lasso-naive sample size n 100 200 300 400 l2 error 0 5 10 15 20 25 30 Estimation error DECO-2 lasso-full lasso-naive sample size n 100 200 300 400 Runtime (sec) 0 2 4 6 8 Runtime DECO-2 lasso-full lasso-naive Figure 1: Performance of DECO on one subset with p = 10, 000 and different n′s. model dimension p 2000 4000 6000 8000 number of False positives 0 5 10 15 False positives DECO-2 lasso-full lasso-naive model dimension p 2000 4000 6000 8000 number of False negatives 0 0.1 0.2 0.3 0.4 False negatives DECO-2 lasso-full lasso-naive model dimension p 2000 4000 6000 8000 l2 error 1 2 3 4 5 Estimation error DECO-2 lasso-full lasso-naive model dimension p 2000 4000 6000 8000 Runtime (sec) 0 2 4 6 8 Runtime DECO-2 lasso-full lasso-naive Figure 2: Performance of DECO on one subset with n = 500 and different p′s. the algorithms are coded and timed in Matlab on computers with Intel i7-3770k cores. For any embarrassingly parallel algorithm, we report the preprocessing time plus the longest runtime of a single machine as its runtime. 4.1 Monitor DECO on one subset In this part, using data generated from Model (ii), we illustrate the performance of DECO on one randomly chosen subset after partitioning. The particular subset we examine contains two nonzero coefficients β1 and β2 with 98 coefficients, randomly chosen, being zero. We either fix p = 10, 000 and change n from 100 to 500, or fix n at 500 and change p from 2, 000 to 10, 000 to simulate datasets. We fit DECO-2, lasso-full and lasso-naive to 100 simulated datasets, and monitor their performance on that particular subset. The results are shown in Fig 1 and 2. It can be seen that, though the sub-model on each subset is mis-specified, DECO performs as if the full dataset were used as its performance is on par with lasso-full. On the other hand, lasso-naive fails completely. This result clearly highlights the advantage of decorrelation before feature partitioning. 4.2 Impact of the subset number m As shown in Theorem 1 and 2, the performance of DECO does not depend on the number of partitions m. We verify this property by using Model (ii) again. This time, we fix p = 10, 000 and n = 500, and vary m from 1 to 200. We compare the performance of DECO-2 and DECO-3 with lasso-full and lasso-refine. The averaged results from 100 simulated datasets are plotted in Fig 3. Since p and n are both fixed, lasso-full and lasso-refine are expected to perform stably over different m′s. DECO-2 and DECO-3 also maintain a stable performance regardless of the value of m. In addition, DECO-3 achieves a similar performance to and sometimes better accuracy than lasso-refine, possibly because the irrepresentable condition is satisfied after decorrelation (See the discussions after Theorem 1). 4.3 Comprehensive comparison In this section, we compare all the methods under the five different correlation structures. The model dimension and the sample size are fixed at p = 10, 000 and n = 500 respectively and the number of subsets is fixed as m = 100. For each model, we simulate 100 synthetic datasets and record the average performance in Table 1 6 subset number m 50 100 150 number of False positives 0 0.5 1 1.5 2 False positives DECO-2 lasso-refine lasso-full DECO-3 subset number m 50 100 150 number of False negatives 0 0.05 0.1 0.15 0.2 False negatives DECO-2 lasso-refine lasso-full DECO-3 subset number m 50 100 150 l2 error 0 1 2 3 4 5 6 Estimation error DECO-2 lasso-refine lasso-full DECO-3 subset number m 50 100 150 runtime (sec) 0 2 4 6 8 10 12 Runtime DECO-2 lasso-refine lasso-full DECO-3 Figure 3: Performance of DECO with different number of subsets. Table 1: Results for five models with (n, p) = (500, 10000) DECO-3 DECO-2 lasso-refine lasso-full lasso-naive MSE 0.102 3.502 0.104 0.924 3.667 (i) # FPs 0.470 0.570 0.420 0.420 0.650 # FNs 0.010 0.020 0.000 0.000 0.010 Time 65.5 60.3 804.5 802.5 9.0 MSE 0.241 4.636 1.873 3.808 171.05 (ii) # FPs 0.460 0.550 2.39 2.39 1507.2 # FNs 0.010 0.030 0.160 0.160 1.290 Time 66.9 61.8 809.2 806.3 13.1 MSE 6.620 1220.5 57.74 105.99 1235.2 (iii) # FPs 0.410 0.570 0.110 0.110 1.180 # FNs 0.130 0.120 3.93 3.93 0.110 Time 65.5 60.0 835.3 839.9 9.1 MSE 0.787 5.648 11.15 6.610 569.56 (iv) # FPs 0.460 0.410 19.90 19.90 1129.9 # FNs 0.090 0.100 0.530 0.530 1.040 Time 69.4 64.1 875.1 880.0 14.6 (v) MSE — 2.341 — 1.661 356.57 Time — 57.5 — 829.5 13.3 Several conclusions can be drawn from Table 1. First, when all variables are independent as in Model (i), lasso-naive performs similarly to DECO-2 because no decorrelation is needed in this simple case. However, lasso-naive fails completely for the other four models when correlations are presented. Second, DECO-3 achieves the overall best performance. The better estimation error over lasso-refine is due to the better variable selection performance, since the irrepresentable condition is not needed for DECO. Finally, DECO-2 performs similarly to lasso-full and the difference is as expected according to the discussions after Theorem 2. 5 Real data We illustrate the competitve performance of DECO via three real datasets that cover a range of high dimensionalities, by comparing DECO-3 to lasso-full, lasso-refine and lasso-naive in terms of prediction error and computational time. The algorithms are configured in the same way as in Section 4. Although DECO allows arbitrary partitioning over the feature space, for simplicity, we confine our attention to random partitioning. In addition, we perform DECO-3 multiple times on the same dataset to ameliorate the uncertainty due to the randomness in partitioning. Student performance dataset. We look at one of the two datasets used for evaluating student achievement in two Portuguese schools [20]. The particular dataset used here provides the students’ performance in mathematics. The goal of the research is to predict the final grade (range from 0 to 20). The original data set contains 395 students and 32 raw attributes. The raw attributes are recoded as 40 attributes and form 767 features after adding interaction terms. To reduce the conditional number of the feature matrix, we remove features that are constant, giving 741 features. We standardize 7 all features and randomly partition them into 5 subsets for DECO. To compare the performance of all methods, we use 10-fold cross validation and record the prediction error (mean square error, MSE), model size and runtime. The averaged results are summarized in Table 2. We also report the performance of the null model which predicts the final grade on the test set using the mean final grade in the training set. Mammalian eye diseases. This dataset, taken from [21], was collected to study mammalian eye diseases, with gene expression for the eye tissues of 120 twelve-week-old male F2 rats recorded. One gene coded as TRIM32 responsible for causing Bardet-Biedl syndrome is the response of interest. Following the method in [21], 18,976 probes were selected as they exhibited sufficient signal for reliable analysis and at least 2-fold variation in expressions, and we confine our attention to the top 5,000 genes with the highest sample variance. The 5,000 genes are standardized and partitioned into 100 subsets for DECO. The performance is assessed via 10-fold cross validation following the same approach in Section 5.1. The results are summarized in Table 2. As a reference, we also report these values for the null model. Electricity load diagram. This dataset [22] consists of electricity load from 2011 - 2014 for 370 clients. The data are originally recorded in KW for every 15 minutes, resulting in 14,025 attributes. Our goal is to predict the most recent electricity load by using all previous data points. The variance of the 14,025 features ranges from 0 to 107. To reduce the conditional number of the feature matrix, we remove features whose variances are below the lower 10% quantile (a value of 105) and retain 126,231 features. We then expand the feature sets by including the interactions between the first 1,500 attributes that has the largest correlation with the clients’ most recent load. The resulting 1,251,980 features are then partitioned into 1,000 subsets for DECO. Because cross-validation is computationally demanding for such a large dataset, we put the first 200 clients in the training set and the remaining 170 clients in the testing set. We also scale the value of electricity load between 0 and 300, so that patterns are more visible. The results are summarized in Table 2. Table 2: The results of all methods on the three datasets. Student Performance Mammalian eye disease Electricity load diagram MSE size runtime MSE size runtime MSE size runtime DECO-3 3.64 1.5 37.0 0.012 4.3 9.6 0.691 4 67.9 lasso-full 3.79 2.2 60.8 0.012 11 139.0 2.205 6 23,515.5 lasso-refine 3.89 2.2 70.9 0.010 11 139.7 1.790 6 22,260.9 lasso-naive 16.5 6.4 44.6 37.65 6.8 7.9 3.6 × 108 4966 52.9 Null 20.7 — — 0.021 — — 520.6 — — 6 Concluding remarks In this paper, we have proposed an embarrassingly parallel framework named DECO for distributed estimation. DECO is shown to be theoretically attractive, empirically competitive and is straightforward to implement. In particular, we have shown that DECO achieves the same minimax convergence rate as if the full data were used and the rate does not depend on the number of partitions. We demonstrated the empirical performance of DECO via extensive experiments and compare it to various approaches for fitting full data. As illustrated in the experiments, DECO can not only reduce the computational cost substantially, but often outperform the full data approaches in terms of model selection and parameter estimation. Although DECO is designed to solve large-p-small-n problems, it can be extended to deal with large-p-large-n problems by adding a sample space partitioning step, for example, using the message approach [5]. More precisely, we first partition the large-p-large-n dataset in the sample space to obtain l row blocks such that each becomes a large-p-small-n dataset. We then partition the feature space of each row block into m subsets. This procedure is equivalent to partitioning the original data matrix X into l × m small blocks, each with a feasible size that can be stored and fitted in a computer. We then apply the DECO framework to the subsets in the same row block using Algorithm 1. The last step is to apply the message method to aggregate the l row block estimators to output the final estimate. This extremely scalable approach will be explored in future work. 8 References [1] Ryan Mcdonald, Mehryar Mohri, Nathan Silberman, Dan Walker, and Gideon S Mann. Efficient largescale distributed training of conditional maximum entropy models. In Advances in Neural Information Processing Systems, pages 1231–1239, 2009. [2] Yuchen Zhang, Martin J Wainwright, and John C Duchi. Communication-efficient algorithms for statistical optimization. In Advances in Neural Information Processing Systems, pages 1502–1510, 2012. [3] Steven L Scott, Alexander W Blocker, Fernando V Bonassi, H Chipman, E George, and R McCulloch. Bayes and big data: The consensus monte carlo algorithm. In EFaBBayes 250 conference, volume 16, 2013. [4] Xiangyu Wang, Fangjian Guo, Katherine A Heller, and David B Dunson. Parallelizing mcmc with random partition trees. In Advances in Neural Information Processing Systems, pages 451–459, 2015. [5] Xiangyu Wang, Peichao Peng, and David B Dunson. Median selection subset aggregation for parallel inference. In Advances in Neural Information Processing Systems, pages 2195–2203, 2014. [6] Stanislav Minsker et al. Geometric median and robust estimation in banach spaces. Bernoulli, 21(4):2308– 2335, 2015. [7] Qifan Song and Faming Liang. A split-and-merge bayesian variable selection approach for ultrahigh dimensional regression. Journal of the Royal Statistical Society: Series B (Statistical Methodology), 2014. [8] Yingbo Zhou, Utkarsh Porwal, Ce Zhang, Hung Q Ngo, Long Nguyen, Christopher Ré, and Venu Govindaraju. Parallel feature selection inspired by group testing. In Advances in Neural Information Processing Systems, pages 3554–3562, 2014. [9] Jinzhu Jia and Karl Rohe. Preconditioning to comply with the irrepresentable condition. arXiv preprint arXiv:1208.5584, 2012. [10] Robert Tibshirani. Regression shrinkage and selection via the lasso. Journal of the Royal Statistical Society. Series B (Methodological), pages 267–288, 1996. [11] Julien Mairal and Bin Yu. Complexity analysis of the lasso regularization path. In Proceedings of the 29th International Conference on Machine Learning (ICML-12), pages 353–360, 2012. [12] Saharon Rosset and Ji Zhu. Piecewise linear regularized solution paths. The Annals of Statistics, pages 1012–1030, 2007. [13] Peng Zhao and Bin Yu. On model selection consistency of lasso. The Journal of Machine Learning Research, 7:2541–2563, 2006. [14] Fei Ye and Cun-Hui Zhang. Rate minimaxity of the lasso and dantzig selector for the lq loss in lr balls. The Journal of Machine Learning Research, 11:3519–3540, 2010. [15] Garvesh Raskutti, Martin J Wainwright, and Bin Yu. Minimax rates of convergence for high-dimensional regression under â ˇD¸S q-ball sparsity. In Communication, Control, and Computing, 2009. Allerton 2009. 47th Annual Allerton Conference on, pages 251–257. IEEE, 2009. [16] Hui Zou and Trevor Hastie. Regularization and variable selection via the elastic net. Journal of the Royal Statistical Society: Series B (Statistical Methodology), 67(2):301–320, 2005. [17] Nicolai Meinshausen and Peter Bühlmann. Stability selection. Journal of the Royal Statistical Society: Series B (Statistical Methodology), 72(4):417–473, 2010. [18] Jerome Friedman, Trevor Hastie, and Rob Tibshirani. Regularization paths for generalized linear models via coordinate descent. Journal of statistical software, 33(1):1, 2010. [19] Jiahua Chen and Zehua Chen. Extended bayesian information criteria for model selection with large model spaces. Biometrika, 95(3):759–771, 2008. [20] Paulo Cortez and Alice Maria Gonçalves Silva. Using data mining to predict secondary school student performance. 2008. [21] Todd E Scheetz, Kwang-Youn A Kim, Ruth E Swiderski, Alisdair R Philp, Terry A Braun, Kevin L Knudtson, Anne M Dorrance, Gerald F DiBona, Jian Huang, Thomas L Casavant, et al. Regulation of gene expression in the mammalian eye and its relevance to eye disease. Proceedings of the National Academy of Sciences, 103(39):14429–14434, 2006. [22] Artur Trindade. UCI machine learning repository, 2014. 9 | 2016 | 472 |
6,408 | Incremental Boosting Convolutional Neural Network for Facial Action Unit Recognition Shizhong Han, Zibo Meng, Ahmed Shehab Khan, Yan Tong Department of Computer Science & Engineering, University of South Carolina, Columbia, SC {han38, mengz, akhan}@email.sc.edu, tongy@cse.sc.edu Abstract Recognizing facial action units (AUs) from spontaneous facial expressions is still a challenging problem. Most recently, CNNs have shown promise on facial AU recognition. However, the learned CNNs are often overfitted and do not generalize well to unseen subjects due to limited AU-coded training images. We proposed a novel Incremental Boosting CNN (IB-CNN) to integrate boosting into the CNN via an incremental boosting layer that selects discriminative neurons from the lower layer and is incrementally updated on successive mini-batches. In addition, a novel loss function that accounts for errors from both the incremental boosted classifier and individual weak classifiers was proposed to fine-tune the IB-CNN. Experimental results on four benchmark AU databases have demonstrated that the IB-CNN yields significant improvement over the traditional CNN and the boosting CNN without incremental learning, as well as outperforming the state-of-the-art CNN-based methods in AU recognition. The improvement is more impressive for the AUs that have the lowest frequencies in the databases. 1 Introduction Facial behavior is a powerful means to express emotions and to perceive the intentions of a human. Developed by Ekman and Friesen [1], the Facial Action Coding System (FACS) describes facial behavior as combinations of facial action units (AUs), each of which is anatomically related to the contraction of a set of facial muscles. In addition to applications in human behavior analysis, an automatic AU recognition system has great potential to advance emerging applications in human-computer interaction (HCI), such as online/remote education, interactive games, and intelligent transportation, as well as to push the frontier of research in psychology. Recognizing facial AUs from spontaneous facial expressions is challenging because of subtle facial appearance changes, free head movements, and occlusions, as well as limited AU-coded training images. As elaborated in the survey papers [2, 3], a number of approaches have been developed to extract features from videos or static images to characterize facial appearance or geometrical changes caused by target AUs. Most of them employed hand-crafted features, which, however, are not designed and optimized for facial AU recognition. Most recently, CNNs have achieved incredible success in different applications such as object detection and categorization, video analysis, and have shown promise on facial expression and AU recognition [4, 5, 6, 7, 8, 9, 10]. CNNs contain a large number of parameters, especially as the network becomes deeper. To achieve satisfactory performance, a large number of training images are required and a mini-batch strategy is used to deal with large training data, where a small batch of images are employed in each iteration. In contrast to the millions of training images employed in object categorization and detection, AUcoded training images are limited and usually collected from a small population, e.g., 48,000 images from 15 subjects in the FERA2015 SEMAINE database [11], and 130,814 images from 27 subjects in Denver Intensity of Spontaneous Facial Action (DISFA) database [12]. As a result, the learned CNNs are often overfitted and do not generalize well to unseen subjects. Boosting, e.g., AdaBoost, is a popular ensemble learning technique, which combines many “weak” classifiers and has been demonstrated to yield better generalization performance in AU recognition [13]. Boosting can be integrated into the CNN such that discriminative neurons are selected and activated in each iteration of CNN learning. However, the boosting CNN (B-CNN) can overfit due 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. Figure 1: An overview of Incremental Boosting CNN. An incremental boosted classifier is trained iteratively. Outputs of the FC layer are employed as input features and a subset of features (the blue nodes) are selected by boosting. The selected features in the current iteration are combined with those selected previously (the red nodes) to form an incremental strong classifier. A loss is calculated based on the incremental classifier and propagated backward to fine-tune the CNN parameters. The gray nodes are inactive and thus, not selected by the incremental strong classifier. Given a testing image, features are calculated via the CNN and fed to the boosted classifier to predict the AU label. Best viewed in color. to the limited training data in each mini-batch. Furthermore, the information captured in previous iteration/batch cannot be propagated, i.e., a new set of weak classifiers is selected in every iteration and the weak classifiers learned previously are discarded. Inspired by incremental learning, we proposed a novel Incremental Boosting CNN (IB-CNN), which aims to accumulate information in B-CNN learning when new training samples appear. As shown in Figure 1, a batch of images is employed in each iteration of CNN learning. The outputs of the fully-connected (FC) layer are employed as features; a subset of features (the blue nodes), which is discriminative for recognizing the target AU in the current batch, is selected by boosting. Then, these selected features are combined with the ones selected previously (the red nodes) to form an incremental strong classifier. The weights of active features, i.e., both the blue and the red nodes, are updated such that the features selected most of the time have higher weights. Finally, a loss, i.e., the overall classification error from both weak classifiers and the incremental strong classifier, is calculated and backpropagated to fine-tune the CNN iteratively. The proposed IB-CNN has a complex decision boundary due to boosting and is capable of alleviating the overfitting problem for the mini-batches by taking advantage of incremental learning. In summary, this paper has three major contributions. (1) Feature selection and classification are integrated with CNN optimization in a boosting CNN framework. (2) A novel incremental boosted classifier is updated iteratively by accumulating information from multiple batches. (3) A novel loss function, which considers the overall classification error of the incremental strong classifier and individual classification errors of weak learners, is developed to fine-tune the IB-CNN. Experimental results on four benchmark AU-coded databases, i.e., Cohn-Kanade (CK) [25] databse, FERA2015 SEMAINE database [11], FERA2015 BP4D database [11], and Denver Intensity of Spontaneous Facial Action (DISFA) database [12] have demonstrated that the proposed IB-CNN significantly outperforms the traditional CNN model as well as the state-of-the-art CNN-based methods for AU recognition. Furthermore, the performance improvement of the infrequent AUs is more impressive, which demonstrates that the proposed IB-CNN is capable of improving CNN learning with limited training data. In addition, the performance of IB-CNN is not sensitive to the number of neurons in the FC layer and the learning rate, which are favored traits in CNN learning. 2 Related Work As detailed in the survey papers [2, 3], various human-designed features are adopted in recognizing facial expressions and AUs including Gabor Wavelets [13], Local Binary Patterns (LBP) [14], Histogram of Oriented Gradients (HOG) [15], Scale Invariant Feature Transform (SIFT) features [16], Histograms of Local Phase Quantization (LPQ) [17], and their spatiotemporal extensions [17, 18, 19]. Recently, feature learning approaches including sparse coding [20] and deep learning [4, 5, 6, 7, 8, 9, 10, 21] have been devoted to recognizing facial expressions and AUs. Among the feature learning based methods, CNNs [4, 5, 6, 7, 8, 9, 10] have attracted increasing attention. Gudi et al. [9] used a pre-processing method with local and global contrast normalization 2 to improve the inputs of CNNs. Fasel [4] employed multi-size convolutional filters to learn multiscale features. Liu et al [7] extracted spatiotemporal features using the 3D CNN. Jung et al. [8] jointly fine-tuned temporal appearance and geometry features. Jaiswal and Valstar [10] integrated bi-directional long-term memory neural networks with the CNN to extract temporal features. Most of CNN-based methods make decisions using inner product of the FC layer. A few approaches developed new objective functions to improve recognition performance. Tang [22, 6] replaced the softmax loss function with an SVM for optimization. Hinton et al. [23] utilized a dropout technique to reduce overfitting by dropping out some neuron activations from the previous layer, which can be seen as an ensemble of networks sharing the same weights. However, the dropout process is random regardless the discriminative power of individual neurons. In contrast, the proposed IB-CNN effectively selects the more discriminative neurons and drops out noisy or redundant neurons. Medera and Babinec [24] adopted incremental learning using multiple CNNs trained individually from different subsets and additional CNNs are trained given new samples. Then, the prediction is calculated by weighted majority-voting of the outputs of all CNNs. However, each CNN may not have sufficient training data, which is especially true with limited AU-coded data. Different from [24], the IB-CNN has only one CNN trained along with an incremental strong classifier, where weak learners are updated over time by accumulating information from multiple batches. Liu et al. [21] proposed a boosted deep belief network for facial expression recognition, where each weak classifier is learned exclusively from an image patch. In contrast, weak classifiers are selected from an FC layer in the proposed IB-CNN and thus, learned from the whole face. 3 Methodology As illustrated in Figure 1, an IB-CNN model is proposed to integrate boosting with the CNN at the decision layer with an incremental boosting algorithm, which selects and updates weak learners over time as well as constructs an incremental strong classifier in an online learning manner. There are three major steps for incremental boosting: selecting and activating neurons (blue nodes) from the FC layer by boosting, combining the activated neurons from different batches (blue and red nodes) to form an incremental strong classifier, and fine-tuning the IB-CNN by minimizing the proposed loss function. In the following, we start with a brief review of CNNs and then, describe the three steps of incremental boosting in detail. 3.1 A Brief Review of CNNs A CNN consists of a stack of layers such as convolutional layers, pooling layers, rectification layers, FC layers, and a decision layer and transforms the input data into a highly nonlinear representation. Ideally, learned filters should activate the image patches related to the recognition task, i.e., detecting AUs in this work. Neurons in an FC layer have full connections with all activations in the previous layer. Finally, high-level reasoning is done at the decision layer, where the number of outputs is equal to the number of target classes. The score function used by the decision layer is generally the inner product of the activations in the FC layer and the corresponding weights. During CNN training, a loss layer is employed after the decision layer to specify how to penalize the deviations between the predicted and true labels, where different types of loss functions have been employed, such as softmax, SVM, and sigmoid cross entropy. In this paper, we substitute the inner-product score function with a boosting score function to achieve a complex decision boundary. 3.2 Boosting CNN In a CNN, a mini-batch strategy is often used to handle large training data. Let X = [x1, ..., xM] be the activation features of a batch with M training images, where the dimension of the activation feature vector xi is K, and y = [y1, ..., yM], yi ∈{−1, 1} is a vector storing the ground truth labels. With the boosting algorithm, the prediction is calculated by a strong classifier H(·) that is the weighted summation of weak classifiers h(·) as follows: H(xi) = K X j=1 αjh(xij, λj); h(xij, λj) = f(xij, λj) p f(xij, λj)2 + η2 (1) where xij ∈xi is the jth activation feature of the ith image. Each feature corresponds to a candidate weak classifier h(xij, λj) with output in the range of (-1,1). f(·) √ f(·)2+η2 is used to simulate a sign(·) function to compute the derivative for gradient descent optimization. In this work, f(xij, λj) ∈R is defined as a one-level decision tree (a decision stump) with the threshold of λj, which has been widely used in AdaBoost. The parameter η in Eq. 1 is employed to control the slope of function 3 f(·) √ f(·)2+η2 and can be set according to the distribution of f(·) as η = σ c , where σ is the standard deviation of f(·) and c is a constant. In this work, η is empirically set to σ 2 . αj ≥0 is the weight of the jth weak classifier and PK j=1 αj = 1. When αj = 0, the corresponding neuron is inactive and will not go through the feedforward and backpropagation process. Traditional boosting algorithms only consider the loss of the strong classifier, which can be dominated by some weak classifiers with large weights, potentially leading to overfitting. To account for classification errors from both the strong classifier and the individual classifiers, the loss function is defined as the summation of a strong-classifier loss and a weak-classifier loss as follows: εB = βεB strong + (1 −β)εweak (2) where β ∈[0, 1] balances the strong-classifier loss and the weak-classifier loss. The strong-classifier loss is defined as the Euclidean distance between the prediction and the groundtruth label: εB strong = 1 M M X i=1 (H(xi) −yi)2 (3) The weak-classifier loss is defined as the summation of the individual losses of all weak classifiers: εweak = 1 MN M X i=1 X 1≤j≤K αj >0 h(xij, λj) −yi 2 (4) where the constraint αj > 0 excludes inactive neurons when calculating the loss. Driven by the loss εB defined in Eq. 2, the B-CNN can be iteratively fine-tuned by backpropagation as illustrated in the top of Figure 2. However, the information captured previously, e.g., the weights and thresholds of the active neurons, is discarded for a new batch. Due to limited data in each minibatch, the trained B-CNN can be overfitted. 3.3 Incremental Boosting Figure 2: A comparison of the IB-CNN and the B-CNN structures. For clarity, the illustration of IB-CNN or B-CNN starts from the FC layer (the cyan nodes). The blue nodes are active nodes selected in the current iteration; the red nodes are the active nodes selected from previous iterations; and the gray nodes are inactive. Incremental learning can help to improve the prediction performance and to reduce overfitting. As illustrated in the bottom of Figure 2, both of the blue nodes selected in the current iteration and the red nodes selected previously are incrementally combined to form an incremental strong classifier Ht I at the tth iteration: Ht I(xt i) = (t −1)Ht−1 I (xt−1 i ) + Ht(xt i) t (5) where Ht−1 I (xt i) is the incremental strong classifier obtained at the (t −1)th iteration; and Ht(xt i) is the boosted strong classifier estimated in the current iteration. Substituting Eq. 1 into Eq. 5, we have Ht I(xt i) = K X j=1 αt jht(xt ij; λt j); αt j = (t −1)αt−1 j + ˆαt j t (6) where ˆαt j is the weak classifier weight calculated in the tth iteration by boosting and αt j is the cumulative weight considering previous iterations. As shown in Figure 3, ht−1(·) has been updated 4 Algorithm 1 Incremental Boosting Algorithm for the IB-CNN Input: The number of iterations (mini-batches) T and activation features X with the size of M ×K, where M is the number of images in a mini-batch and K is the dimension of the activation feature vector for one image. 1: for each input activation j from 1 to K do 2: α1 j = 0 3: end for 4: for each mini-batch t from 1 to T do 5: Feed-forward to the fully connected layer; 6: Select active features by boosting and calculate weights ˆαt based on the standard AdaBoost; 7: Update the incremental strong classifier as Eq. 6; 8: Calculate the overall loss of IB-CNN as Eq. 8; 9: Backpropagate the loss based on Eq. 9 and Eq. 10; 10: Continue backpropagation to lower layers. 11: end for to ht(·) by updating the threshold λt−1 j to λt j. If the jth weak classifier was not selected before, λt j is estimated in the tth iteration by boosting. Otherwise, λt j will be updated from the previous iteration after backpropagation as follows: λt j = λt−1 j −γ∇∂εHt−1 I ∂λt−1 j (7) ... ... ... HI t Figure 3: An illustration of constructing the incremental strong classifier. Squares represent neuron activations. The gray nodes are inactive; while the blue and red nodes are active nodes selected in the current iteration and previous iterations, respectively. where γ is the learning rate. Then, the incremental strong classifier Ht I is updated over time. As illustrated in Figure 3, if a neuron is activated in the current iteration, the corresponding weight will increase; otherwise, it will decrease. The summation of weights of all weak classifiers will be normalized to 1. Hence, the weak classifiers selected most of the time, i.e., effective for most of mini-batches, will have higher weights. Therefore, the overall loss of IB-CNN is calculated as εIB = βεIB strong + (1 −β)εweak (8) where εIB strong = 1 M PM i=1(Ht I(xt i) −yt i)2. Compared to the B-CNN, the IB-CNN exploits the information from all mini-batches. For testing, IB-CNN uses the incremental strong classifier, while the B-CNN employs the strong classifier learned from the last iteration. 3.4 IB-CNN Fine-tuning A stochastic gradient descent method is utilized for fine-tuning the IB-CNN, i.e., updating IB-CNN parameters, by minimizing the loss in Eq. 8. The descent directions for xt ij and λt j can be calculated as follows: ∂εIB ∂xt ij = β ∂εIB strong ∂Ht I(xt i) ∂Ht I(xi) ∂xt ij + (1 −β) ∂εIB weak ∂ht(xt ij; λt j) ∂ht(xt ij; λt j) ∂xt ij (9) ∂εIB ∂λt j = M X i=1 β ∂εIB strong ∂Ht I(xt i) ∂Ht I(xt i) ∂λt j + (1 −β) M X i=1 ∂εIB weak ∂ht(xt ij; λt j) ∂ht(xt ij; λt j) ∂λt j (10) where ∂εIB ∂xt ij and ∂εIB ∂λt j are only calculated for the active nodes of incremental boosting (the red and blue nodes in Figure 3). ∂εIB ∂xt ij can be further backpropagated to the lower FC layers and convolutional layers. The incremental boosting algorithm for the IB-CNN is summarized in Algorithm 1. 4 Experiments To evaluate effectiveness of the proposed IB-CNN model, extensive experiments have been conducted on four benchmark AU-coded databases. The CK database [25] contains 486 image sequences from 97 subjects and has been widely used for evaluating the performance of AU recognition. In addition, 14 AUs were annotated frame-by-frame [30] for training and evaluation. The FERA2015 SEMAINE database [11] contains 6 AUs and 31 subjects with 93,000 images. The FERA2015 BP4D database [11] has 11 AUs and 41 subjects with 146,847 images. The DISFA database [12] has 12 labeled AUs and 27 subjects with 130,814 images. 5 4.1 Pre-Processing Face alignment is conducted to reduce variation in face scale and in-plane rotation across different facial images. Specifically, the face regions are aligned based on three fiducial points: the centers of the two eyes and the mouth, and scaled to a size of 128 × 96. In order to alleviate face pose variations, especially out-of-plane rotations, face images are further warped to a frontal view based on landmarks that are less affected by facial expressions including landmarks along the facial contour, two eye centers, the nose tip, the mouth center, and on the forehead. A total of 23 landmarks that are less affected by facial muscle movements are selected as control points to warp the face region to the mean facial shape calculated from all images 1. Time sequence normalization is used to reduce identity-related information and highlight appearance and geometrical changes due to activation of AUs. Particularly, each image is normalized based on the mean and the standard deviation calculated from a short video sequence containing at least 800 continuous frames at a frame rate of 30fps 2. 4.2 CNN Implementation Details The proposed IB-CNN is implemented based on a modification of cifar10_quick in Caffe [28]. As illustrated in Figure 1, the preprocessed facial images are fed into the network as input. The IBCNN consists of three stacked convolutional layers with activation functions, two average pooling layers, an FC layer, and the proposed IB layer to predict the AU label. Specifically, the first two convolutional layers have 32 filters with a size of 5 × 5 and a stride of 1. Then, the output feature maps are sent to a rectified layer followed by the average pooling layer with a downsampling stride of 3. The last convolutional layer has 64 filters with a size of 5 × 5, and the output 9 × 5 feature maps are fed into an FC layer with 128 nodes. The outputs of the FC layer are sent to the proposed IB layer. The stochastic gradient descent, with a momentum of 0.9 and a mini-batch size of 100, is used for training the CNN for each target AU. 4.3 Experimental Results To demonstrate effectiveness of the proposed IB-CNN, two baseline methods are employed for comparison. The first method, denoted as CNN, is a traditional CNN model with a sigmoid cross entropy decision layer. The second method, denoted as B-CNN, is the boosting CNN described in Section 3.2. Both CNN and B-CNN have the same architecture as the IB-CNN with different decision layers. Performance evaluation on the SEMAINE database: All the models compared were trained on the training set and evaluated on the validation set. The training-testing process was repeated 5 times. The mean and standard deviation of F1 score and two-alternative forced choice (2AFC) score are calculated from the 5 runs for each target AU. As shown in Table 1, the proposed IB-CNN outperforms the traditional CNN in term of the average F1 score (0.416 vs 0.347) and the average 2AFC score (0.775 vs 0.735). Not surprisingly, IB-CNN also beats B-CNN obviously: the average F1 score increases from 0.310 (B-CNN) to 0.416 (IB-CNN) and the average 2AFC score increases from 0.673 (B-CNN) to 0.775 (IB-CNN), thanks to incremental learning over time. In addition, IB-CNN considering both strong and weak classifier losses outperforms the one with only strong-classifier loss, denoted as IB-CNN-S. Note that, IB-CNN achieves a significant improvement for recognizing AU28 (Lips suck), which has the least number of occurrences (around 1.25% positive samples) in the training set, from 0.280 (CNN) and 0.144 (B-CNN) to 0.490 (IB-CNN) in terms of F1 score. The performance of B-CNN is the worst for infrequent AUs due to the limited positive samples in each mini-batch. In contrast, the proposed IB-CNN improves CNN learning significantly with limited training data. Table 1: Performance comparison of CNN, B-CNN, IB-CNN-S, and IB-CNN on the SEMAINE database in terms of F1 and 2AFC. The format is mean±std. PPos: percentage of positive samples in the training set. AUs PPos CNN B-CNN IB-CNN-S IB-CNN F1 2AFC F1 2AFC F1 2AFC F1 2AFC AU2 13.5% 0.314±0.065 0.715±0.076 0.241±0.073 0.646±0.060 0.414±0.016 0.812±0.010 0.410±0.024 0.820±0.009 AU12 17.6% 0.508±0.023 0.751±0.009 0.555±0.007 0.746±0.013 0.549±0.016 0.773±0.007 0.539±0.013 0.777±0.005 AU17 1.9% 0.288±0.020 0.767±0.014 0.204±0.048 0.719±0.036 0.248±0.048 0.767±0.011 0.248±0.007 0.777±0.012 AU25 17.7% 0.358±0.033 0.635±0.011 0.407±0.006 0.618±0.011 0.378±0.009 0.638±0.011 0.401±0.014 0.638±0.003 AU28 1.25% 0.280±0.111 0.840±0.076 0.144±0.092 0.639±0.195 0.483±0.069 0.898±0.006 0.490±0.078 0.904±0.011 AU45 19.7% 0.333±0.036 0.702±0.022 0.311±0.016 0.668±0.019 0.401±0.009 0.738±0.010 0.398±0.005 0.734±0.005 AVG 0.347±0.026 0.735±0.014 0.310±0.015 0.673±0.028 0.412±0.018 0.771±0.003 0.416±0.018 0.775±0.004 1For the CK, SEMAINE, and DISFA databases, 66 landmarks are detected [26] for face alignment and warping. For the BP4D database, the 49 landmarks provided in the database are used for face alignment. 2Psychological studies show that each AU activation ranges from 48 to 800 frames at 30fps [27]. 6 Table 2: Performance comparison of CNN, B-CNN, and IB-CNN on the DISFA database in terms of F1 score and 2AFC score. The format is mean±std. PPos: percentage of positive samples in the whole database. AUs PPos CNN B-CNN IB-CNN F1 2AFC F1 2AFC F1 2AFC AU1 6.71% 0.257±0.200 0.724±0.116 0.259±0.150 0.780±0.079 0.327±0.204 0.773±0.119 AU2 5.63% 0.346±0.226 0.769±0.119 0.333±0.197 0.835±0.085 0.394±0.219 0.849±0.073 AU4 18.8% 0.515±0.208 0.820±0.116 0.446±0.186 0.793±0.083 0.586±0.104 0.886±0.060 AU5 2.09% 0.195±0.129 0.780±0.154 0.184±0.114 0.749±0.279 0.312±0.153 0.887±0.076 AU6 14.9% 0.619±0.072 0.896±0.042 0.596±0.086 0.906±0.040 0.624±0.069 0.917±0.026 AU9 5.45% 0.340±0.131 0.859±0.081 0.331±0.115 0.895±0.057 0.385±0.137 0.900±0.057 AU12 23.5% 0.718±0.063 0.943±0.028 0.686±0.083 0.913±0.030 0.778±0.047 0.953±0.020 AU15 6.01% 0.174±0.132 0.586±0.174 0.224±0.120 0.753±0.091 0.135±0.122 0.511±0.226 AU17 9.88% 0.281±0.154 0.678±0.125 0.330±0.132 0.763±0.086 0.376±0.222 0.742±0.148 AU20 3.46% 0.134±0.113 0.604±0.155 0.184±0.101 0.757±0.083 0.126±0.069 0.628±0.151 AU25 35.2% 0.716±0.111 0.890±0.064 0.670±0.064 0.844±0.049 0.822±0.076 0.922±0.063 AU26 19.1% 0.563±0.152 0.810±0.073 0.507±0.131 0.797±0.054 0.578±0.155 0.876±0.039 AVG 0.405±0.055 0.780±0.036 0.398±0.059 0.815±0.031 0.457±0.067 0.823±0.031 Table 3: Performance comparison with the state-of-the-art methods on four benchmark databases in terms of common metrics. ACC: Average classification rate. CK SEMAINE BP4D DISFA Methods ACC Methods F1 Methods F1 Methods 2AFC ACC AAM [29] 0.955 LGBP [11] 0.351 LGBP [11] 0.580 Gabor [12] N/A 0.857 Gabor+DBN [30] 0.933 CNN [9] 0.341 CNN [9] 0.522 BGCS [31] N/A 0.868 LBP [32] 0.949 DLA-SIFT [16] 0.435 DLA-SIFT [16] 0.591 LPQ [17] 0.810 N/A ML-CNN [33] 0.757 0.846 CNN (baseline) 0.937 CNN (baseline) 0.347 CNN (baseline) 0.510 CNN (baseline) 0.780 0.839 IB-CNN 0.951 IB-CNN 0.416 IB-CNN 0.578 IB-CNN 0.825 0.858 Performance evaluation on the DISFA database: A 9-fold cross-validation strategy is employed for the DISFA database, where 8 subsets of 24 subjects were utilized for training and the remaining one subset of 3 subjects for testing. For each fold, the training-testing process was repeated 5 times. The mean and standard deviation of the F1 score and the 2AFC score are calculated from the 5 × 9 runs for each target AU and reported in Table 2. As shown in Table 2, the proposed IB-CNN improves the performance from 0.405 (CNN) and 0.398 (B-CNN) to 0.457 (IB-CNN) in terms of the average F1 score and from 0.780 (CNN) and 0.815 (B-CNN) to 0.823 (IB-CNN) in terms of 2AFC score. Similar to the results on the SEMAINE database, the performance improvement of the infrequent AUs is more impressive. AU5 (upper lid raiser) has the least number of occurrences, i.e., 2.09% positive samples, in the DISFA database. The recognition performance increases from 0.195 (CNN) and 0.184 (B-CNN) to 0.312 (IB-CNN) in terms of the average F1 score. Comparison with the State-of-the-Art methods: We further compare the proposed IB-CNN with the state-of-the-art methods, especially the CNN-based methods, evaluated on the four benchmark databases using the metrics that are common in those papers 3. As shown in Tables 3, the performance of IB-CNN is comparable with the state-of-the-art methods and more importantly, outperforms the CNN-based methods. 4.4 Data Analysis 0.1 0.5 1 2 4 8 16 0.2 0.3 0.4 0.5 Value of c in function η F1 Score Figure 4: Recognition performance versus the choice of η. Data analysis of the parameter η: The value of η can affect the slope of the simulated sign(·) function and consequently, the gradient and optimization process. When η is smaller than 0.5, the simulation is more similar to the real sign(·), but the derivative is near zero for most of the input data, which can cause slow convergence or divergence. An experiment was conducted to analyze the influence of η = σ c in Eq. 1. Specifically, an average F1 score is calculated from all AUs in the SEMAINE database while varying the value of c. As illustrated in Figure 4, the recognition performance in terms of the average F1 score is robust to the choice of η when c ranges from 0.5 to 16. In our experiment, η is set to half of the standard deviation σ 2 , empirically. Data Analysis of the number of input neurons in the IB layer: Selecting an exact number of nodes for the hidden layers remains an open question. An experiment was conducted to demonstrate that the proposed IB-CNN is insensitive to the number of input neurons. Specifically, a set of IB3Since the testing sets of the SEMAINE and BP4D database are not available, the IB-CNN is compared with the method reported on the validation sets. 7 CNNs, with the number of input neurons of 64, 128, 256, 512, 1042, and 2048, were trained and tested on the SEMAINE database. For each IB-CNN, the average F1 score is computed over 5 runs for each AU. As shown in Figure 5, the B-CNN and especially, the proposed IB-CNN is more robust to the number of input neurons compared to the traditional CNN since a small set of neurons are active in contrast to the FC layer in the traditional CNN. CNN B-CNN IB-CNN F1 Score F1 Score 64 128 256 512 1024 2048 0 0.1 0.2 0.3 0.4 0.5 AU2 64 128 256 512 1024 2048 0 0.1 0.2 0.3 0.4 0.5 0.6 AU12 64 128 256 512 1024 2048 0 0.1 0.2 0.3 0.4 AU17 64 128 256 512 1024 2048 0 0.1 0.2 0.3 0.4 0.5 AU25 64 128 256 512 1024 2048 0 0.1 0.2 0.3 0.4 0.5 0.6 AU28 64 128 256 512 1024 2048 0 0.1 0.2 0.3 0.4 0.5 AU45 Figure 5: Recognition performance versus the number of input neurons in the IB layer. −11 −10 −9 −8 −7 0 0.2 0.4 0.6 0.8 Log Learning Rate F1 Score CNN IB-CNN Figure 6: Recognition performance versus the learning rate γ. Data analysis of learning rate γ: Another issue in CNNs is the choice of the learning rate γ. The performance of the IB-CNN at different learning rates is depicted in Figure 6 in terms of the average F1 score calculated from all AUs on the SEMAINE database. Compared to the traditional CNN, the proposed IB-CNN is less sensitive to the value of the learning rate. 5 Conclusion and Future Work In this paper, a novel IB-CNN was proposed to integrate boosting classification into a CNN for the application of AU recognition. To deal with limited positive samples in a mini-batch, an incremental boosting algorithm was developed to accumulate information from multiple batches over time. A novel loss function that accounts for errors from both the incremental strong classifier and individual weak classifiers is proposed to fine-tune the IB-CNN. Experimental results on four benchmark AU databases have demonstrated that the IB-CNN achieves significant improvement over the traditional CNN, as well as the stateof-the-art CNN-based methods for AU recognition. Furthermore, the IB-CNN is more effective in recognizing infrequent AUs with limited training data. The IB-CNN is a general machine learning method and can be adapted to other learning tasks, especially those with limited training data. In the future, we plan to extend it to multitask learning by replacing the binary classifier with a multiclass boosting classifier. Acknowledgment This work is supported by National Science Foundation under CAREER Award IIS-1149787. References [1] Ekman, P., Friesen, W.V., Hager, J.C.: Facial Action Coding System: the Manual. Research Nexus, Div., Network Information Research Corp., Salt Lake City, UT (2002) [2] Zeng, Z., Pantic, M., Roisman, G.I., Huang, T.S.: A survey of affect recognition methods: Audio, visual, and spontaneous expressions. IEEE T-PAMI 31(1) (Jan. 2009) 39–58 [3] Sariyanidi, E., Gunes, H., Cavallaro, A.: Automatic analysis of facial affect: A survey of registration, representation and recognition. IEEE T-PAMI 37(6) (June 2015) 1113–1133 [4] Fasel, B.: Head-pose invariant facial expression recognition using convolutional neural networks. In: ICMI. (2002) 529–534 [5] Rifai, S., Bengio, Y., Courville, A., Vincent, P., Mirza, M.: Disentangling factors of variation for facial expression recognition. In: ECCV. (2012) 808–822 [6] Tang, Y.: Deep learning using linear support vector machines. In: ICML. (2013) 8 [7] Liu, M., Li, S., Shan, S., Wang, R., Chen, X.: Deeply learning deformable facial action parts model for dynamic expression analysis. In: ACCV. (2014) [8] Jung, H., Lee, S., Yim, J., Park, S., Kim, J.: Joint fine-tuning in deep neural networks for facial expression recognition. In: ICCV. (2015) 2983–2991 [9] Gudi, A., Tasli, H.E., den Uyl, T.M., Maroulis, A.: Deep learning based FACS action unit occurrence and intensity estimation. In: FG. (2015) [10] Jaiswal, S., Valstar, M.F.: Deep learning the dynamic appearance and shape of facial action units. In: WACV. (2016) [11] Valstar, M., Girard, J., Almaev, T., McKeown, G., Mehu, M., Yin, L., Pantic, M., Cohn, J.: FERA 2015 second facial expression recognition and analysis challenge. FG (2015) [12] Mavadati, S.M., Mahoor, M.H., Bartlett, K., Trinh, P., Cohn, J.F.: Disfa: A spontaneous facial action intensity database. IEEE Trans. on Affective Computing 4(2) (2013) 151–160 [13] Bartlett, M.S., Littlewort, G., Frank, M.G., Lainscsek, C., Fasel, I., Movellan, J.R.: Recognizing facial expression: Machine learning and application to spontaneous behavior. In: CVPR. (2005) 568–573 [14] Valstar, M.F., Mehu, M., Jiang, B., Pantic, M., Scherer, K.: Meta-analysis of the first facial expression recognition challenge. IEEE T-SMC-B 42(4) (2012) 966–979 [15] Baltrusaitis, T., Mahmoud, M., Robinson, P.: Cross-dataset learning and person-specific normalisation for automatic action unit detection. In: FG. Volume 6. (2015) 1–6 [16] Yuce, A., Gao, H., Thiran, J.: Discriminant multi-label manifold embedding for facial action unit detection. In: FG. (2015) [17] Jiang, B., Martinez, B., Valstar, M.F., Pantic, M.: Decision level fusion of domain specific regions for facial action recognition. In: ICPR, IEEE (2014) 1776–1781 [18] Zhao, G., Pietiäinen, M.: Dynamic texture recognition using local binary patterns with an application to facial expressions. IEEE T-PAMI 29(6) (June 2007) 915–928 [19] Yang, P., Liu, Q., Metaxas, D.N.: Boosting encoded dynamic features for facial expression recognition. Pattern Recognition Letters 30(2) (Jan. 2009) 132–139 [20] Zafeiriou, S., Petrou, M.: Sparse representations for facial expressions recognition via L1 optimization. In: CVPR Workshops. (2010) 32–39 [21] Liu, P., Han, S., Meng, Z., Tong, Y.: Facial expression recognition via a boosted deep belief network. In: CVPR. (2014) [22] Nagi, J., Di Caro, G.A., Giusti, A., Nagi, F., Gambardella, L.M.: Convolutional neural support vector machines: hybrid visual pattern classifiers for multi-robot systems. In: ICMLA. (2012) 27–32 [23] Hinton, G.E., Srivastava, N., Krizhevsky, A., Sutskever, I., Salakhutdinov, R.: Improving neural networks by preventing co-adaptation of feature detectors. arXiv preprint (2012) [24] Medera, D., Babinec, S.: Incremental learning of convolutional neural networks. In: IJCCI. (2009) 547– 550 [25] Kanade, T., Cohn, J.F., Tian, Y.: Comprehensive database for facial expression analysis. In: FG. (2000) 46–53 [26] Asthana, A., Zafeiriou, S., Cheng, S., Pantic, M.: Robust discriminative response map fitting with constrained local models. In: CVPR. (2013) 3444–3451 [27] Sayette, M.A., Cohn, J.F., Wertz, J.M., Perrott, M.A., Parrott, D.J.: A psychometric evaluation of the facial action coding system for assessing spontaneous expression. J. Nonverbal Behavior 25(3) (2001) 167–185 [28] Jia, Y., Shelhamer, E., Donahue, J., Karayev, S., Long, J., Girshick, R., Guadarrama, S., Darrell, T.: Caffe: Convolutional architecture for fast feature embedding. In: ACM MM, ACM (2014) 675–678 [29] Lucey, S., Ashraf, A.B., Cohn, J.: Investigating spontaneous facial action recognition through AAM representations of the face. In Kurihara, K., ed.: Face Recognition Book. Pro Literatur Verlag, Mammendorf, Germany (April 2007) [30] Tong, Y., Liao, W., Ji, Q.: Facial action unit recognition by exploiting their dynamic and semantic relationships. IEEE T-PAMI 29(10) (October 2007) 1683–1699 [31] Song, Y., McDuff, D., Vasisht, D., Kapoor, A.: Exploiting sparsity and co-occurrence structure for action unit recognition. In: FG. (2015) [32] Han, S., Meng, Z., Liu, P., Tong, Y.: Facial grid transformation: A novel face registration approach for improving facial action unit recognition. In: ICIP. (2014) [33] Ghosh, S., Laksana, E., Scherer, S., Morency, L.: A multi-label convolutional neural network approach to cross-domain action unit detection. ACII (2015) 9 | 2016 | 473 |
6,409 | An urn model for majority voting in classification ensembles Victor Soto Computer Science Department Columbia University New York, NY, USA vsoto@cs.columbia.edu Alberto Suárez and Gonzalo Martínez-Muñoz Computer Science Department Universidad Autónoma de Madrid Madrid, Spain {gonzalo.martinez,alberto.suarez}@uam.es Abstract In this work we analyze the class prediction of parallel randomized ensembles by majority voting as an urn model. For a given test instance, the ensemble can be viewed as an urn of marbles of different colors. A marble represents an individual classifier. Its color represents the class label prediction of the corresponding classifier. The sequential querying of classifiers in the ensemble can be seen as draws without replacement from the urn. An analysis of this classical urn model based on the hypergeometric distribution makes it possible to estimate the confidence on the outcome of majority voting when only a fraction of the individual predictions is known. These estimates can be used to speed up the prediction by the ensemble. Specifically, the aggregation of votes can be halted when the confidence in the final prediction is sufficiently high. If one assumes a uniform prior for the distribution of possible votes the analysis is shown to be equivalent to a previous one based on Dirichlet distributions. The advantage of the current approach is that prior knowledge on the possible vote outcomes can be readily incorporated in a Bayesian framework. We show how incorporating this type of problem-specific knowledge into the statistical analysis of majority voting leads to faster classification by the ensemble and allows us to estimate the expected average speed-up beforehand. 1 Introduction Combining the outputs of multiple predictors is in many cases of interest a successful strategy to improve the capabilities of artificial intelligence systems, ranging from agent architectures [19], to committee learning [13, 15, 8, 9]. A common approach is to build a collection of individual subsystems and then integrate their outputs into a final decision by means of a voting process. Specifically, in the machine learning literature, there is extensive empirical evidence on the improvements in generalization capacity that can be obtained using ensembles of learners [7, 11]. However, one of the drawbacks of these types of systems is the linear memory and time costs incurred in the computation of the final ensemble prediction by combination of the individual predictions. There are various strategies that alleviate these shortcomings. These techniques are grouped into static (or off-line) and dynamic (or online). In static pruning techniques, only a subset of complementary predictors from the original ensemble is kept [16, 21, 6]. By contrast, in dynamic pruning, the whole ensemble is retained. The prediction of the class label of a particular instance is accelerated by halting the sequential querying process when it is unlikely that the remaining (unknown) votes would change the output prediction [10, 20, 14, 12, 2, 3, 17]. These techniques are online in the sense that, as new individual predictions become known, the algorithm dynamically updated the estimated probability of having a stable prediction; i.d. a prediction that coincides with that by the complete ensemble. This is the basis of the Statistical Instance-Based Algorithm (SIBA) proposed in [14]. In a similar 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. approach, albeit with a different objective, Reyzin proposes to randomly sample hypotheses from the original AdaBoost ensemble. The goal is to minimize the number of features that are used for prediction, with a limited loss of accuracy [18]. This feature-efficient prediction is beneficial when access to the features of a new instance at test time is costly (e.g., in some medical problems). A different approach is followed in [3]. In this work, a policy is learned to decide which classifiers should be queried and which discarded in the prediction of the class label of a given instance. The dynamic ensemble pruning method proposed in this work is closely related to SIBA [14]. In SIBA, the members of a committee are queried sequentially. At each step in the querying process, the votes recorded are used to estimate the probability that the majority decision of the classifiers queried up to that moment coincides with the complete ensemble. If this probability exceeds a specified confidence level, α, the voting process is halted. To compute this estimate, the probability that a single predictor outputs a given decision for the particular instance considered is modeled as a random variable. Starting from a uniform prior, Bayes’ theorem is used to update the distribution of this variable with the information provided by the actual votes, as they become known. In most of the problems analyzed in [14], the assumption that the prior is uniform leads to conservative estimates of the confidence on the stability of the predictions when only a fraction of the classifiers have been queried. Analyzing the results of those experiments, it is apparent that the actual disagreement percentages between the dynamic decision output and the decision made by the complete committee are significantly lower than the specified target α. As a consequence, more queries are made than the ones that are actually needed. The present work has two objectives. First, we propose an intuitive mathematical modeling of the voting process in ensembles of classifiers based on the hypergeometric distribution. Under the assumption that the distribution of possible vote outcomes is uniform, we prove that this derivation is equivalent to the one presented in [14]. However, the vote distribution is, in general, not uniform. Its shape depends on the classification task considered and on the base learning algorithm used to generate the predictors. Second, to take into account this dependence, we propose to approximate this distribution using a non-parametric prior. The use of this problem-specific prior knowledge leads to more accurate estimations of the disagreement rates between the dynamic sub-committee prediction and the complete committee, which are closer to the specified target α. In this manner, faster classification can be achieved with minimal loss of accuracy. In addition, the use of priors allow us to estimate quite precisely the expected average number of trees that would be necessary to query. 2 Modeling ensemble voting processes as a classical urn problem Consider the following process modeled as a classical urn model. Let us suppose we have marbles of l different colors in an urn. The number of marbles of color yk in the urn is Tk, with k = 1 . . . l. The total number of marbles in the urn is T = Pl k=1 Tk. The contents of the urn can therefore be described by vector T = ⟨T1, T2 . . . Tl⟩. Assume that t < T marbles are extracted from the urn without replacement. This extraction process can be characterized by vector t = ⟨t1, t2 . . . tl⟩where tk is the number of marbles of color yk extracted, with t = Pl k=1 tk. The probability of extracting a color distribution of marbles t, given the initial color distribution of the urn T is described by the multivariate hypergeometric distribution P(t|T) = T1 t1 . . . Tl tl T t = Ql i=1 Ti ti T t . (1) Consider the case in which the total number of marbles in the urn, T, is known but that the color distribution, T, is unknown. In this case, the color distribution of the extracted marbles, t, can be used to estimate the content of the urn applying Bayes Theorem P(T|t) = P(t|T)P(T) P(t) = P(t|T)P(T) P T∗∈Ωt P(t|T∗)P(T∗) = T1 t1 . . . Tl tl P(T) P T∗∈Ωt T ∗ 1 t1 . . . T ∗ ltl P(T∗) (2) where Ωt is the set of vectors T∗, such that T ∗ i ≥ti ∀i and Pl i=1 T ∗ i = T. This problem is equivalent to the voting process in an ensemble of classifiers: Suppose we want to predict the class label of an instance by combining the individual predictions of the ensemble classifiers (marbles). Assuming that the individual predictions are deterministic, the class (color) that 2 each classifier (marble) would output if queried is fixed, but unknown before the query. Therefore, for each instance considered we have a different "bag of colored marbles" with an unknown class distribution. After a partial count of votes of the ensemble is known, Eq. 2 provides an estimate of the distribution of votes for the complete ensemble. This estimate can be used to compute the probability that the decision obtained using only a partial tally of votes, t, of size t < T and by the final decision using all T votes, coincide P∗(t, T) = X T∈Tt T1 t1 . . . Tl tl P(T) P T∗∈Ωt T ∗ 1 t1 . . . T ∗ ltl P(T∗) , (3) where Tt is the set of vectors of votes for the complete ensemble T = {T1, T2 . . . Tl} such that the class predicted by the subensemble of size t and the class predicted by the complete committee coincide, with Ti ≥ti, and Pl i=1 Ti = T. If P∗(t, T) = 1, then the classification given by the partial ensemble and the full ensemble coincide. This case happens when the difference between the number of votes for the first and second class in t is greater than the remaining votes in the urn. In such case, the voting process can be halted with full confidence that the decision of the partial ensemble will not change when the predictions of the remaining classifiers are considered. In addition, if it is acceptable that, with a small probability 1 −α, the prediction of the partially polled ensemble and that of the complete ensemble disagree, then the voting process can be stopped when the P∗(t, T) exceeds the specified confidence level α. The final classification would be given as the combined decisions of the classifiers that have been polled up to that point only. 2.1 Uniform prior Assuming a uniform prior for the distribution of possible T vectors P(T) = 1/∥T∥, where ∥T∥ stands for the number of possible T vectors, this derivation is equivalent to the one presented in [14]. That formulation assumes that the base classifiers of the ensemble are independent realizations from a pool of all possible classifiers given the training dataset. Assuming that an unlimited number of realizations can be performed, the distribution of class votes in the ensemble converges to a Dirichlet distribution in the limit of infinite ensemble size. Then, assuming a partial tally of t votes, the probability that the ensemble’s decision will change if the precictions of the remaining T −t classifiers are considered, can be estimated. In order to prove the equivalence between both formulations, we first need to introduce three results, presented in the theorem and propositions below. Theorem. Chu-Vandermonde Identity. Let s, t, r ∈N then s + t r = r X k=0 s k t r −k (4) Proposition 1. Upper negation. Let r ∈C and k ∈Z, then r k = (−1)k k −r −1 k (5) The previous theorem and proposition are used in the following proposition, which is the key to prove the equivalence between the two formulations: Proposition 2. Let n1 and n2 be positive integers such that n1 + n2 = n and n ≤N. Then N−n2 X i=n1 i n1 N −i n2 = N + 1 N −n (6) Proof. First the symmetry property of the binomial (i.e., n k = n n−k ) is used to bring down the indices N−n2 X i=n1 i n1 N −i n2 = N−n2 X i=n1 i i −n1 N −i N −i −n2 3 The upper indices are removed by applying the upper negation property of proposition 1. N−n2 X i=n1 i i −n1 N −i N −i −n2 = N−n2 X i=n1 −n1 −1 i −n1 −n2 −1 N −i −n2 (−1)i−n1(−1)N−i−n2 Now, the Chu-Vandermonde identity can be applied with r = N −n1 −n2 and k = i −n1 N−n2 X i=n1 −n1 −1 i −n1 −n2 −1 N −i −n2 (−1)i−n1(−1)N−i−n2 = −n −2 N −n (−1)N−n Finally the upper negation is applied again −n −2 N −n (−1)N−n = N + 1 N −n Proposition 3 Following the hypergeometric reformulation given by Equation 2 and assuming that P(T) follows a uniform distribution 1/∥T∥, where ∥T∥stands for the number of possible T vectors then P(T|t) = (T −t)! Ql i=1 (Ti −ti)! Ql i=1 (ti + 1)Ti−ti (t + l)T −t where (x)n = x(x + 1) . . . (x + n −1) is the Pochhammer symbol. This formulation is equivalent to the one proposed in [14]. Proof. Equation 2 can be simplified by taking into account the uniform prior P(T) = 1/∥T∥as P(T|t) = P(t|T)P(T) P(t) = T1 t1 . . . Tl tl P T∗∈Ωt T ∗ 1 t1 . . . T ∗ ltl (7) The indices of the summation, Ωt, is the set of vectors T such that Ti ≥ti ∀i and Pl i=1 Ti = T. They can be changed for l classes to P(T|t) = T1 t1 . . . Tl tl P ˆ T1 T ∗ 1 =t1 P ˆ T2 T ∗ 2 =t2 · · · P ˆTl−1 T ∗ l−1=tl−1 T ∗ 1 t1 . . . T ∗ ltl (8) where ˆTk for k = 1, . . . , (l −1) are the maximum values for T ∗ k in the summations. Note that the summation over T ∗ l is unnecessary since the value of T ∗ l becomes fixed once the values of T ∗ 1 . . . T ∗ l−1 are fixed since Pl i=1 T ∗ i = T. In this sense, the values for ˆTk have a dependency on T ∗ i for i < k as ˆTk = T −t + tk −Pk−1 i=1 (T ∗ i −ti), k = 1, . . . , (l −1). The summations in the denominator of Eq. 8 can be rearranged ˆ T1 X T ∗ 1 =t1 ˆ T2 X T ∗ 2 =t2 · · · ˆTl−1 X T ∗ l−1=tl−1 T ∗ 1 t1 . . . T ∗ l tl = ˆ T1 X T ∗ 1 =t1 T ∗ 1 t1 ˆ T2 X T ∗ 2 =t2 T ∗ 2 t2 · · · ˆTl−1 X T ∗ l−1=tl−1 T ∗ l−1 tl−1 T ∗ l tl . Proposition 2 (Eq. 6) can be used, together with N = T −Pl−2 i=1 T ∗ i , to express the summation over T ∗ l−1 in closed form T −t+tl−1−Pl−2 i=1(T ∗ i −ti) X T ∗ l−1=tl−1 T ∗ l−1 tl−1 T ∗ l tl = T −Pl−2 i=1 T ∗ i −tl X T ∗ l−1=tl−1 T ∗ l−1 tl−1 T −Pl−2 i=1 T ∗ i −T ∗ l−1 tl = T −Pl−2 i=1 T ∗ i + 1 T −Pl−2 i=1 T ∗ i −tl−1 −tl = T −Pl−2 i=1 T ∗ i + 1 tl−1 + tl + 1 , 4 where the symmetry property of the binomial has been used in the last step. The subsequent summations are carried out in the same manner. The summation over T ∗ k requires the application of Eq. 6 with N = T −Pk−1 i=1 T ∗ i + (l −k −1), n1 = tk and n2 = Pl i=k+1 ti + (l −k −1) ˆ T1 X T ∗ 1 =t1 T ∗ 1 t1 ... ˆTl−2 X T ∗ l−2=tl−2 T ∗ l−2 tl−2 T −Pl−2 i=1 T ∗ i + 1 tl−1 + tl + 1 = · · · = T + l −1 t + l −1 Employing this result in Eq. 8, one obtains P(T|t) = T1 t1 . . . Tl tl T +l−1 t+l−1 = T1! t1!(T1−t1)! . . . Tl! tl!(Tl−tl)! (T +l−1)! (t+l−1)!(T −t)! = (T −t)! Ql i=1 (Ti −ti)! Ql i=1 (ti + 1)Ti−ti (t + l)T −t . 2.2 Non-uniform prior The distribution P(T) can be modeled using a non-parametric non-uniform prior. The values of this prior can be obtained from the training data by some form of validation; e.g., out-of-bag or cross validation. Out-of-bag validation is faster because it does not require multiple generations of the ensemble. Therefore, it will be the validation method used in our implementation of the method. To compute the out-of-bag error, each training instance, xn, is classified by the ensemble predictors that do not have that particular instance in their training set. Let ˜T n = ˜T n 1 + . . . + ˜T n l , be the number of such classifiers, where ˜T n i is the number of out-of-bag votes for class i, where i = 1, . . . , l, assigned to instance xn. The number of votes for each class for an ensemble of size T is estimated as T n i ≈round(T ˜T n i / ˜T n). To mitigate the influence of the random fluctuations that appear because of the finite size of the training set and to avoid spurious numeric artifacts, the prior is subsequently smoothed using a sliding window of size 5 over the vote distribution. As shown in Section 2, the response time of the ensemble can be reduced by using Eq. 3, if we allow that a small fraction, 1 −α, of the predictions given by ensembles of size t and T do not coincide. Assuming this tolerance, when P∗(t, T) > α, the voting process can be halted and the ensemble will output the decision given by the t ≤T queried classifiers. However, the computation of Eq. 3 is costly and should be performed off-line. In the SIBA formulation, a lookup table indexed by the number of votes of the minority class (for binary problems) and whose values are the minimum number of votes of the majority class such that P∗(t, T) > α, is used. Using a precomputed lookup table to halt the voting process does not entail a significant overhead during classification: a single lookup operation in the table is needed for each vote. The consequence of using a uniform prior is that all classes are considered equivalent. Hence, it is sufficient to compute one lookup table and use the minority class for indexing. When prior knowledge is taken into account, the probability P∗(t1 = n, t2 = m, T) is not necessarily equal to P∗(t1 = m, t2 = n, T) for n ̸= m. Therefore, a different lookup table per class will be necessary. In addition, it is necessary to compute a different set of tables for each dataset. In the original formulation, the lookup table values depend only on T and α. Therefore, they are independent of the particular classification problem considered. In our case, the prior distribution is estimated from the training data: Hence, it is problem dependent. However, the querying process is similar to SIBA. For instance, if we have 1 vote for class 1 and 7 for class 2, one determines whether the value in position 1 (minority class at this moment) of the lookup table for class 1 is greater or equal to 7. If it is, the querying process stops. As a side effect, for the experimental comparison, it is necessary to recompute the lookup tables for each realization of the data. Notwithstanding, in a real setting, these tables need to be computed only once. This can be done offline. Therefore, the speed improvements in the classification phase are independent of the size of the training set. The lookup table and the estimated non-parametric prior can be used to estimate also the average number of classifiers that are expected to be queried during test. This estimation can be made using Monte Carlo simulation. To this end one would perform the following experiment repeatedly and compute the average number of queries: extract a random vector T from the prior distribution; generate a vector of votes of size T that contains exactly Ti votes for class i with i = 1 . . . l; finally, query a random permutation of this vector of votes until the process can be halted as given by the lookup table and keep the number of queries. 5 3 Experiments In this section we present the results of an extensive empirical evaluation of the dynamical ensemble pruning method described in the previous section. The experiments are performed in a series of benchmark classification problems from the UCI Repository [1] and synthetic data [4] using Random Forests [5]. The code is available at: https://github.com/vsoto/majority-ibp-prior. The protocol for the experiments is as follows: for each problem, 100 partitions are created by 10 × 10-fold cross-validation for real datasets and by random sampling in the synthetic datasets. All the classification tasks considered are binary, except for New-thyroid, Waveform and Wine, which have three classes. For each partition, the following steps are carried out: (i) a Random Forest ensemble of size T = 101 is built; (ii) we compute the generalization error rate of the complete ensemble in the test set and record the mean number of trees that are queried to determine the final prediction. Note that this number need not be T: the voting process can be halted when the remaining votes (i.e. the predictions of classifiers that have not been queried up to that point) cannot modify the partial ensemble decision. This is the case when the number of remaining votes is below the difference between the majority class and the second most voted class; (iii) The SIBA algorithm [14] is applied to dynamically select the number of classifiers that are needed for each instance in the test set to achieve a level of confidence in the prediction above α = 0.99. We use SIBA as the benchmark for comparison since in previous studies it has been shown to provide the best overall results, especially for T < 500 [2]; (iv) The process is repeated using the proposed method with non-uniform priors for the class vote distribution, with the same confidence threshold, α = 0.99. The prior distribution P(T) is estimated in the training set using out-of-bag data. This prior is also used to estimate the expected number of trees to be queried in the testing phase. In addition, for steps (iii) and (iv) we compute the test error rate, the average number of queried trees, and the disagreement rates between the predictions of the partially queried ensembles and the complete ones. Table 1: Error rates (left) and disagreement % (right). The statistical significant differences, using paired t-tests at a significance level α = 0.05, are highlighted in boldface. Error rates Disagreement % Problem RF SIBA HYPER SIBA HYPER Australian 13.00±3.7 13.09±3.7 13.25±3.8 0.3±0.6 0.9±1.1 Breast 3.22±2.1 3.23±2.1 3.76±2.3 0.1±0.4 1.0±1.1 Diabetes 24.34±4.2 24.25±4.1 24.23±4.0 0.6±0.9 0.8±1.0 Echocardiogram 22.18±14.3 22.05±14.7 22.18±14.1 0.7±3.1 1.4±4.6 German 23.43±3.5 23.65±3.3 23.62±3.3 0.8±0.8 0.8±0.9 Heart 18.30±6.9 18.37±7.0 18.37±7.2 0.8±1.8 1.0±2.1 Horse-colic 15.47±5.6 15.44±5.4 15.44±5.4 0.4±0.9 0.7±1.3 Ionosphere 6.44±4.1 6.44±4.1 6.52±3.9 0.1±0.6 0.7±1.3 Labor 6.33±8.9 6.17±8.8 6.43±9.1 0.2±1.7 1.2±4.5 Liver 27.10±6.7 27.09±7.0 27.01±6.9 1.0±1.7 0.9±1.5 Mushroom 0.00±0.0 0.00±0.0 0.08±0.2 0.0±0.0 0.1±0.2 New-thyroid 4.29±4.0 4.38±4.0 4.66±4.2 0.1±0.7 0.7±2.0 Ringnorm 7.60±1.3 7.72±1.2 7.82±1.2 0.5±0.2 0.8±0.3 Sonar 16.25±8.7 16.45±8.7 16.45±8.8 0.9±2.0 0.8±1.9 Spam 4.59±1.5 4.63±1.5 4.86±1.4 0.1±0.2 0.7±0.4 Threenorm 17.85±1.1 18.04±1.1 17.97±1.1 1.0±0.2 0.8±0.2 Tic-tac-toe 1.05±1.1 1.16±1.1 1.72±1.5 0.1±0.4 0.7±1.0 Twonorm 4.66±0.6 4.77±0.6 4.90±0.6 0.4±0.1 0.7±0.2 Votes 4.05±2.9 4.12±2.9 4.30±2.9 0.1±0.4 1.0±1.8 Waveform 17.30±0.9 17.36±0.8 17.45±0.8 0.6±0.1 1.0±0.3 Wine 1.69±2.8 1.74±2.8 2.30±3.5 0.1±0.6 1.1±2.5 In Table 1, we compare the error rates of Random Forest (RF) and of the dynamically pruned ensembles using the halting rule derived from assuming uniform priors (SIBA) and using nonuniform priors (HYPER), and the disagreement rates. The values displayed are averages over 100 realizations of the datasets The standard deviation is given after the ± symbol. 6 0 10 20 30 40 50 60 70 80 90 100 0 0.005 0.01 0.015 0.02 0.025 t1 P(t1) 0 0.02 0.04 0.06 0.08 0.1 0.12 0 0.005 0.01 0.015 0.02 0.025 0.03 0.035 0.04 0.045 0.05 disagreement 1-alpha sonar HYPER SIBA FIXED 0 10 20 30 40 50 60 70 80 90 100 0 0.05 0.1 0.15 0.2 0.25 0.3 t1 P(t1) 0 0.01 0.02 0.03 0.04 0.05 0.06 0 0.005 0.01 0.015 0.02 0.025 0.03 0.035 0.04 0.045 0.05 disagreement 1-alpha votes HYPER SIBA FIXED Figure 1: Vote distribution, P(T), and disagreement rates for Sonar (left) and Votes (right) From Table 1, one observes that the mean error rates of the pruned ensembles using SIBA and HYPER are only slightly worse than the rates obtained by the complete ensemble (RF). These differences should be expected since we are allowing a small disagreement of 1 −α = 1% between the decisions of the partial and the complete ensemble. In any case, the differences in generalization error can be made arbitrarily small by increasing α. By design, the disagreement rates are expected to be below, but close to 1%. From Table 1, one observes that the disagreement % of the proposed method (HYPER) are closer to the specified threshold (1 −α = 1%) than those of SIBA, except for Liver, Sonar and Threenorm, where the differences are small. In these problems (and in general in the problems where SIBA obtains disagreement rates closer to 1 −α), the distribution of T is closer to a uniform distribution (see Figure 1, left histogram). In consequence, the assumption of uniform prior taken by SIBA is closer to the real one. However, when P(T) differs from the uniform distribution (see for instance Votes in Figure 1 right histogram) the results of SIBA are rather different from the expected disagreement rates. Table 2: Number of queried trees and speed-up rate with respect to the full ensemble of 101 trees. The statistical significant differences between SIBA and HYPER, using paired t-tests at a significance level α = 0.05, are highlighted in boldface. # of trees Speed-up rate Problem RF∗ SIBA HYPER MC Estim RF∗ SIBA HYPER Australian 62.2±1.4 16.1±2.1 12.8±2.3 12.9±0.9 1.6 6.3 7.9 Breast 54.2±0.9 8.9±1.4 4.0±1.0 4.0±0.4 1.9 11.3 25.3 Diabetes 68.8±1.8 24.9±3.2 24.0±3.2 23.8±1.1 1.5 4.1 4.2 Echocardiogram 68.0±4.6 22.6±8.2 20.0±8.0 21.6±3.2 1.5 4.5 5.1 German 71.8±1.3 28.4±2.8 27.7±2.9 30.1±1.0 1.4 3.6 3.6 Heart 67.2±2.5 22.5±4.2 20.9±4.2 20.7±1.7 1.5 4.5 4.8 Horse-colic 66.2±2.1 20.2±3.5 17.5±3.7 18.6±1.5 1.5 5.0 5.8 Ionosphere 57.9±1.5 11.9±2.3 7.8±2.1 7.8±0.6 1.7 8.5 12.9 Labor 61.6±4.0 14.1±6.0 9.7±5.3 10.2±2.0 1.6 7.2 10.4 Liver 74.5±2.3 31.8±4.5 31.7±4.5 31.6±2.0 1.4 3.2 3.2 Mushroom 51.0±0.0 6.0±0.0 1.0±0.0 1.0±0.0 2.0 16.8 101.0 New-thyroid 55.2±1.8 10.7±2.6 6.0±2.3 6.2±1.4 1.8 9.4 16.8 Ringnorm 68.6±0.8 22.9±1.1 20.4±1.5 19.7±2.3 1.5 4.4 5.0 Sonar 73.9±3.0 32.1±6.6 32.6±6.8 31.8±2.4 1.4 3.1 3.1 Spam 57.1±0.3 11.1±0.5 7.2±0.6 7.1±0.5 1.8 9.1 14.0 Threenorm 76.6±0.5 34.8±1.0 35.8±1.6 33.4±2.5 1.3 2.9 2.8 Tic-tac-toe 60.7±0.9 12.8±1.4 7.8±1.2 8.6±0.7 1.7 7.9 12.9 Twonorm 67.2±0.2 21.0±0.5 18.4±0.9 18.8±1.7 1.5 4.8 5.5 Votes 54.5±1.2 8.8±1.8 4.1±1.4 4.0±0.7 1.9 11.5 24.6 Waveform 72.3±0.7 29.3±1.1 27.8±1.7 28.6±2.8 1.4 3.4 3.6 Wine 57.3±2.1 11.4±2.7 5.8±1.8 6.7±1.4 1.8 8.9 17.5 In order to analyze this aspect in more detail, we have computed the disagreement rates for different values of alpha (α = 0.999, 0.995, 0.99, 0.95). In Figure 1 the relation between the target 1 −α and the actual disagreement rate is presented. A diagonal solid line marks the expected upper limit for the disagreement. The results for SIBA, HYPER and for the case of using a fixed number of trees for all instances (FIXED) (and equal to the average number of trees used by HYPER in those tasks) 7 are presented in these plots. This last case (FIXED) can be seen as a stochastic approximation to the prediction of the whole ensemble. From these plots, we observe that the results for HYPER are very close to the expected disagreement rates for cases in which the prior is approximately uniform (Sonar), and for cases in which the prior is non-uniform (Votes). As expected, the results of SIBA are close to the target only for the case of approximately uniform prior (Sonar). Finally, when a stochastic approximation is used (FIXED) the disagreement rates are clearly above the target threshold given by α. From these results we conclude that the proposed model provides a more accurate description of the voting process used to compute the prediction of the ensemble. This means that taking into account the prior distribution of possible vote outcomes, P(T), is important to obtain disagreement rates that are closer to the threshold established. Finally, in Table 2, we present the average number of trees used by Random Forest (RF∗), the SIBA method,the proposed method using non-parametric priors (HYPER), and the expected average of the number of trees to be queried in HYPER using Monte Carlo sampling (MC Estim). Note that the number of trees used by RF∗is not necessary T = 101: the voting process is halted when the remaining (unknown) predictions cannot alter the decision of the ensemble. The number of trees given in RF∗is the same as the trees that SIBA or HYPER would use when α = 100%. Finally, the last three columns of Table 2 display the speed-up rate of the partial ensembles with respect to the full ensemble of size T = 101. From this table it is clear that HYPER reduces the number of queried classifiers with respect to SIBA in most of the tasks investigated. In addition, using only training data, the Monte Carlo estimations of the average number of trees are very precise. The largest average difference between this estimation and HYPER is 2.4 trees for German and Threenorm. The speed-up rate of HYPER with respect to the full ensemble is remarkable: from 2.8 times faster for Threenorm to 101 times faster in Mushroom. This dataset can be used to illustrate the benefits of using the prior distribution. For this problem, most classifiers agree in their predictions. HYPER takes advantage of this prior knowledge and queries only one classifier to cast the final decision. In this problem, the chances that the prediction of a single classifier, and the prediction of the complete ensemble are different, are below 1%. Similar behavior (but not as extreme) is observed in Breast and Votes. 4 Conclusions In this work, we present an intuitive, rigorous mathematical description of the voting process in an ensemble of classifiers: For a given an instance, the process is equivalent to extracting marbles (the individual classifiers), without replacement, from a bag that contains a known number of marbles, but whose color (class label prediction) distribution is unknown. In addition, we show that for the specific case of a uniform prior distribution of class votes this process is equivalent to the one developed in [14]. In the current description, which does not assume a uniform distribution prior for the class votes, the hypergeometric distribution plays a central role. The results of this statistical description are then used to design a dynamic ensemble pruning method, with the goal of speeding up predictions in the test phase. For a given instance, it is possible to compute the probability that the the partial decision made on the basis of the known votes (i.e., the class label predictions of the subset of classifiers that have been queried) and the final ensemble decision coincide. If this probability is above a specified threshold, sufficiently close to 1, a reliable estimate of the class label that the complete ensemble would predict can be made on the basis of the known votes. The effectiveness of this dynamic ensemble pruning method is illustrated using random forests. The prior distribution of class votes is estimated using out-of-bag data. As a result of incorporating this problem-specific knowledge in the statistical analysis of the voting process, the differences between the predictions of the dynamically pruned ensemble and the complete ensemble are closer to the specified threshold than when a uniform distribution is assumed, as in SIBA [14]. In the empirical evaluation performed, this dynamic ensemble pruning algorithm consistently yields improvements of classification speed over SIBA without a significant deterioration of accuracy. Finally, the statistical model proposed is used to provide an accurate estimate of the average number of individual classifier predictions that are needed to reach a stable ensemble prediction. Acknowledgments The authors acknowledge financial support from the Comunidad de Madrid (project CASI-CAMCM S2013/ICE-2845), and from the Spanish Ministerio de Economía y Competitividad (projects TIN2013-42351-P and TIN2015-70308-REDT). 8 References [1] A. Asuncion and D. Newman. UCI machine learning repository, 2007. [2] J. Basilico, M. Munson, T. Kolda, K. Dixon, and W. Kegelmeyer. Comet: A recipe for learning and using large ensembles on massive data. In Proceedings - IEEE International Conference on Data Mining, ICDM, pages 41–50, 2011. [3] D. Benbouzid, R. Busa-Fekete, and B. Kégl. Fast classification using sparse decision dags. In Proceedings of the 29th International Conference on Machine Learning, ICML 2012, volume 1, pages 951–958, 2012. [4] L. Breiman. Bias, variance, and arcing classifiers. Technical Report 460, Statistics Department, University of California, 1996. [5] L. Breiman. Random forests. Machine Learning, 45(1):5–32, 2001. [6] R. Caruana and A. Niculescu-Mizil. Ensemble selection from libraries of models. In Proc. of the 21st International Conference on Machine Learning (ICML’04), 2004. [7] R. Caruana and A. Niculescu-Mizil. An empirical comparison of supervised learning algorithms. In Proc. of the 23rd International Conference on Machine Learning, pages 161–168, New York, NY, USA, 2006. ACM Press. [8] T. G. Dietterich. Ensemble methods in machine learning. In Multiple Classifier Systems: First International Workshop, pages 1–15, 2000. [9] T. G. Dietterich. An experimental comparison of three methods for constructing ensembles of decision trees: Bagging, boosting, and randomization. Machine Learning, 40(2):139–157, 2000. [10] W. Fan, F. Chu, H. Wang, and P. S. Yu. Pruning and dynamic scheduling of cost-sensitive ensembles. In Proc. of the 18th National Conference on Artificial Intelligence, pages 146–151. American Association for Artificial Intelligence, 2002. [11] M. Fernández-Delgado, E. Cernadas, S. Barro, and D. Amorim. Do we need hundreds of classifiers to solve real world classification problems? Journal of Machine Learning Research, 15:3133–3181, 2014. [12] T. Gao and D. Koller. Active classification based on value of classifier. In NIPS, 2011. [13] L. K. Hansen and P. Salamon. Neural network ensembles. IEEE Transactions on Pattern Analysis and Machine Intelligence, 12:993–1001, 1990. [14] D. Hernández-Lobato, G. Martínez-Muñoz, and A. Suárez. Statistical instance-based pruning in ensembles of independent classifiers. IEEE Transactions on Pattern Analysis and Machine Intelligence, 31(2):364–369, 2009. [15] T. K. Ho, J. J. Hull, and S. N. Srihari. Decision combination in multiple classifier systems. IEEE Transactions on Pattern Analysis Machine Intelligence, 16(1):66–75, 1994. [16] D. D. Margineantu and T. G. Dietterich. Pruning adaptive boosting. In Proc. of the 14th International Conference on Machine Learning, pages 211–218. Morgan Kaufmann, 1997. [17] F. Markatopoulou, G. Tsoumakas, and I. Vlahavas. Dynamic ensemble pruning based on multi-label classification. Neurocomputing, 150(PB):501–512, 2015. [18] L. Reyzin. Boosting on a budget: Sampling for feature-efficient prediction. In L. Getoor and T. Scheffer, editors, Proceedings of the 28th International Conference on Machine Learning (ICML-11), ICML ’11, pages 529–536, New York, NY, USA, June 2011. ACM. [19] R. S. Sutton, J. Modayil, M. Delp, T. Degris, P. M. Pilarski, A. White, and D. Precup. Horde: A scalable real-time architecture for learning knowledge from unsupervised sensorimotor interaction. In S. Tumer, Yolum and Stone, editors, Proc. of 10th Int. Conf. on Autonomous Agents and Multiagent Systems (AAMAS 2011), pages 761–768, Taipei, Taiwan, 2011. [20] H. Wang, W. Fan, P. S. Yu, and J. Han. Mining concept-drifting data streams using ensemble classifiers. In KDD ’03: Proceedings of the ninth ACM SIGKDD international conference on Knowledge discovery and data mining, pages 226–235, New York, NY, USA, 2003. ACM Press. [21] Y. Zhang, S. Burer, and W. N. Street. Ensemble pruning via semi-definite programming. Journal of Machine Learning Research, 7:1315–1338, 2006. 9 | 2016 | 474 |
6,410 | Unsupervised Feature Extraction by Time-Contrastive Learning and Nonlinear ICA Aapo Hyvärinen1,2 and Hiroshi Morioka1 1 Department of Computer Science and HIIT University of Helsinki, Finland 2 Gatsby Computational Neuroscience Unit University College London, UK Abstract Nonlinear independent component analysis (ICA) provides an appealing framework for unsupervised feature learning, but the models proposed so far are not identifiable. Here, we first propose a new intuitive principle of unsupervised deep learning from time series which uses the nonstationary structure of the data. Our learning principle, time-contrastive learning (TCL), finds a representation which allows optimal discrimination of time segments (windows). Surprisingly, we show how TCL can be related to a nonlinear ICA model, when ICA is redefined to include temporal nonstationarities. In particular, we show that TCL combined with linear ICA estimates the nonlinear ICA model up to point-wise transformations of the sources, and this solution is unique — thus providing the first identifiability result for nonlinear ICA which is rigorous, constructive, as well as very general. 1 Introduction Unsupervised nonlinear feature learning, or unsupervised representation learning, is one of the biggest challenges facing machine learning. Various approaches have been proposed, many of them in the deep learning framework. Some of the most popular methods are multi-layer belief nets and Restricted Boltzmann Machines [13] as well as autoencoders [14, 31, 21], which form the basis for the ladder networks [30]. While some success has been obtained, the general consensus is that the existing methods are lacking in scalability, theoretical justification, or both; more work is urgently needed to make machine learning applicable to big unlabeled data. Better methods may be found by using the temporal structure in time series data. One approach which has shown a great promise recently is based on a set of methods variously called temporal coherence [17] or slow feature analysis [32]. The idea is to find features which change as slowly as possible, originally proposed in [6] for learning invariant features. Kernel-based methods [12, 26] and deep learning methods [23, 27, 9] have been developed to extend this principle to the general nonlinear case. However, it is not clear how one should optimally define the temporal stability criterion; these methods typically use heuristic criteria and are not based on generative models. In fact, the most satisfactory solution for unsupervised deep learning would arguably be based on estimation of probabilistic generative models, because probabilistic theory often gives optimal objectives for learning. This has been possible in linear unsupervised learning, where sparse coding and independent component analysis (ICA) use independent, typically sparse, latent variables that generate the data via a linear mixing. Unfortunately, at least without temporal structure, the nonlinear ICA model is seriously unidentifiable [18], which means that the original sources cannot be found. In spite of years of research [20], no generally applicable identifiability conditions have been found. Nevertheless, practical algorithms have been proposed [29, 1, 5] with the hope that some kind of useful solution can still be found even for data with no temporal structure (that is, an i.i.d. sample). 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. Source signals Observed signals 1 n 1 n A Generative model B Time-contrastive learning 1 2 3 T Time ( ) Nonlinear mixture: Predictions of segment labels 1 1 2 2 3 1 m Feature values T T 3 4 Multinomial logistic regression: Segments: Feature extractor: Theorem 1 Figure 1: An illustration of how we combine a new generative nonlinear ICA model with the new learning principle called time-contrastive learning (TCL). A) The probabilistic generative model is a nonlinear version of ICA, where the observed signals are given by a nonlinear transformation of source signals, which are mutually independent, and have segment-wise nonstationarity. B) In TCL we train a feature extractor to be sensitive to the nonstationarity of the data by using a multinomial logistic regression which attempts to discriminate between the segments, labelling each data point with the segment label 1, . . . , T. The feature extractor and the logistic regression together can be implemented by a conventional multi-layer perceptron with back-propagation training. Here, we combine a new heuristic principle for analysing temporal structure with a rigorous treatment of a nonlinear ICA model, leading to a new identifiability proof. The structure of our theory is illustrated in Figure 1. First, we propose to learn features using the (temporal) nonstationarity of the data. The idea is that the learned features should enable discrimination between different time windows; in other words, we search for features that provide maximal information on which part of the time series a given data point comes from. This provides a new, intuitively appealing method for feature extraction, which we call time-contrastive learning (TCL). Second, we formulate a generative model in which independent components have different distributions in different time windows, and we observe nonlinear mixtures of the components. While a special case of this principle, using nonstationary variances, has been very successfully used in linear ICA [22], our extension to the nonlinear case is completely new. Such nonstationarity of variances seems to be prominent in many kinds of data, for example EEG/MEG [2], natural video [17], and closely related to changes in volatility in financial time series; but we further generalize the nonstationarity to modulated exponential families. Finally, we show that as a special case, TCL estimates the nonlinear part of the nonlinear ICA model, leaving only a simple linear mixing to be determined by linear ICA, and a final indeterminacy in terms of a component-wise nonlinearity similar to squaring. For modulated Gaussian sources, even the squaring can be removed and we have “full” identifiability. This gives the very first identifiability proof for a high-dimensional, nonlinear, ICA mixing model — together with a practical method for its estimation. 2 Time-contrastive learning TCL is a method to train a feature extractor by using a multinomial logistic regression (MLR) classifier which aims to discriminate all segments (time windows) in a time series, given the segment indices as the labels of the data points. In more detail, TCL proceeds as follows: 1. Divide a multivariate time series xt into segments, i.e. time windows, indexed by τ = 1, . . . , T. Any temporal segmentation method can be used, e.g. simple equal-sized bins. 2. Associate each data point with the corresponding segment index τ in which the data point is contained; i.e. the data points in the segment τ are all given the same segment label τ. 2 3. Learn a feature extractor h(xt; θ) together with an MLR with a linear regression function wT τ h(xt; θ) + bτ to classify all data points with the corresponding segment labels τ used as class labels Ct, as defined above. (For example, by ordinary deep learning with h(xt; θ) being outputs in the last hidden layer and θ being network weights.) The purpose of the feature extractor is to extract a feature vector that enables the MLR to discriminate the segments. Therefore, it seems intuitively clear that the feature extractor needs to learn a useful representation of the temporal structure of the data, in particular the differences of the distributions across segments. Thus, we are effectively using a classification method (MLR) to accomplish unsupervised learning. Methods such as noise-contrastive estimation [11] and generative adversarial nets [8], see also [10], are similar in spirit, but clearly distinct from TCL which uses the temporal structure of the data by contrasting different time segments. In practice, the feature extractor needs to be capable of approximating a general nonlinear relationship between the data points and the log-odds of the classes, and it must be easy to learn from data simultaneously with the MLR. To satisfy these requirements, we use here a multilayer perceptron (MLP) as the feature extractor. Essentially, we use ordinary MLP/MLR training according to very well-known neural network theory, with the last hidden layer working as the feature extractor. Note that the MLR is here only used as an instrument for training the feature extractor, and has no practical meaning after the training. 3 TCL as approximator of log-pdf ratios We next show how the combination of the optimally discriminative feature extractor and MLR learns to model the nonstationary probability density functions (pdf’s) of the data. The posterior over classes for one data point xt in the multinomial logistic regression of TCL is given by well-known theory as p(Ct = τ|xt; θ, W, b) = exp(wT τ h(xt; θ) + bτ) 1 + PT j=2 exp(wT j h(xt; θ) + bj) (1) where Ct is a class label of the data at time t, xt is the n-dimensional data point at time t, θ is the parameter vector of the m-dimensional feature extractor (MLP) denoted by h, W = [w1, . . . , wT ] ∈ Rm×T , and b = [b1, . . . , bT ]T are the weight and bias parameters of the MLR. We fixed the elements of w1 and b1 to zero to avoid the well-known indeterminacy of the softmax function. On the other hand, the true posteriors of the segment labels can be written, by the Bayes rule, as p(Ct = τ|xt) = pτ(xt)p(Ct = τ) PT j=1 pj(xt)p(Ct = j) , (2) where p(Ct = τ) is a prior distribution of the segment label τ, and pτ(xt) = p(xt|Ct = τ). Assume that the feature extractor has a universal approximation capacity (in the sense of well-known neural network theory), and that the amount of data is infinite, so that the MLR converges to the optimal classifier. Then, we will have equality between the model posterior Eq. (1) and the true posterior in Eq. (2) for all τ. Well-known developments, intuitively based on equating the numerators in those equations and taking the pivot into account, lead to the relationship wT τ h(xt; θ) + bτ = log pτ(xt) −log p1(xt) + log p(Ct = τ) p(Ct = 1), (3) where the last term on the right-hand side is zero if the segments have equal prior probability (i.e. equal length). In other words, what the feature extractor computes after TCL training (under optimal conditions) is the log-pdf of the data point in each segment (relative to that in the first segment which was chosen as pivot above). This gives a clear probabilistic interpretation of the intuitive principle of TCL, and will be used below to show its connection to nonlinear ICA. 4 Nonlinear nonstationary ICA model In this section, seemingly unrelated to the preceding section, we define a probabilistic generative model; the connection will be explained in the next section. We assume, as typical in nonlinear ICA, 3 that the observed multivariate time series xt is a smooth and invertible nonlinear mixture of a vector of source signals st = (s1(t), . . . , sn(t)); in other words: xt = f(st). (4) The components si(t) in st are assumed mutually independent over i (but not over time t). The crucial question is how to define a suitable model for the sources, which is general enough while allowing strong identifiability results. Here, we start with the fundamental assumption that the source signals si(t) are nonstationary, and use such nonstationarity for source separation. For example, the variances (or similar scaling coefficients) could be changing as proposed earlier in the linear case [22, 24, 16]. We generalize that idea and propose a generative model for nonstationary sources based on the exponential family. Merely for mathematical convenience, we assume that the nonstationarity is much slower than the sampling rate, so the time series can be divided into segments in each of which the distribution is approximately constant (but the distribution is different in different segments). The log-pdf of the source signal with index i in the segment τ is then defined as: log pτ(si) = qi,0(si) + V X v=1 λi,v(τ)qi,v(si) −log Z(λi,1(τ), . . . , λi,V (τ)) (5) where qi,0 is a “stationary baseline” log-pdf of the source, and the qi,v, v ≥1 are nonlinear scalar functions defining the exponential family for source i; the index t is dropped for simplicity. The essential point is that the parameters λi,v(τ) of the source i depend on the segment index τ, which creates nonstationarity. The normalization constant Z disappears in all our proofs below. A simple example would be obtained by setting qi,0 = 0, V = 1, i.e., using a single modulated function qi,1 with qi,1(si) = −s2 i /2 which means that the variance of a Gaussian source is modulated, or qi,1(si) = −|si|, a modulated Laplacian source. Another interesting option might be to use two nonlinearities similar to “rectified linear units” (ReLU) given by qi,1(si) = −max(si, 0) and qi,2(si) = −max(−si, 0) to model both changes in scale (variance) and location (mean). Yet another option is to use a Gaussian baseline qi,0(si) = −s2 i /2 with a nonquadratic function qi,1. Our definition thus generalizes the linear model [22, 24, 16] to the nonlinear case, as well as to very general modulated non-Gaussian densities by allowing qi,v to be non-quadratic, using more than one qi,v per source (i.e. we can have V > 1) as well as a non-stationary baseline. We emphasize that our principle of nonstationarity is clearly distinct from the principle of linear autocorrelations previously used in the nonlinear case [12, 26]. Note further that some authors prefer to use the term blind source separation (BSS) for generative models with temporal structure. 5 Solving nonlinear ICA by TCL Now we consider the case where TCL as defined in Section 2 is applied on data generated by the nonlinear ICA model in Section 4. We refer again to Figure 1 which illustrates the total system. For simplicity, we consider the case qi,0 = 0, V = 1, i.e. the exponential family has a single modulated function qi,1 per source, and this function is the same for all sources; we will discuss the general case separately below. The modulated function will be simply denoted by q := qi,1 in the following. First, we show that the nonlinear functions q(si), i = 1, . . . , n, of the sources can be obtained as unknown linear transformations of the outputs of the feature extractor hi trained by the TCL: Theorem 1. Assume the following: A1. We observe data which is obtained by generating independent sources1 according to (5), and mixing them as in (4) with a smooth invertible f. For simplicity, we assume only a single function defining the exponential family, i.e. qi,0 = 0, V = 1 and q := qi,1 as explained above. A2. We apply TCL on the data so that the dimension of the feature extractor h is equal to the dimension of the data vector xt, i.e., m = n. 1More precisely: the sources are generated independently given the λi,v. Depending on how the λi,v are generated, there may or may not be marginal dependency between the si; see the Corollary 1 below. 4 A3. The modulation parameter matrix L with elements [L]τ,i = λi,1(τ) −λi,1(1), τ = 1, . . . , T; i = 1, . . . , n has full column rank n. (Intuitively: the variances of the components are modulated sufficiently independently of each other. Note that many segments are actually allowed to have equal distributions since this matrix is typically very tall.) Then, in the limit of infinite data, the outputs of the feature extractor are equal to q(s) = (q(s1), q(s2), . . . , q(sn))T up to an invertible linear transformation. In other words, q(st) = Ah(xt; θ) + d (6) for some constant invertible matrix A ∈Rn×n and a constant vector d ∈Rn. Sketch of proof: (see Supplementary Material for full proof) The basic idea is that after convergence we must have equality between the model of the log-pdf in each segment given by TCL in Eq. (3) and that given by nonlinear ICA, obtained by summing the RHS of Eq. (5) over i: wT τ h(x; θ) −k1(x) = n X i=1 λi,1(τ)q(si) −k2(τ) (7) where k1 does not depend on τ, and k2(τ) does not depend on x or s. We see that the functions hi(x) and q(si) must span the same linear subspace. (TCL looks at differences of log-pdf’s, introducing the baseline k1(x), but this does not actually change the subspace). This implies that the q(si) must be equal to some invertible linear transformation of h(x; θ) and a constant bias term, which gives (6). To further estimate the linear transformation A in (6), we can simply use linear ICA, under a further independence assumption regarding the generation of the λi,1: Corollary 1. Assume the λi,1 are randomly generated, independently for each i. The estimation (identification) of the q(si) can then be performed by first performing TCL, and then linear ICA on the hidden representation h(x). Proof: We only need to combine the well-known identifiability proof of linear ICA [3] with Theorem 1, noting that the quantities q(si) are now independent, and since q has a strict upper bound (which is necessary for integrability), q(si) must be non-Gaussian. In general, TCL followed by linear ICA does not allow us to exactly recover the independent components because the function q(·) can hardly be invertible, typically being something like squaring or absolute values. However, for a specific class of q including the modulated Gaussian family, we can prove a stricter form of identifiability. Slightly counterintuitively, we can recover the signs of the si, since we also know the corresponding x and the transformation is invertible: Corollary 2. Assume q(s) is a strictly monotonic function of |s|. Then, we can further identify the original si, up to strictly monotonic transformations of each source. Proof: To make pτ(s) integrable, necessarily q(s) →−∞when |s| →∞, and q(s) must have a finite maximum, which we can set to zero without restricting generality. For each fixed i, consider the manifold defined by q(gi(x))) = 0. By invertibility of g, this divides the space of x into two halves. In one half, define ˜si = q(si), and in the other, ˜si = −q(si). With such ˜si, we have thus recovered the original sources, up to the strictly monotonic transformation ˜si = c sign(si)q(si), where c is either +1 or −1. (Note that in general, the si are meaningfully defined only up to a strictly monotonic transformation, analogue to multiplication by an arbitrary constant in the linear case [3].) Summary of Theory What we have proven is that in the special case of a single q(s) which is a monotonic function of |s|, our nonlinear ICA model is identifiable, up to inevitable component-wise monotonic transformations. We also provided a practical method for the estimation of the nonlinear transformations q(si) for any general q, given by TCL followed by linear ICA. (The method provided for “inverting” q in the proof of Corollary 2 may be very difficult to implement in practice.) Extensions First, allowing a stationary baseline qi,0 does not change the Theorem at all, and a weaker form of Corollary 1 holds as well. Second, with many qi,v (V > 1), the left-hand-side of (6) will have V n entries given by all the possible qi,v(si), and the dimension of the feature extractor must be equally increased; the condition of full rank on L is likewise more complicated. Corollary 1 must then consider an independent subspace model, but it can still be proven in the same way. (The details and the proof will be presented in a later paper.) Third, the case of combining ICA with dimension reduction is treated in Supplementary Material. 5 6 Simulation on artificial data Data generation We created data from the nonlinear ICA model in Section 4, using the simplified case of the Theorem (a single function q) as follows. Nonstationary source signals (n = 20, segment length 512) were randomly generated by modulating Laplacian sources by λi,1(τ) randomly drawn so that the std’s inside the segments have a uniform distribution in [0, 1]. As the nonlinear mixing function f(s), we used an MLP (“mixing-MLP”). In order to guarantee that the mixing-MLP is invertible, we used leaky ReLU’s and the same number of units in all layers. TCL settings, training, and final linear ICA As the feature extractor to be trained by TCL, we adopted an MLP (“feature-MLP”). The segmentation in TCL was the same as in the data generation, and the number of layers was the same in the mixing-MLP and the feature-MLP. Note that when L = 1, both the mixing-MLP and feature-MLP are a one layer model, and then the observed signals are simply linear mixtures of the source signals as in a linear ICA model. As in the Theorem, we set m = n. As the activation function in the hidden layers, we used a “maxout” unit, constructed by taking the maximum across G = 2 affine fully connected weight groups. However, the output layer has “absolute value” activation units exclusively. This is because the output of the feature-MLP (i.e., h(x; θ)) should resemble q(s), based on Theorem 1, and here we used the Laplacian distribution for generating the sources. The initial weights of each layer were randomly drawn from a uniform distribution for each layer, scaled as in [7]. To train the MLP, we used back-propagation with a momentum term. To avoid overfitting, we used ℓ2 regularization for the feature-MLP and MLR. According to Corollary 1 above, after TCL we further applied linear ICA (FastICA, [15]) to the h(x; θ), and used its outputs as the final estimates of q(si). To evaluate the performance of source recovery, we computed the mean correlation coefficients between the true q(si) and their estimates. For comparison, we also applied a linear ICA method based on nonstationarity of variance (NSVICA) [16], a kernel-based nonlinear ICA method (kTDSEP) [12], and a denoising autoencoder (DAE) [31] to the observed data. We took absolute values of the estimated sources to make a fair comparison with TCL. In kTDSEP, we selected the 20 estimated components with the highest correlations with the source signals. We initialized the DAE by the stacked DAE scheme [31], and sigmoidal units were used in the hidden layers; we omitted the case L > 3 because of instability of training. Results Figure 2a) shows that after training the feature-MLP by TCL, the MLR achieved higher classification accuracies than chance level, which implies that the feature-MLP was able to learn a representation of the data nonstationarity. (Here, chance level denotes the performance of the MLP with a randomly initialized feature-MLP.) We can see that the larger the number of layers is (which means that the nonlinearity in the mixing-MLP is stronger), the more difficult it is to train the feature-MLP and the MLR. The classification accuracy also goes down when the number of segments increases, since when there are more and more classes, some of them will inevitably have very similar distributions and are thus difficult to discriminate; this is why we computed the chance level as above. Figure 2b) shows that the TCL method could reconstruct the q(si) reasonably well even for the nonlinear mixture case (L > 1), while all other methods failed (NSVICA obviously performed very well in the linear case).The figure also shows that (1) the larger the number of segments (amount of data) is, the higher the performance of the TCL method is (i.e. the method seems to converge), and (2) again, more layers makes learning more difficult. To summarize, this simulation confirms that TCL is able to estimate the nonlinear ICA model based on nonstationarity. Using more data increases performance, perhaps obviously, while making the mixing more nonlinear decreases performance. 7 Experiments on real brain imaging data To evaluate the applicability of TCL to real data, we applied it on magnetoencephalography (MEG), i.e. measurements of the electrical activity in the human brain. In particular, we used data measured in a resting-state session, during which the subjects did not have any task nor were receiving any particular stimulation. In recent years, many studies have shown the existence of networks of brain activity in resting state, with MEG as well [2, 4]. Such networks mean that the data is nonstationary, and thus this data provides an excellent target for TCL. 6 a) Number of segments 8 16 32 64 128 256 512 Accuracy (%) 1 2 4 8 10 20 40 80 100 L=1 L=2 L=3 L=4 L=5 L=1(chance) L=2(chance) L=3(chance) L=4(chance) L=5(chance) b) Number of segments 8 16 32 64 128 256 512 Mean correlation 0 0.2 0.4 0.6 0.8 1 TCL(L=1) TCL(L=2) TCL(L=3) TCL(L=4) TCL(L=5) NSVICA(L=1) NSVICA(L=2) NSVICA(L=3) NSVICA(L=4) NSVICA(L=5) kTDSEP(L=1) kTDSEP(L=2) kTDSEP(L=3) kTDSEP(L=4) kTDSEP(L=5) DAE(L=1) DAE(L=2) DAE(L=3) Figure 2: Simulation on artificial data. a) Mean classification accuracies of the MLR in TCL, as a function of the numbers of layers and segments. (Accuracies are on training data since it is not obvious how to define test data.) Note that chance levels (dotted lines) change as a function of the number of segments (see text). The MLR achieved higher accuracy than chance level. b) Mean absolute correlation coefficients between the true q(s) and the features learned by TCL (solid line) and, for comparison: nonstationarity-based linear ICA (NSVICA, dashed line), kernel-based nonlinear ICA (kTDSEP, dotted line), and denoising autoencoder (DAE, dash-dot line). TCL has much higher correlations than DAE or kTDSEP, and in the nonlinear case (L > 1), higher than NSVICA. Data and preprocessing We used MEG data from an earlier neuroimaging study [25], graciously provided by P. Ramkumar. MEG signals were measured from nine healthy volunteers by a Vectorview helmet-shaped neuromagnetometer at a sampling rate of 600 Hz with 306 channels. The experiment consisted of two kinds of sessions, i.e., resting sessions (2 sessions of 10 min) and task sessions (2 sessions of 12 min). In the task sessions, the subjects were exposed to a sequence of 6–33 s blocks of auditory, visual and tactile stimuli, which were interleaved with 15 s rest periods. We exclusively used the resting-session data for the training of the network, and task-session data was only used in the evaluation. The modality of the sensory stimulation (incl. no stimulation, i.e. rest) provided a class label that we used in the evaluation, giving in total four classes. We preprocessed the MEG signals by Morlet filtering around the alpha frequency band. TCL settings We used segments of equal size, of length 12.5 s or 625 data points (downsampling to 50 Hz); the length was based on prior knowledge about the time-scale of resting-state networks. The number of layers took the values L ∈{1, 2, 3, 4}, and the number of nodes of each hidden layer was a function of L so that we always fixed the number of output layer nodes to 10, and increased gradually the number of nodes when going to earlier layer as L = 1 : 10, L = 2 : 20 −10, L = 3 : 40 −20 −10, and L = 4 : 80 −40 −20 −10. We used ReLU’s in the middle layers, and adaptive units φ(x) = max(x, ax) exclusively for the output layer, which is more flexible than the “absolute value” unit used in the Simulation above. To prevent overfitting, we applied dropout [28] to inputs, and batch normalization [19] to hidden layers. Since different subjects and sessions are likely to have uninteresting technical differences, we used a multi-task learning scheme, with a separate top-layer MLR classifier for each measurement session and subject, but a shared feature-MLP. (In fact, if we use the MLR to discriminate all segments of all sessions, it tends to mainly learn such inter-subject and inter-session differences.) Otherwise, all the settings were as in Section 6. Evaluation methods To evaluate the obtained features, we performed classification of the sensory stimulation categories (modalities) by applying feature extractors trained with (unlabeled) restingsession data to (labeled) task-session data. Classification was performed using a linear support vector machine (SVM) classifier trained on the stimulation modality labels, and its performance was evaluated by a session-average of session-wise one-block-out cross-validation (CV) accuracies. The hyperparameters of the SVM were determined by nested CV without using the test data. The average activities of the feature extractor during each block were used as feature vectors in the evaluation of TCL features. However, we used log-power activities for the other (baseline) methods because the average activities had much lower performance with those methods. We balanced the number of blocks between the four categories. We measured the CV accuracy 10 times by changing the initial values of the feature extractor training, and showed their average performance. We also visualized the spatial activity patterns obtained by TCL, using weighted-averaged sensor signals; i.e., the sensor signals are averaged while weighted by the activities of the feature extractor. 7 a) TCL DAE NSVICA kTDSEP Classification accuracy (%) 30 40 50 L=1 L=4 L=1 L=4 b) L3 L2 L1 Figure 3: Real MEG data. a) Classification accuracies of linear SVMs newly trained with tasksession data to predict stimulation labels in task-sessions, with feature extractors trained in advance with resting-session data. Error bars give standard errors of the mean across ten repetitions. For TCL and DAE, accuracies are given for different numbers of layers L. Horizontal line shows the chance level (25%). b) Example of spatial patterns of nonstationary components learned by TCL. Each small panel corresponds to one spatial pattern with the measurement helmet seen from three different angles (left, back, right); red/yellow is positive and blue is negative. L3: approximate total spatial pattern of one selected third-layer unit. L2: the patterns of the three second-layer units maximally contributing to this L3 unit. L1: for each L2 unit, the two most strongly contributing first-layer units. Results Figure 3a) shows the comparison of classification accuracies between the different methods, for different numbers of layers L = {1, 2, 3, 4}. The classification accuracies by the TCL method were consistently higher than those by the other (baseline) methods.2 We can also see a superior performance of multi-layer networks (L ≥3) compared with that of the linear case (L = 1), which indicates the importance of nonlinear demixing in the TCL method. Figure 3b) shows an example of spatial patterns learned by the TCL method. For simplicity of visualization, we plotted spatial patterns for the three-layer model. We manually picked one out of the ten hidden nodes from the third layer, and plotted its weighted-averaged sensor signals (Figure 3b, L3). We also visualized the most strongly contributing second- and first-layer nodes. We see progressive pooling of L1 units to form left temporal, right temporal, and occipito-parietal patterns in L2, which are then all pooled together in the L3 resulting in a bilateral temporal pattern with negative contribution from the occipito-parietal region. Most of the spatial patterns in the third layer (not shown) are actually similar to those previously reported using functional magnetic resonance imaging (fMRI), and MEG [2, 4]. Interestingly, none of the hidden units seems to represent artefacts (i.e. non-brain signals), in contrast to ordinary linear ICA of EEG or MEG. 8 Conclusion We proposed a new learning principle for unsupervised feature (representation) learning. It is based on analyzing nonstationarity in temporal data by discriminating between time segments. The ensuing “time-contrastive learning” is easy to implement since it only uses ordinary neural network training: a multi-layer perceptron with logistic regression. However, we showed that, surprisingly, it can estimate independent components in a nonlinear mixing model up to certain indeterminacies, assuming that the independent components are nonstationary in a suitable way. The indeterminacies include a linear mixing (which can be resolved by a further linear ICA step), and component-wise nonlinearities, such as squares or absolute values. TCL also avoids the computation of the gradient of the Jacobian, which is a major problem with maximum likelihood estimation [5]. Our developments also give by far the strongest identifiability proof of nonlinear ICA in the literature. The indeterminacies actually reduce to just inevitable monotonic component-wise transformations in the case of modulated Gaussian sources. Thus, our results pave the way for further developments in nonlinear ICA, which has so far seriously suffered from the lack of almost any identifiability theory, and provide a new principled approach to unsupervised deep learning. Experiments on real MEG found neuroscientifically interesting networks. Other promising future application domains include video data, econometric data, and biomedical data such as EMG and ECG, in which nonstationary variances seem to play a major role.3 2Note that classification using the final linear ICA is equivalent to using whitening since ICA only makes a further orthogonal rotation. 3This research was supported in part by JSPS KAKENHI 16J08502 and the Academy of Finland. 8 References [1] L. B. Almeida. MISEP—linear and nonlinear ICA based on mutual information. J. of Machine Learning Research, 4:1297–1318, 2003. [2] M. J. Brookes et al. Investigating the electrophysiological basis of resting state networks using magnetoencephalography. Proc. Natl. Acad. Sci., 108(40):16783–16788, 2011. [3] P. Comon. Independent component analysis—a new concept? Signal Processing, 36:287–314, 1994. [4] F. de Pasquale et al. A cortical core for dynamic integration of functional networks in the resting human brain. Neuron, 74(4):753–764, 2012. [5] L. Dinh, D. Krueger, and Y. Bengio. NICE: Non-linear independent components estimation. arXiv:1410.8516 [cs.LG], 2015. [6] P. Földiák. Learning invariance from transformation sequences. Neural Computation, 3:194–200, 1991. [7] X. Glorot and Y. Bengio. Understanding the difficulty of training deep feedforward neural networks. In AISTATS’10, 2010. [8] I. Goodfellow, J. Pouget-Abadie, M. Mirza, B. Xu, D. Warde-Farley, S. Ozair, A. Courville, and Y. Bengio. Generative adversarial nets. In NIPS, pages 2672–2680, 2014. [9] R. Goroshin, J. Bruna, J. Tompson, D. Eigen, and Y. LeCun. Unsupervised feature learning from temporal data. arXiv:1504.02518, 2015. [10] M. U. Gutmann, R. Dutta, S. Kaski, and J. Corander. Likelihood-free inference via classification. arXiv:1407.4981 [stat.CO], 2014. [11] M. U. Gutmann and A. Hyvärinen. Noise-contrastive estimation of unnormalized statistical models, with applications to natural image statistics. J. of Machine Learning Research, 13:307–361, 2012. [12] S. Harmeling, A. Ziehe, M. Kawanabe, and K.-R. Müller. Kernel-based nonlinear blind source separation. Neural Comput., 15(5):1089–1124, 2003. [13] G. E. Hinton. Learning multiple layers of representation. Trends Cogn. Sci., 11:428–434, 2007. [14] G. E. Hinton and R. S. Zemel. Autoencoders, minimum description length, and helmholtz free energy. Adv. Neural Inf. Process. Syst., 1994. [15] A. Hyvärinen. Fast and robust fixed-point algorithms for independent component analysis. IEEE Trans. Neural Netw., 10(3):626–634, 1999. [16] A. Hyvärinen. Blind source separation by nonstationarity of variance: A cumulant-based approach. IEEE Transactions on Neural Networks, 12(6):1471–1474, 2001. [17] A. Hyvärinen, J. Hurri, and P. O. Hoyer. Natural Image Statistics. Springer-Verlag, 2009. [18] A. Hyvärinen and P. Pajunen. Nonlinear independent component analysis: Existence and uniqueness results. Neural Netw., 12(3):429–439, 1999. [19] S. Ioffe and C. Szegedy. Batch normalization: Accelerating deep network training by reducing internal covariate shift. CoRR, abs/1502.03167, 2015. [20] C. Jutten, M. Babaie-Zadeh, and J. Karhunen. Nonlinear mixtures. Handbook of Blind Source Separation, Independent Component Analysis and Applications, pages 549–592, 2010. [21] D. P. Kingma and M. Welling. Auto-encoding variational bayes. arXiv:1312.6114 [stat.ML], 2014. [22] K. Matsuoka, M. Ohya, and M. Kawamoto. A neural net for blind separation of nonstationary signals. Neural Netw., 8(3):411–419, 1995. [23] H. Mobahi, R. Collobert, and J. Weston. Deep learning from temporal coherence in video. In Proceedings of the 26th Annual International Conference on Machine Learning, pages 737–744, 2009. [24] D.-T. Pham and J.-F. Cardoso. Blind separation of instantaneous mixtures of non stationary sources. IEEE Trans. Signal Processing, 49(9):1837–1848, 2001. [25] P. Ramkumar, L. Parkkonen, R. Hari, and A. Hyvärinen. Characterization of neuromagnetic brain rhythms over time scales of minutes using spatial independent component analysis. Hum. Brain Mapp., 33(7):1648– 1662, 2012. [26] H. Sprekeler, T. Zito, and L. Wiskott. An extension of slow feature analysis for nonlinear blind source separation. J. of Machine Learning Research, 15(1):921–947, 2014. [27] J. T. Springenberg and M. Riedmiller. Learning temporal coherent features through life-time sparsity. In Neural Information Processing, pages 347–356. Springer, 2012. [28] N. Srivastava, G. Hinton, A. Krizhevsky, I. Sutskever, and R. Salakhutdinov. Dropout: A simple way to prevent neural networks from overfitting. J. Mach. Learn. Res., 15(1):1929–1958, 2014. [29] Y. Tan, J. Wang, and J.M. Zurada. Nonlinear blind source separation using a radial basis function network. IEEE Transactions on Neural Networks, 12(1):124–134, 2001. [30] H. Valpola. From neural PCA to deep unsupervised learning. In Advances in Independent Component Analysis and Learning Machines, pages 143–171. Academic Press, 2015. [31] P. Vincent, H. Larochelle, I. Lajoie, Y. Bengio, and P.-A. Manzagol. Stacked denoising autoencoders: Learning useful representations in a deep network with a local denoising criterion. J. Mach. Learn. Res., 11:3371–3408, 2010. [32] L. Wiskott and T. J. Sejnowski. Slow feature analysis: Unsupervised learning of invariances. Neural Comput., 14(4):715–770, 2002. 9 | 2016 | 475 |
6,411 | Leveraging Sparsity for Efficient Submodular Data Summarization Erik M. Lindgren, Shanshan Wu, Alexandros G. Dimakis The University of Texas at Austin Department of Electrical and Computer Engineering erikml@utexas.edu, shanshan@utexas.edu, dimakis@austin.utexas.edu Abstract The facility location problem is widely used for summarizing large datasets and has additional applications in sensor placement, image retrieval, and clustering. One difficulty of this problem is that submodular optimization algorithms require the calculation of pairwise benefits for all items in the dataset. This is infeasible for large problems, so recent work proposed to only calculate nearest neighbor benefits. One limitation is that several strong assumptions were invoked to obtain provable approximation guarantees. In this paper we establish that these extra assumptions are not necessary—solving the sparsified problem will be almost optimal under the standard assumptions of the problem. We then analyze a different method of sparsification that is a better model for methods such as Locality Sensitive Hashing to accelerate the nearest neighbor computations and extend the use of the problem to a broader family of similarities. We validate our approach by demonstrating that it rapidly generates interpretable summaries. 1 Introduction In this paper we study the facility location problem: we are given sets V of size n, I of size m and a benefit matrix of nonnegative numbers C 2 RI⇥V , where Civ describes the benefit that element i receives from element v. Our goal is to select a small set A of k columns in this matrix. Once we have chosen A, element i will get a benefit equal to the best choice out of the available columns, maxv2A Civ. The total reward is the sum of the row rewards, so the optimal choice of columns is the solution of: arg max {A✓V :|A|k} X i2I max v2A Civ. (1) A natural application of this problem is in finding a small set of representative images in a big dataset, where Civ represents the similarity between images i and v. The problem is to select k images that provide a good coverage of the full dataset, since each one has a close representative in the chosen set. Throughout this paper we follow the nomenclature common to the submodular optimization for machine learning literature. This problem is also known as the maximization version of the k-medians problem or the submodular facility location problem. A number of recent works have used this problem for selecting subsets of documents or images from a larger corpus [27, 39], to identify locations to monitor in order to quickly identify important events in sensor or blog networks [24, 26], as well as clustering applications [23, 34]. We can naturally interpret Problem 1 as a maximization of a set function F(A) which takes as an input the selected set of columns and returns the total reward of that set. Formally, let F(;) = 0 and 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. for all other sets A ✓V define F(A) = X i2I max v2A Civ. (2) The set function F is submodular, since for all j 2 V and sets A ✓B ✓V \ {j}, we have F(A [ {j}) −F(A) ≥F(B [ {j}) −F(B), that is, the gain of an element is diminishes as we add elements. Since the entries of C are nonnegative, F is monotone, since for all A ✓B ✓V , we have F(A) F(B). We also have F normalized, since F(;) = 0. The facility location problem is NP-Hard, so we consider approximation algorithms. Like all monotone and normalized submodular functions, the greedy algorithm guarantees a (1 −1/e)-factor approximation to the optimal solution [35]. The greedy algorithm starts with the empty set, then for k iterations adds the element with the largest reward. This approximation is the best possible—the maximum coverage problem is an instance of the submodular facility location problem, which was shown to be NP-Hard to optimize within a factor of 1 −1/e + " for all " > 0 [13]. The problem is that the greedy algorithm has super-quadratic running time ⇥(nmk) and in many datasets n and m can be in the millions. For this reason, several recent papers have focused on accelerating the greedy algorithm. In [26], the authors point out that if the benefit matrix is sparse, this can dramatically speed up the computation time. Unfortunately, in many problems of interest, data similarities or rewards are not sparse. Wei et al. [40] proposed to first sparsify the benefit matrix and then run the greedy algorithm on this new sparse matrix. In particular, [40] considers t-nearest neighbor sparsification, i.e., keeping for each row the t largest entries and zeroing out the rest. Using this technique they demonstrated an impressive 80-fold speedup over the greedy algorithm with little loss in solution quality. One limitation of their theoretical analysis was the limited setting under which provable approximation guarantees were established. Our Contributions: Inspired by the work of Wei et al. [40] we improve the theoretical analysis of the approximation error induced by sparsification. Specifically, the previous analysis assumes that the input came from a probability distribution where the preferences of each element of i 2 I are independently chosen uniformly at random. For this distribution, when k = ⌦(n), they establish that the sparsity can be taken to be O(log n) and running the greedy algorithm on the sparsified problem will guarantee a constant factor approximation with high probability. We improve the analysis in the following ways: • We prove guarantees for all values of k and our guarantees do not require any assumptions on the input besides nonnegativity of the benefit matrix. • In the case where k = ⌦(n), we show that it is possible to take the sparsity of each row as low as O(1) while guaranteeing a constant factor approximation. • Unlike previous work, our analysis does not require the use of any particular algorithm and can be integrated to many algorithms for solving facility location problems. • We establish a lower bound which shows that our approximation guarantees are tight up to log factors, for all desired approximation factors. In addition to the above results we propose a novel algorithm that uses a threshold based sparsification where we keep matrix elements that are above a set value threshold. This type of sparsification is easier to efficiently implement using nearest neighbor methods. For this method of sparsification, we obtain worst case guarantees and a lower bound that matches up to constant factors. We also obtain a data dependent guarantee which helps explain why our algorithm empirically performs better than the worst case. Further, we propose the use of Locality Sensitive Hashing (LSH) and random walk methods to accelerate approximate nearest neighbor computations. Specifically, we use two types of similarity metrics: inner products and personalized PageRank (PPR). We propose the use of fast approximations for these metrics and empirically show that they dramatically improve running times. LSH functions are well-known but, to the best of our knowledge, this is the first time they have been used to accelerate facility location problems. Furthermore, we utilize personalized PageRank as the similarity between vertices on a graph. Random walks can quickly approximate this similarity and we demonstrate that it yields highly interpretable results for real datasets. 2 2 Related Work The use of a sparsified proxy function was shown by Wei et al. to also be useful for finding a subset for training nearest neighbor classifiers [41]. Further, they also show a connection of nearest neighbor classifiers to the facility location function. The facility location function was also used by Mirzasoleiman et al. as part of a summarization objective function in [32], where they present a summarization algorithm that is able to handle a variety of constraints. The stochastic greedy algorithm was shown to get a 1 −1/e −" approximation with runtime O(nm log 1 "), which has no dependance on k [33]. It works by choosing a sample set from V of size n k log 1 " each iteration and adding to the current set the element of the sample set with the largest gain. Also, there are several related algorithms for the streaming setting [5] and distributed setting [6, 25, 31, 34]. Since the objective function is defined over the entire dataset, optimizing the submodular facility location function becomes more complicated in these memory limited settings. Often the function is estimated by considering a randomly chosen subset from the set I. 2.1 Benefits Functions and Nearest Neighbor Methods For many problems, the elements V and I are vectors in some feature space where the benefit matrix is defined by some similarity function sim. For example, in Rd we may use the RBF kernel sim(x, y) = e−γkx−yk2 2, dot product sim(x, y) = xT y, or cosine similarity sim(x, y) = xT y kxkkyk. There has been decades of research on nearest neighbor search in geometric spaces. If the vectors are low dimensional, then classical techniques such as kd-trees [7] work well and are exact. However it has been observed that as the dimensions grow that the runtime of all known exact methods does little better than a linear scan over the dataset. As a compromise, researchers have started to work on approximate nearest neighbor methods, one of the most successful approaches being locality sensitive hashing [15, 20]. LSH uses a hash function that hashes together items that are close. Locality sensitive hash functions exist for a variety of metrics and similarities such as Euclidean [11], cosine similarity [3, 9], and dot product [36, 38]. Nearest neighbor methods other than LSH that have been shown to work for machine learning problems include [8, 10]. Additionally, see [14] for efficient and exact GPU methods. An alternative to vector functions is to use similarities and benefits defined from graph structures. For instance, we can use the personalized PageRank of vertices in a graph to define the benefit matrix [37]. The personalized PageRank is similar to the classic PageRank, except the random jumps, rather than going to anywhere in the graph, go back to the users “home” vertex. This can be used as a value of “reputation” or “influence” between vertices in a graph [17]. There are a variety of algorithms for finding the vertices with a large PageRank personalized to some vertex. One popular one is the random walk method. If ⇡i is the personalized PageRank vector to some vertex i, then ⇡i(v) is the same as the probability that a random walk of geometric length starting from i ends on a vertex v (where the parameter of the geometric distribution is defined by the probability of jumping back to i) [4]. Using this approach, we can quickly estimate all elements in the benefit matrix greater than some value ⌧. 3 Guarantees for t-Nearest Neighbor Sparsification We associate a bipartite support graph G = (V, I, E) by having an edge between v 2 V and i 2 I whenever Cij > 0. If the support graph is sparse, we can use the graph to calculate the gain of an element much more efficiently, since we only need to consider the neighbors of the element versus the entire set I. If the average degree of a vertex i 2 I is t, (and we use a cache for the current best value of an element i) then we can execute greedy in time O(mtk). See Algorithm 1 in the Appendix for pseudocode. If the sparsity t is much smaller than the size of V , the runtime is greatly improved. However, the instance we wish to optimize may not be sparse. One idea is to sparsify the original matrix by only keeping the values in the benefit matrix C that are t-nearest neighbors, which was considered in [40]. That is, for every element i in I, we only keep the top t elements of Ci1, Ci2, . . . , Cin and set the rest equal to zero. This leads to a matrix with mt nonzero elements. We 3 then want the solution from optimizing the sparse problem to be close to the value of the optimal solution in the original objective function F. Our main theorem is that we can set the sparsity parameter t to be O( n ↵k log m ↵k)—which is a significant improvement for large enough k—while still having the solution to the sparsified problem be at most a factor of 1 1+↵from the value of the optimal solution. Theorem 1. Let Ot be the optimal solution to an instance of the submodular facility location problem with a benefit matrix that was sparsified with t-nearest neighbor. For any t ≥t⇤(↵) = O( n ↵k log n ↵k), we have F(Ot) ≥ 1 1+↵OPT. Proof Sketch. For the value of t chosen, there exists a set Γ of size ↵k such that every element of I has a neighbor in the t-nearest neighbor graph; this is proven using the probabilistic method. By appending Γ to the optimal solution and using the monotonicity of F, we can move to the sparsified function, since no element of I would prefer an element that was zeroed out in the sparsified matrix as one of their top t most beneficial elements is present in the set Γ. The optimal solution appended with Γ is a set of size (1 + ↵)k. We then bound the amount that the optimal value of a submodular function can increase by when adding ↵k elements. See the appendix for the complete proof. Note that Theorem 1 is agnostic to the algorithm used to optimize the sparsified function, and so if we use a ⇢-approximation algorithm, then we are at most a factor of ⇢ 1+↵from the optimal solution. Later this section we will utilize this to design a subquadratic algorithm for optimizing facility location problems as long as we can quickly compute t-nearest neighbors and k is large enough. If m = O(n) and k = ⌦(n), we can achieve a constant factor approximation even when taking the sparsity parameter as low as t = O(1), which means that the benefit matrix C has only O(n) nonzero entries. Also note that the only assumption we need is that the benefits between elements are nonnegative. When k = ⌦(n), previous work was only able to take t = O(log n) and required the benefit matrix to come from a probability distribution [40]. Our guarantee has two regimes depending on the value of ↵. If we want the optimal solution to the sparsified function to be a 1 −" factor from the optimal solution to the original function, we have that t⇤(") = O( n "k log m "k) suffices. Conversely, if we want to take the sparsity t to be much smaller than n k log m k , then this is equivalent to taking ↵very large and we have some guarantee of optimality. In the proof of Theorem 1, the only time we utilize the value of t is to show that there exists a small set Γ that covers the entire set I in the t-nearest neighbor graph. Real datasets often contain a covering set of size ↵k for t much smaller than O( n ↵k log m ↵k). This observation yields the following corollary. Corollary 2. If after sparsifying a problem instance there exists a covering set of size ↵k in the t-nearest neighbor graph, then the optimal solution Ot of the sparsified problem satisfies F(Ot) ≥ 1 1+↵OPT. In the datasets we consider in our experiments of roughly 7000 items, we have covering sets with only 25 elements for t = 75, and a covering set of size 10 for t = 150. The size of covering set was upper bounded by using the greedy set cover algorithm. In Figure 2 in the appendix, we see how the size of the covering set changes with the choice of the number of neighbors chosen t. It would be desirable to take the sparsity parameter t lower than the value dictated by t⇤(↵). As demonstrated by the following lower bound, is not possible to take the sparsity significantly lower than 1 ↵ n k and still have a 1 1+↵approximation in the worst case. Proposition 3. Suppose we take t = max ⇢1 2↵, 1 1 + ↵ " n −1 k . There exists a family of inputs such that we have F(Ot) 1 1+↵−2/kOPT. The example we create to show this has the property that in the t-nearest neighbor graph, the set Γ needs ↵k elements to cover every element of I. We plant a much smaller covering set that is very close in value to Γ but is hidden after sparsification. We then embed a modular function within the facility location objective. With knowledge of the small covering set, an optimal solver can take 4 advantage of this modular function, while the sparsified solution would prefer to first choose the set Γ before considering the modular function. See the appendix for full details. Sparsification integrates well with the stochastic greedy algorithm [33]. By taking t ≥t⇤("/2) and running stochastic greedy with sample sets of size n k ln 2 ", we get a 1 −1/e −" approximation in expectation that runs in expected time O( nm "k log 1 " log m "k). If we can quickly sparsify the problem and k is large enough, for example n1/3, this is subquadratic. The following proposition shows a high probability guarantee on the runtime of this algorithm and is proven in the appendix. Proposition 4. When m = O(n), the stochastic greedy algorithm [33] with set sizes of size n k log 2 ", combined with sparsification with sparsity parameter t, will terminate in time O(n log 1 " max{t, log n}) with high probability. When t ≥t⇤("/2) = O( n "k log m "k), this algorithm has a 1 −1/e −" approximation in expectation. 4 Guarantees for threshold-based Sparsification Rather than t-nearest neighbor sparsification, we now consider using ⌧-threshold sparsification, where we zero-out all entries that have value below a threshold ⌧. Recall the definition of a locality sensitive hash. Definition. H is a (⌧, K⌧, p, q)-locality sensitive hash family if for x, y satisfying sim(x, y) ≥⌧we have Ph2H(h(x) = h(y)) ≥p and if x, y satisfy sim(x, y) K⌧we have Ph2H(h(x) = h(y)) q. We see that ⌧-threshold sparsification is a better model than t-nearest neighbors for LSH, as for K = 1 it is a noisy ⌧-sparsification and for non-adversarial datasets it is a reasonable approximation of a ⌧-sparsification method. Note that due to the approximation constant K, we do not have an a priori guarantee on the runtime of arbitrary datasets. However we would expect in practice that we would only see a few elements with threshold above the value ⌧. See [2] for a discussion on this. One issue is that we do not know how to choose the threshold ⌧. We can sample elements of the benefit matrix C to estimate how sparse the threshold graph will be for a given threshold ⌧. Assuming the values of C are in general position1, by using the Dvoretzky-Kiefer-Wolfowitz-Massart Inequality [12, 28] we can bound the number of samples needed to choose a threshold that achieves a desired sparsification level. We establish the following data-dependent bound on the difference in the optimal solutions of the ⌧-threshold sparsified function and the original function. We denote the set of vertices adjacent to S in the ⌧-threshold graph with N(S). Theorem 5. Let O⌧be the optimal solution to an instance of the facility location problem with a benefit matrix that was sparsified using a ⌧-threshold. Assume there exists a set S of size k such that in the ⌧-threshold graph we have the neighborhood of S satisfying |N(S)| ≥µn. Then we have F(O⌧) ≥ ✓ 1 + 1 µ ◆−1 OPT. For the datasets we consider, we see that we can keep a 0.01 −0.001 fraction of the elements of C while still having a small set S with a neighborhood N(S) that satisfied |N(S)| ≥0.3n. In Figure 3 in the appendix, we plot the relationship between the number of edges in the ⌧-threshold graph and the number of coverable element by a a set of small size, as estimated by the greedy algorithm for max-cover. Additionally, we have worst case dependency on the number of edges in the ⌧-threshold graph and the approximation factor. The guarantees follow from applying Theorem 5 with the following Lemma. Lemma 6. For k ≥ c 1−2c2 1 δ, any graph with 1 2δ2n2 edges has a set S of size k such that the neighborhood N(S) satisfies |N(S)| ≥cδn. 1By this we mean that the values of C are all unique, or at least only a few elements take any particular value. We need this to hold since otherwise a threshold based sparsification may exclusively return an empty graph or the complete graph. 5 To get a matching lower bound, consider the case where the graph has two disjoint cliques, one of size δn and one of size (1 −δ)n. Details are in the appendix. 5 Experiments 5.1 Summarizing Movies and Music from Ratings Data We consider the problem of summarizing a large collection of movies. We first need to create a feature vector for each movie. Movies can be categorized by the people who like them, and so we create our feature vectors from the MovieLens ratings data [16]. The MovieLens database has 20 million ratings for 27,000 movies from 138,000 users. To do this, we perform low-rank matrix completion and factorization on the ratings matrix [21, 22] to get a matrix X = UV T , where X is the completed ratings matrix, U is a matrix of feature vectors for each user and V is a matrix of feature vectors for each movie. For movies i and j with vectors vi and vj, we set the benefit function Cij = vT i vj. We do not use the normalized dot product (cosine similarity) because we want our summary movies to be movies that were highly rated, and not normalizing makes highly rated movies increase the objective function more. We complete the ratings matrix using the MLlib library in Apache Spark [29] after removing all but the top seven thousand most rated movies to remove noise from the data. We use locality sensitive hashing to perform sparsification; in particular we use the LSH in the FALCONN library for cosine similarity [3] and the reduction from a cosine simiarlity hash to a dot product hash [36]. As a baseline we consider sparsification using a scan over the entire dataset, the stochastic greedy algorithm with lazy evaluations[33], and the greedy algorithm with lazy evaluations [30]. The number of elements chosen was set to 40 and for the LSH method and stochastic greedy we average over five trials. We then do a scan over the sparsity parameter t for the sparsification methods and a scan over the number of samples drawn each iteration for the stochastic greedy algorithm. The sparsified methods use the (non-stochastic) lazy greedy algorithm as the base optimization algorithm, which we found worked best for this particular problem2. In Figure 1(a) we see that the LSH method very quickly approaches the greedy solution—it is almost identical in value just after a few seconds even though the value of t is much less than t⇤("). The stochastic greedy method requires much more time to get the same function value. Lazy greedy is not plotted, since it took over 500 seconds to finish. 0 25 50 75 100 125 150 0.90 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 Runtime (s) (a) Fraction of Greedy Set Value vs. Runtime Exact top-t LSH top-t Stochastic Greedy 0 25 50 75 100 125 150 0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 Runtime (s) (b) Fraction of Greedy Set Contained vs. Runtime Figure 1: Results for the MovieLens dataset [16]. Figure (a) shows the function value as the runtime increases, normalized by the value the greedy algorithm obtained. As can be seen our algorithm is within 99.9% of greedy in less than 5 seconds. For this experiment, the greedy algorithm had a runtime of 512 seconds, so this is a 100x speed up for a small penalty in performance. We also compare to the stochastic greedy algorithm [33], which needs 125 seconds to get equivalent performance, which is 25x slower. Figure (b) shows the fraction of the set that was returned by each method that was common with the set returned by greedy. We see that the approximate nearest neighbor method has 90% of its elements common with the greedy set while being 50x faster than greedy, and using exact nearest neighbors can perfectly match the greedy set while being 4x faster than greedy. 2When experimenting on very larger datasets, we found that runtime constraints can make it necessary to use stochastic greedy as the base optimization algorithm 6 Table 1: A subset of the summarization outputted by our algorithm on the MovieLens dataset, plus the elements who are represented by each representative with the largest dot product. Each group has a natural interpretation: 90’s slapstick comedies, 80’s horror, cult classics, etc. Note that this was obtained with only a similarity matrix obtained from ratings. Happy Gilmore Nightmare on Elm Street Star Wars IV Shawshank Redemption Tommy Boy Friday the 13th Star Wars V Schindler’s List Billy Madison Halloween II Raiders of the Lost Ark The Usual Suspects Dumb & Dumber Nightmare on Elm Street 3 Star Wars VI Life Is Beautiful Ace Ventura Pet Detective Child’s Play Indiana Jones, Last Crusade Saving Private Ryan Road Trip Return of the Living Dead II Terminator 2 American History X American Pie 2 Friday the 13th 2 The Terminator The Dark Knight Black Sheep Puppet Master Star Trek II Good Will Hunting Pulp Fiction The Notebook Pride and Prejudice The Godfather Reservoir Dogs P.S. I Love You Anne of Green Gables The Godfather II American Beauty The Holiday Persuasion One Flew Over the Cuckoo’s Nest A Clockwork Orange Remember Me Emma Goodfellas Trainspotting A Walk to Remembe Mostly Martha Apocalypse Now Memento The Proposal Desk Set Chinatown Old Boy The Vow The Young Victoria 12 Angry Men No Country for Old Men Life as We Know It Mansfield Park Taxi Driver A performance metric that can be better than the objective value is the fraction of elements returned that are common with the greedy algorithm. We treat this as a proxy for the interpretability of the results. We believe this metric is reasonable since we found the subset returned by the greedy algorithm to be quite interpretable. We plot this metric against runtime in Figure 1b. We see that the LSH method quickly gets to 90% of the elements in the greedy set while stochastic greedy takes much longer to get to just 70% of the elements. The exact sparsification method is able to completely match the greedy solution at this point. One interesting feature is that the LSH method does not go much higher than 90%. This may be due to the increased inaccuracy when looking at elements with smaller dot products. We plot this metric against the number of exact and approximate nearest neighbors t in Figure 4 in the appendix. We include a subset of the summarization and for each representative a few elements who are represented by this representative with the largest dot product in Table 1 to show the interpretability of our results. 5.2 Finding Influential Actors and Actresses For our second experiment, we consider how to find a diverse subset of actors and actresses in a collaboration network. We have an edge between an actor or actress if they collaborated in a movie together, weighted by the number of collaborations. Data was obtained from [19] and an actor or actress was only included if he or she was one of the top six in the cast billing. As a measure of influence, we use personalized PageRank [37]. To quickly calculate the people with the largest influence relative to someone, we used the random walk method[4]. We first consider a small instance where we can see how well the sparsified approach works. We build a graph based on the cast in the top thousand most rated movies. This graph has roughly 6000 vertices and 60,000 edges. We then calculate the entire PPR matrix using the power method. Note that this is infeasible on larger graphs in terms of time and memory. Even on this moderate sized graph it took six hours and takes up two gigabytes of space. We then compare the value of the greedy algorithm using the entire PPR matrix with the sparsified algorithm using the matrix approximated by Monte Carlo sampling using the two metrics mentioned in the previous section. We omit exact nearest neighbor and stochastic greedy because it is not clear how it would work without having to compute the entire PPR matrix. Instead we compare to an approach where we choose a sample from I and calculate the PPR only on these elements using the power method. As mentioned in Section 2, several algorithms utilize random sampling from I. We take k to be 50 for this instance. In Figure 5 in the appendix we see that sparsification performs drastically better in both function value and percent of the greedy set contained for a given runtime. 7 We now scale up to a larger graph by taking the actors and actresses billed in the top six for the twenty thousand most rated movies. This graph has 57,000 vertices and 400,000 edges. We would not be able to compute the entire PPR matrix for this graph in a reasonable amount of time and even if we could it would be a challenge to store the entire matrix in memory. However we can run the sparsified algorithm in three hours using only 2 GB of memory, which could be improved further by parallelizing the Monte Carlo approximation. We run the greedy algorithm separately on the actors and actresses. For each we take the top twentyfive and compare to the actors and actresses with the largest (non-personalized) PageRank. In Figure 2 of the appendix, we see that the PageRank output fails to capture the diversity in nationality of the dataset, while the submodular facility location optimization returns actors and actresses from many of the worlds film industries. Acknowledgements This material is based upon work supported by the National Science Foundation Graduate Research Fellowship under Grant No. DGE-1110007 as well as NSF Grants CCF 1344179, 1344364, 1407278, 1422549 and ARO YIP W911NF-14-1-0258. References [1] N. Alon and J. H. Spencer. The Probabilistic Method. Wiley, 3rd edition, 2008. [2] A. Andoni. Exact algorithms from approximation algorithms? (part 2). Windows on Theory, 2012. https://windowsontheory.org/2012/04/17/ exact-algorithms-from-approximation-algorithms-part-2/ (version: 2016-09-06). [3] A. Andoni, P. Indyk, T. Laarhoven, I. Razenshteyn, and L. Schmidt. Practical and optimal LSH for angular distance. In NIPS, 2015. [4] K. Avrachenkov, N. Litvak, D. Nemirovsky, and N. Osipova. Monte Carlo methods in PageRank computation: When one iteration is sufficient. SIAM Journal on Numerical Analysis, 2007. [5] A. Badanidiyuru, B. Mirzasoleiman, A. Karbasi, and A. Krause. Streaming submodular maximization: Massive data summarization on the fly. In KDD, 2014. [6] R. Barbosa, A. Ene, H. L. Nguyen, and J. Ward. The power of randomization: Distributed submodular maximization on massive datasets. In ICML, 2015. [7] J. L. Bentley. Multidimensional binary search trees used for associative searching. Communications of the ACM, 1975. [8] A. Beygelzimer, S. Kakade, and J. Langford. Cover trees for nearest neighbor. In ICML, 2006. [9] M. S. Charikar. Similarity estimation techniques from rounding algorithms. In STOC, 2002. [10] J. Chen, H.-R Fang, and Y. Saad. Fast approximate k–NN graph construction for high dimensional data via recursive Lanczos bisection. JMLR, 2009. [11] M. Datar, N. Immorlica, P. Indyk, and V. S. Mirrokni. Locality-sensitive hashing scheme based on p-stable distributions. In Symposium on Computational Geometry, 2004. [12] A. Dvoretzky, J. Kiefer, and J. Wolfowitz. Asymptotic minimax character of the sample distribution function and of the classical multinomial estimator. The Annals of Mathematical Statistics, pages 642–669, 1956. [13] U. Feige. A threshold of ln n for approximating set cover. Journal of the ACM, 1998. [14] V. Garcia, E. Debreuve, F. Nielsen, and M. Barlaud. K-nearest neighbor search: Fast GPU-based implementations and application to high-dimensional feature matching. In International Conference on Image Processing, 2010. [15] A. Gionis, P. Indyk, and R. Motwani. Similarity search in high dimensions via hashing. In VLDB, 1999. [16] GroupLens. MovieLens 20M dataset, 2015. http://grouplens.org/datasets/movielens/20m/. 8 [17] P. Gupta, A. Goel, J. Lin, A. Sharma, D. Wang, and R. Zadeh. Wtf: The who to follow service at twitter. In WWW, 2013. [18] W. Hoeffding. Probability inequalities for sums of bounded random variables. Journal of the American Statistical Association, 1963. [19] IMDb. Alternative interfaces, 2016. http://www.imdb.com/interfaces. [20] P. Indyk and R. Motwani. Approximate nearest neighbors: towards removing the curse of dimensionality. In STOC, 1998. [21] P. Jain, P. Netrapalli, and S. Sanghavi. Low-rank matrix completion using alternating minimization. In STOC, 2013. [22] Y. Koren, R. Bell, and C. Volinsky. Matrix factorization techniques for recommender systems. Computer, 2009. [23] A. Krause and R. G. Gomes. Budgeted nonparametric learning from data streams. In ICML, 2010. [24] A. Krause, J. Leskovec, C. Guestrin, J. VanBriesen, and C. Faloutsos. Efficient sensor placement optimization for securing large water distribution networks. Journal of Water Resources Planning and Management, 2008. [25] R. Kumar, B. Moseley, S. Vassilvitskii, and A. Vattani. Fast greedy algorithms in MapReduce and streaming. ACM Transactions on Parallel Computing, 2015. [26] J. Leskovec, A. Krause, C. Guestrin, C. Faloutsos, J. VanBriesen, and N. Glance. Cost-effective outbreak detection in networks. In KDD, 2007. [27] H. Lin and J. A. Bilmes. Learning mixtures of submodular shells with application to document summarization. In UAI, 2012. [28] P. Massart. The tight constant in the Dvoretzky-Kiefer-Wolfowitz inequality. The Annals of Probability, pages 1269–1283, 1990. [29] X. Meng, J. Bradley, B. Yavuz, E. Sparks, S. Venkataraman, D. Liu, J. Freeman, D. B. Tsai, M. Amde, S. Owen, D. Xin, R. Xin, M. J. Franklin, R. Zadeh, M. Zaharia, and A. Talwalkar. MLlib: Machine learning in Apache Spark. JMLR, 2016. [30] M. Minoux. Accelerated greedy algorithms for maximizing submodular set functions. In Optimization Techniques. Springer, 1978. [31] V. Mirrokni and M. Zadimoghaddam. Randomized composable core-sets for distributed submodular maximization. STOC, 2015. [32] B. Mirzasoleiman, A. Badanidiyuru, and A. Karbasi. Fast constrained submodular maximization: Personalized data summarization. In ICML, 2016. [33] B. Mirzasoleiman, A. Badanidiyuru, A. Karbasi, J. Vondrak, and A. Krause. Lazier than lazy greedy. In AAAI, 2015. [34] B. Mirzasoleiman, A. Karbasi, R. Sarkar, and A. Krause. Distributed submodular maximization: Identifying representative elements in massive data. In NIPS, 2013. [35] G. L. Nemhauser, L. A. Wolsey, and M. L. Fisher. An analysis of approximations for maximizing submodular set functions—-I. Mathematical Programming, 1978. [36] B. Neyshabur and N. Srebro. On symmetric and asymmetric LSHs for inner product search. In ICML, 2015. [37] L. Page, S. Brin, R. Motwani, and T. Winograd. The PageRank citation ranking: Bringing order to the web. Stanford Digital Libraries, 1999. [38] A. Shrivastava and P. Li. Asymmetric LSH (ALSH) for sublinear time maximum inner product search (MIPS). In NIPS, 2014. [39] S. Tschiatschek, R. K. Iyer, H. Wei, and J. A. Bilmes. Learning mixtures of submodular functions for image collection summarization. In NIPS, 2014. [40] K. Wei, R. Iyer, and J. Bilmes. Fast multi-stage submodular maximization. In ICML, 2014. [41] K. Wei, R. Iyer, and J. Bilmes. Submodularity in data subset selection and active learning. In ICML, 2015. 9 | 2016 | 476 |
6,412 | Mistake Bounds for Binary Matrix Completion Mark Herbster University College London Department of Computer Science London WC1E 6BT, UK m.herbster@cs.ucl.ac.uk Stephen Pasteris University College London Department of Computer Science London WC1E 6BT, UK s.pasteris@cs.ucl.ac.uk Massimiliano Pontil Istituto Italiano di Tecnologia 16163 Genoa, Italy and University College London Department of Computer Science London WC1E 6BT, UK m.pontil@cs.ucl.ac.uk Abstract We study the problem of completing a binary matrix in an online learning setting. On each trial we predict a matrix entry and then receive the true entry. We propose a Matrix Exponentiated Gradient algorithm [1] to solve this problem. We provide a mistake bound for the algorithm, which scales with the margin complexity [2, 3] of the underlying matrix. The bound suggests an interpretation where each row of the matrix is a prediction task over a finite set of objects, the columns. Using this we show that the algorithm makes a number of mistakes which is comparable up to a logarithmic factor to the number of mistakes made by the Kernel Perceptron with an optimal kernel in hindsight. We discuss applications of the algorithm to predicting as well as the best biclustering and to the problem of predicting the labeling of a graph without knowing the graph in advance. 1 Introduction We consider the problem of predicting online the entries in an m ⇥n binary matrix U. We formulate this as the following game: nature queries an entry (i1, j1); the learner predicts ˆy1 2 {−1, 1} as the matrix entry; nature presents a label y1 = Ui1,j1; nature queries the entry (i2, j2); the learner predicts ˆy2; and so forth. The learner’s goal is to minimize the total number of mistakes M = |{t : ˆyt 6= yt}|. If nature is adversarial, the learner will always mispredict, but if nature is regular or simple, there is hope that a learner may make only a few mispredictions. In our setting we are motivated by the following interpretation of matrix completion. Each of the m rows represents a task (or binary classifier) and each of the n columns is associated with an object (or input). A task is the problem of predicting the binary label of each of the objects. For a single task, if we were given a kernel matrix between the objects in advance we could then use the Kernel Perceptron algorithm to sequentially label the objects and this algorithm would incur O(1/λ2) mistakes, where λ is the margin of the best linear classifier in the inner product space induced by the kernel. Unfortunately, in our setup, we do not know a good kernel in advance. However, we will show that a remarkable property of our algorithm is that it enjoys, up to logarithmic factors, a mistake bound of O(1/γ2) per task, where γ is the largest possible margin (over the choice of the kernel) which is achieved on all tasks. 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. The problem of predicting online the labels of a finite set of objects under the assumption that the similarity between objects can be described by a graph was introduced in [4], building upon earlier work in the batch setting [5, 6]. In this and later research the common assumption is that two objects are similar if there is an edge in the graph connecting them and the aim is to predict well when there are few edges between objects with disagreeing labels. Lower bounds and an optimal algorithm (up to logarithmic factors) for this problem were given in [7, 8]. The problem of predicting well when the graph is unknown was previously addressed in [9, 10]. That research took the approach that when receiving a vertex to predict, edges local to that vertex were then revealed. In this paper we take a different approach - the graph structure is never revealed to the learner. Instead, we have a number of tasks over the same unknown graph, and the hope is to perform comparably to the case in which the graph in known in advance. The general problem of matrix completion has been studied extensively in the batch statistical i.i.d. setting, see for example [11, 12, 13] and references therein. These studies are concerned either with Rademacher bounds or statistical oracle inequalities, both of which are substantially different from the focus of the present paper. In the online mistake-bound setting a special form of matrix completion was previously considered as the problem of learning a binary relation [14, 15] (see Section 5). In a more general online setting, with minimal assumptions on the loss function [16, 17] bounded the regret of the learner in terms of the trace-norm of the underlying matrix. Instead our bounds are with respect to the margin complexity of the matrix. As a result, although our bounds have a more restricted applicability they have the advantage that they become non-trivial after only ˜⇥(n) matrix entries1 are observed as opposed to the required ˜⇥(n3/2) in [16] and ˜⇥(n7/4) in [17]. The notion of margin complexity in machine learning was introduced in [2] where it was used to the study the learnability of concept classes via linear embeddings and further studied in [3], where it was linked to the γ2 norm. Here we adopt the terminology in [11] and refer to the γ2 norm as the max-norm. The margin complexity seems to be a more natural parameter as opposed to the trace-norm for the 0-1 loss as it only depends on the signs of the underlying comparator matrix. To the best of our knowledge the bounds contained herein are the first online matrix completion bounds in terms of the margin complexity. To obtain our results, we use an online matrix multiplicative weights algorithm, e.g., see [1, 18, 17, 19] and references therein. These kinds of algorithms have been applied in a number of learning scenarios, including online PCA [20], online variance minimization [21], solving SDPs [18], and online prediction with switching sequences [22]. These algorithms update a new hypothesis matrix on each trial by trading off fidelity to the previous hypothesis and the incorporation of the new label information. The tradeoff is computed as an approximate spectral regularization via the quantum relative entropy (see [1, Section 3.1]). The particular matrix multiplicative weights algorithm we apply is Matrix Winnow [19]; we adapt this algorithm and its mistake bound analysis for our purposes via selection of comparator, threshold, and appropriate “progress inequalities.” The paper is organized as follows. In Section 2 we introduce basic notions used in the paper. In Section 3 we present our algorithm and derive a mistake bound, also comparing it to related bounds in the literature. In Section 4 we observe that our algorithm is able to exploit matrix structure to perform comparably to the Kernel Perceptron with the best kernel known in advance. Finally, in Section 5 we discuss the example of biclustered matrices, and argue that our bound is optimal up to a polylogarithmic factor. The appendix contains proofs of the results only stated in the main body of the paper, and other auxiliary results. 2 Preliminaries We denote the set of the first m positive integers as Nm = {1, . . . , m}. We denote the inner product of vectors x, w 2 Rn as hx, wi = Pn i=1 xiwi and the norm as |w| = p hw, wi. We let Rm⇥n be the set of all m ⇥n real-valued matrices. If X 2 Rm⇥n then Xi denotes the i-th n-dimensional row vector and the (i, j) entry in X is Xij. The trace of a square matrix X 2 Rn⇥n is Tr(X) = Pn i=1 Xii. The trace norm of a matrix X 2 Rm⇥n is kXk1 = Tr( p X >X), where p· indicates the unique positive square root of a positive semi-definite matrix. For every matrix U 2 {−1, 1}m⇥n, we define SP(U) = {V 2 Rm⇥n : 8ijVijUij > 0}, the set of matrices which 1For simplicity we assume m 2 ⇥(n). 2 are sign consistent with U. We also define SP1(U) = {V 2 Rm⇥n : 8ijVijUij ≥1}, that is the set of matrices which are sign consistent to U with a margin of at least one. The max-norm (or γ2 norm [3]) of a matrix U 2 Rm⇥n is defined by the formula kUkmax := inf P Q>=U ⇢ max 1im |P i| max 1jn |Qj| $ , (1) where the infimum is over all matrices P 2 Rm⇥k and Q 2 Rn⇥k and every integer k. The margin complexity of a matrix U 2 Rm⇥n is mc(U) := inf P Q>2SP(U) max ij |P i||Qj| |hP i, Qji| . This quantity plays a central role in the analysis of our algorithm. If we interpret the rows of U as m different binary classification tasks, and the columns as a finite set of objects which we wish to label, the “min-max” margin with respect to an embedding is smallest of the m maximal margins over the tasks. The quantity 1/ mc(U) is then the maximum “min-max” margin with respect to all possible embeddings. Specifically, the rows of matrix P represent the “weights” of the binary classifiers and the rows of matrix Q the “input vectors” associated with the objects. The quantity |hP i,Qji| |P i||Qj| is the margin of the i-th classifier on the j-th input. Observe that margin complexity depends only on the sign pattern of the matrix and not the magnitudes. The margin complexity is equivalently mc(U) = minV 2SP1(U) kV kmax, see e.g., [3, Lemma 3.1]. In our online setting we are concerned with predicting an (example) sequence ((i1, j1), y1), . . . , ((iT , jT ), yT ) 2 (Nm ⇥Nn) ⇥{−1, 1}. A sequence must be consistent, that is, given examples ((i, j), y) and ((i0, j0), y0) if (i, j) = (i0, j0) then y = y0. We define the set of signconsistent matrices with a sequence S as cons(S) := {M 2 Rm⇥n : 0 < yMij, ((i, j), y) 2 S}. We extend the notion of margin complexity to sequences via mc(S) := infU2cons(S) mc(U). The number of margin violations in a sequence S at complexity γ is defined to be, merr(S, γ) := inf P Q>2cons(S) %%%% ⇢ ((i, j), y) 2 S : |P i||Qj| |hP i, Qji| > 1 γ $%%%% . (2) In particular, note that merr(S, γ) = 0 if γ 1 mc(S). Finally, we introduce the following quantity, which plays a central role in the amortized analysis of our algorithm. Definition 2.1. The quantum relative entropy of symmetric positive semidefinite square matrices A and B is ∆(A, B) := Tr(A log (A) −A log (B) + B −A). 3 Algorithm and Analysis Algorithm 1 presents an adaptation of the Matrix Exponentiated Gradient algorithm [1, 17, 18, 19] to our setting. This algorithm is a matrix analog of the Winnow algorithm [19]; we refer to the above papers for more insights into this family of algorithms. The following theorem provides a mistake bound for the algorithm. Theorem 3.1. The number of mistakes, M, on sequence S made by the Algorithm 1 with parameter 0 < γ 1 is upper bounded by M c (m + n) log(m + n) 1 γ2 + merr(S, γ) ' , (3) where c = 1/(3 −e) 3.55 and the quantity merr(S, γ) is given in equation (2). Proof. Given U 2 Rm⇥n, let P 2 Rm⇥k and Q 2 Rn⇥k be such that P Q > = U. For every i 2 Nm, we denote by P i the i-th row vector of P and for every j 2 Nn, we denote by Qj the j-th row vector of Q. We construct the (m + n) ⇥k matrix R := diag ✓ 1 |P 1|, . . . , 1 |P m|, 1 |Q1|, . . . , 1 |Qn| ◆ P Q ' 3 Algorithm 1 Predicting a binary matrix. Parameters: Learning rate 0 < γ 1 . Initialization: W (0) I (m+n), where I is the (m + n) ⇥(m + n) identity matrix. For t = 1, . . . , T • Get pair (it, jt) 2 Nm ⇥Nn. • Define X(t) := 1 2(eit + em+jt)(eit + em+jt)>, where ek is the k-th basis vector of Rm+n. • Predict ˆyt = ( 1 if Tr(W (t−1)X(t)) ≥ 1 m+n, −1 otherwise. • Receive label yt 2 {−1, 1} and if ˆyt 6= yt update W (t) exp ⇣ log ⇣ W (t−1)⌘ + γ 2 (yt −ˆyt)X(t)⌘ . and construct ˜U := ( 1 m+n)RR >. Define matrix X(t) := 1 2(eit + em+jt)(eit + em+jt)>, where ek is the k-th basis vector of Rm+n. Note that Tr(X(t)) = 1, Tr( ˜U) = 1 (since every row of R is normalized) and Tr( ˜UX(t)) = 1 n + m Tr((RR >)1 2(eit + em+jt)(eit + em+jt) >) = 1 2(n + m)(eit + em+jt) >RR >(eit + em+jt) = 1 2(n + m)(R >(eit + em+jt)) >(R >(eit + em+jt)) = 1 2(n + m) ✓P it |P it| + Qjt |Qjt| ◆✓P it |P it| + Qjt |Qjt| ◆> = 1 (n + m) ✓ 1 + hP it, Qjti |P it||Qjt| ◆ . For a trial t we say there is a margin violation if |P it||Qjt| |hP it,Qjti| > 1 γ . Let M −denote the number of mistakes made in trials with margin violations and let M + denote the number of mistakes made in trials without margin violations. From Lemma A.3 in the appendix we have ∆( ˜U, W (t−1)) −∆( ˜U, W (t)) ≥γ 2 (yt −ˆyt) Tr( ˜UX(t)) + ⇣ 1 −e γ 2 (yt−ˆyt)⌘ Tr(W (t−1)X(t)) , then substituting in the above we have that ∆( ˜U, W (t−1)) −∆( ˜U, W (t)) ≥γ 2 (yt −ˆyt) 1 n + m ✓ 1 + hP it, Qjti |P it||Qjt| ◆ + ⇣ 1 −e γ 2 (yt−ˆyt)⌘ Tr(W (t−1)X(t)) . To further simplify the above we use Lemma A.4 presented in the appendix, which gives ∆( ˜U, W (t−1)) −∆( ˜U, W (t)) ≥ 8 < : (c0 −1) 1 n+mγ2, if there is a margin violation , c0 1 n+mγ2, otherwise. where c0 = 3 −e. 4 Using a telescoping sum, this gives ∆( ˜U, W (0)) ≥ ∆( ˜U, W (0)) −∆( ˜U, W (T )) ≥M +c0 1 n + mγ2 + M −(c0 −1) 1 n + mγ2 = (c0M + −(1 −c0)M −) 1 n + mγ2 and hence M + 1 c0 1 n+mγ2 ∆( ˜U, W (0)) + 1 −c0 c0 M −. We conclude that M = M + + M − 1 c0 1 n+mγ2 ∆( ˜U, W (0)) + 1 c0 M −. We also have that ∆( ˜U, W (0)) = Tr( ˜U log( ˜U)) −Tr( ˜U log(W (0))) + Tr(W (0)) −Tr( ˜U) = Tr( ˜U log( ˜U)) −Tr( ˜U log(W (0))) + 1 −1 = Tr( ˜U log( ˜U)) −Tr( ˜U log(W (0))) . Write the eigen-decomposition of ˜U as Pm+n i=1 λi↵i↵T i . Now we have Pm+n i=1 λi = Tr( ˜U) = 1 so all eigenvalues λi are in the range [0, 1] meaning log(λi) 0 so λi log(λi) < 0 which are the eigenvalues of ˜U log( ˜U) meaning that Tr( ˜U log( ˜U)) 0. Also, log(W (0)) = log( 1 n+m)I so ˜U log(W (0)) = log( 1 n+m) ˜U and hence −Tr( ˜U log(W (0))) = −log( 1 n+m) Tr( ˜U) = log(m+n). So by the above we have ∆( ˜U, W (0)) log(m + n) and hence putting together we get M m + n c0γ2 log(m + n) + 1 c0 M −. Observe that in the simplifying case when we have no margin errors (merr(S, γ) = 0) and the learning rate is γ := 1 mc(S) we have that the number of mistakes of Algorithm 1 is bounded by ˜O((n + m) mc2(S)). More generally although the learning rate is fixed in advance, we may use a “doubling trick” to avoid the need to tune the γ. Corollary 3.2. For any value of γ⇤the number of mistakes M made by the following algorithm: DOUBLING ALGORITHM: Set p 2 and loop over 1. Run Algorithm 1 with γ = 1 until it has made d2c(m + n) log(m + n)2e mistakes 2. Set p 2 is upper bounded by M 12c (m + n) log(m + n) 1 (γ⇤)2 + merr(S, γ⇤) ' , with c = 1/(3 −e) ⇡3.55. See the appendix for a proof. We now compare our bound to other online learning algorithms for matrix completion. The algorithms of [16, 17] address matrix completion in a significantly more general setting. Both algorithms operate with weak assumptions on the loss function, while our algorithm is restricted to the 0–1 loss (mistake counting). Those papers present regret bounds, whereas we apply the stronger assumption that there exists a consistent predictor. As a regret bound is not possible for a deterministic predictor with the 0–1 loss, we compare Theorem 3.1 to their 5 bound when their algorithm is allowed to predict ˆy 2 [−1, 1] and uses absolute loss. For clarity in our discussion we will assume that m 2 ⇥(n). Under the above assumptions, the regret bound in [17, Corollary 7] becomes 2 p kUk1(m + n)1/2 log(m + n)T. For simplicity we consider the simplified setting in which each entry is predicted, that is T = mn; then absorbing polylogarithmic factors, their bound is ˜O(n5/4kUk 1 2 1 ). From Theorem 3.1 we have a bound of ˜O(n mc2(U)). Using [11, Theorem 10], we may upper bound the margin complexity in terms of the trace norm, mc(U) 3 min V 2SP1(U) kV k 1 3 1 3kUk 1 3 1 . (4) Substituting this into Theorem 3.1 our bound is ˜O(nkUk 2 3 1 ). Since the trace norm may be bounded as n kUk1 n3/2, both bounds become vacuous when kUk1 = n3/2, however if the trace norm is bounded away from n3/2, the bound of Theorem 3.1 is smaller by a polynomial factor. An aspect of the bounds which this comparison fails to capture is the fact that since [17, Corollary 7] is a regret bound it will degrade more smoothly under adversarial noise than Theorem 3.1. The algorithm in [16] is probabilistic and the regret bound is of ˜O(kUk1 pn). Unlike [17], the setting of [16] is transductive, that is each matrix entry is seen only once, and thus less general. If we use the upper bound from [11, Theorem 10] as in the discussion of [17] then [16] improves uniformly on our bound and the bound in [17]. However, using this upper bound oversimplifies the comparison as 1 mc2(U) n while n kUk1 n3/2 for U 2 {−1, 1}m⇥n. In other words we have been very conservative in our comparison; the bound (4) may be loose and our algorithm may often have a much smaller bound. A specific example is provided by the class of (k, `)-biclustered matrices (see also the discussion in Section 5 below) where mc2(U) min(k, `), in which case bound becomes nontrivial after ˜⇥(min(k, `) n) examples while the bounds in [16] and [17] become nontrivial after at least ˜⇥(n3/2) and ˜⇥(n7/4) examples, respectively. With respect to computation our algorithm on each trial requires a single eigenvalue decomposition of a PSD matrix, whereas the algorithm of [17] requires multiple eigenvalue decompositions per trial. Although [16] does not discuss the complexity of their algorithm beyond the fact that it is polynomial, in [17] it is conjectured that it requires at a minimum ⇥(n4) time per trial. 4 Comparison to the Best Kernel Perceptron In this section, we observe that Algorithm 1 has a mistake bound that is comparable to Novikoff’s bound [23] for the Kernel Perceptron with an optimal kernel in hindsight. To explain our observation, we interpret the rows of matrix U as m different binary classification tasks, and the columns as a finite set of objects which we wish to label; think for example of users/movies matrix in recommendation systems. If we solve the tasks independently using a Kernel Perceptron algorithm, we will make O(1/γ2) mistakes per task, where γ is the largest margin of a consistent hypothesis. If every task has a margin larger than γ we will make O(m/γ2) mistakes in total. This algorithm and the parameter γ crucially depend on the kernel used: if there exists a kernel which makes γ large for all (or most of) the tasks, then the Kernel Perceptron will incur a small number of mistakes on all (or most of) the tasks. We now argue that our bound mimics this “oracle”, without knowing in advance the kernel. Without loss of generality, we assume m ≥n (otherwise apply the same reasoning below to matrix U >). In this scenario, Theorem 3.1 upper bounds the number of mistakes as O ✓m log m γ2 ◆ where γ is chosen so that merr(S, γ) = 0. To further illustrate our idea, we define the task complexity of a matrix U 2 Rm⇥n as ⌧(U) = min 0 h(V ) : V 2 SP1(U) where h(V ) = inf K≻0 max 1im V iK−1V > i max 1jn Kjj . (5) Note that the quantity V iK−1V > i max1jn Kjj is exactly the bound in Novikoff’s Theorem on the number of mistakes of the Kernel Perceptron on the i-th task with kernel K. Hence the quantity 6 h(V ) represents the best upper bound on the number of mistakes made by a Kernel Perceptron on the worst (since we take the maximum over i) task. Proposition 4.1. For every U 2 Rm⇥n, it holds that mc2(U) = ⌧(U). Proof. The result follows by Lemma A.6 presented in the appendix and by the formula mc(U) = minV 2SP1(U) kV kmax, see, e.g., [3, Lemma 3.1]. Returning to the interpretation of the bound in Theorem 3.1, we observe that if no more than r out of the m tasks have margin smaller than a threshold λ then in Algorithm 1 setting parameter γ = λ, Theorem 3.1 gives a bound of O ✓(m −r) log m λ2 + rn ◆ . Thus we essentially “pay” linearly for every object in a difficult task. Since we assume n m, provided r is small the bound is “robust” to the presence of bad tasks. We specialize the above discussion to the case that each of the m tasks is a binary labeling of an unknown underlying connected graph G := (V, E) with n vertices and assume that m ≥n. We let U 2 {−1, 1}m⇥n be the matrix, the rows of which are different binary labelings of the graph. For every i 2 Nm, we interpret U i, the i-th row of matrix U, as the i-th labeling of the graph and let Φi be the corresponding cutsize, namely, Φi := |{(j, j0) 2 E : Uij 6= Uij0}| and define Φmax := max1im Φi. In order to apply Theorem 3.1, we need to bound the margin complexity of U. Using the above analysis (Proposition 4.1), this quantity is upper bounded by mc2(U) max 1im U iK−1U > i max 1jn Kjj. (6) We choose the kernel K := L+ + (R 11T ), where L is the graph Laplacian of G, the vector 1 has all components equal to one, and R = maxj L+ jj. Since the graph is connected then 1 is the only eigenvector of L with zero eigenvalue. Hence K is invertible and K−1 = L + (R 11T )+ = L+(R n 1 pn11T 1 pn)+ = L+ 1 Rn2 11T . Then using the formula Φi = 1 4U iLU > i we obtain from (6) that mc2(U) max 1im ✓ 4Φi + 1 R ◆ R . Theorem 3.1 then gives a bound of M O ((1 + ΦmaxR) m log m). The quantity R may be further upper bounded by the graph resistance diameter, see for example [24]. 5 Biclustering and Near Optimality The problem of learning a (k, `)-binary-biclustered matrix, corresponds to the assumption that the row indices and column indices represent k and ` distinct object types and that there exists a binary relation on these objects which determines the matrix entry. Formally we have the following Definition 5.1. The class of (k, `)-binary-biclustered matrices is defined as Bm,n k,` = {U 2 Rm⇥n : r 2 Nm k , c 2 Nn ` , F 2 {−1, 1}k⇥`, Uij = Fricj, i 2 Nm, j 2 Nn} . The intuition is that a matrix is (k, `)-biclustered if after a permutation of the rows and columns the resulting matrix is a k ⇥` grid of rectangles and all entries in a given rectangle are either 1 or −1. The problem of determining a (k, `)-biclustered matrix with a minimum number of “violated” entries given a subset of entries was shown to be NP-hard in [25]. Thus although we do not give an algorithm that provides a biclustering, we provide a bound in terms of the best consistent biclustering. Lemma 5.2. If U 2 Bm,n k,` then mc2(U) min(k, `). Proof. We use Proposition 4.1 to upper bound mc2(U) by h(U), where the function h is given in equation (5). We further upper bound h(U) by choosing a kernel matrix in the underlying optimization problem. By Definition 5.1, there exists r 2 Nm k , c 2 Nn ` and F 2 {−1, 1}k⇥` 7 such that Uij = Fricj, for every i 2 Nm and every j 2 Nn. Then we choose the kernel matrix K = (Kjj0)1j,j0n such that Kjj0 := δcjc0 j + ✏δjj0 One verifies that U iK−1U > i ` for every i 2 {1, . . . , m}, hence by taking the limit for ✏! 0 Proposition 4.1 gives that mc2(U) ` . By the symmetry of our construction we can swap ` with k, giving the bound. Using this lemma with Theorem 3.1 gives us the following upper bound on the number of mistakes. Corollary 5.3. The number of mistakes of Algorithm 1 applied to sequences generated by a (k, `)binary-biclustered matrix is upper bounded by O(min(k, `)(m + n) log(m + n)). A special case of the setting in this corollary was first studied in the mistake bound setting in [14]. In [15] the bound was improved and generalized to include robustness to noise (for simplicity we do not compare in the noisy setting). In both papers the underlying assumption is that there are k distinct row types and no restrictions on the number of columns thus ` = n. In this case they obtained an upper bound of kn + min( m2 2e log2 e, m p 3n log2 k). Comparing the two bounds we can see that when k < n 1 2 −✏the bound in Corollary 5.3 improves over [15, Corollary 1] by a polynomial factor and on other hand when k ≥n 1 2 we are no worse than a polylogarithmic factor. We now establish that the mistake bound (3) is tight up to a poly-logarithmic factor. Theorem 5.4. Given an online algorithm A that predicts the entries of a matrix U 2 {−1, 1}m⇥n and given an ` 2 Nn there exists a sequence S constructed by an adversary with margin complexity mc(S) p `. On this sequence the algorithm A will make at least ` ⇥m mistakes. See the appendix for a proof. 6 Conclusion In this paper, we presented a Matrix Exponentiated Gradient algorithm for completing the entries of a binary matrix in an online learning setting. We established a mistake bound for this algorithm, which is controlled by the margin complexity of the underlying binary matrix. We discussed improvements of the bound over related bounds for matrix completion. Specifically, we noted that our bound requires fewer examples before it becomes non-trivial, as compared to the bounds in [16, 17]. Here we require only ˜⇥(m + n) examples as opposed to the required ˜⇥((m + n)3/2) in [16] and ˜⇥((m + n)7/4), respectively. Thus although our bound is more sensitive to noise, it captures structure more quickly in the underlying matrix. When interpreting the rows of the matrix as binary tasks, we argued that our algorithm performs comparably (up to logarithmic factors) to the Kernel Perceptron with the optimal kernel in retrospect. Finally, we highlighted the example of completing a biclustered matrix and noted that this is instrumental in showing the optimality of the algorithm in Theorem 5.4. We observed that Algorithm 1 has a per trial computational cost which is smaller than currently available algorithms for matrix completion with online guarantees. In the future it would be valuable to study if improvements in this computation are possible by exploiting the special structure in our algorithm. Furthermore, it would be very interesting to study a modification of our analysis to the case in which the tasks (rows of matrix U) grow over time, a setting which resembles the lifelong learning frameworks in [26, 27]. Acknowledgements. We wish to thank the anonymous reviewers for their useful comments. This work was supported in part by EPSRC Grants EP/P009069/1, EP/M006093/1, and by the U.S. Army Research Laboratory and the U.K. Defence Science and Technology Laboratory and was accomplished under Agreement Number W911NF-16-3-0001. The views and conclusions contained in this document are those of the authors and should not be interpreted as representing the official policies, ether expressed or implied, of the U.S. Army Research Laboratory, the U.S. Government, the U.K. Defence Science and Technology Laboratory or the U.K. Government. The U.S. and U.K. Governments are authorized to reproduce and distribute reprints for Government purposes notwithstanding any copyright notation herein. 8 References [1] K. Tsuda, G. Rätsch, and M.K. Warmuth. Matrix exponentiated gradient updates for on-line learning and bregman projection. Journal of Machine Learning Research, 6:995–1018, 2005. [2] S. Ben-David, N. Eiron, and H. U. Simon. Limitations of learning via embeddings in euclidean half spaces. Journal of Machine Learning Research, 3:441–461, 2003. [3] N. Linial, S. Mendelson, G. Schechtman, and A. Shraibman. Complexity measures of sign matrices. Combinatorica, 27(4):439–463, 2007. [4] M. Herbster, M. Pontil, and L. Wainer. Online learning over graphs. In Proceedings of the 22nd International Conference on Machine Learning, pages 305–312, 2005. [5] X. Zhu, Z. Ghahramani, and J. Lafferty. Semi-supervised learning using gaussian fields and harmonic functions. In Proc. 20th International Conference on Machine Learning, pages 912–919, 2003. [6] M. Belkin and P. Niyogi. Semi-supervised learning on riemannian manifolds. Machine Learning, 56:209– 239, 2004. [7] N. Cesa-Bianchi, C. Gentile, and F. Vitale. Fast and optimal prediction of a labeled tree. In Proceedings of the 22nd Annual Conference on Learning Theory, 2009. [8] N. Cesa-Bianchi, C. Gentile, F. Vitale, and G. Zappella. Random spanning trees and the prediction of weighted graphs. Journal of Machine Learning Research, 14(1):1251–1284, 2013. [9] N. Cesa-Bianchi, C. Gentile, and F. Vitale. Predicting the labels of an unknown graph via adaptive exploration. Theoretical Computer Science, 412(19):1791–1804, 2011. [10] C. Gentile, M. Herbster, and S. Pasteris. Online similarity prediction of networked data from known and unknown graphs. In Proceedings of the 26th Annual Conference on Learning Theory, 2013. [11] N. Srebro and A. Shraibman. Rank, trace-norm and max-norm. In Proceedings of the 18th Annual Conference on Learning Theory, pages 545–560, 2005. [12] E. J. Candès and T. Tao. The power of convex relaxation: Near-optimal matrix completion. IEEE Trans. Inf. Theor., 56(5):2053–2080, May 2010. [13] A. Maurer and M. Pontil. Excess risk bounds for multitask learning with trace norm regularization. In Proceedings of The 27th Conference on Learning Theory (COLT), pages pages 55–76, 2013. [14] S. A. Goldman, R. L. Rivest, and R. E. Schapire. Learning binary relations and total orders. SIAM J. Comput., 22(5), 1993. [15] S. A. Goldman and M. K. Warmuth. Learning binary relations using weighted majority voting. In Proceedings of the 6th Annual Conference on Computational Learning Theory, pages 453–462, 1993. [16] N. Cesa-Bianchi and O. Shamir. Efficient online learning via randomized rounding. In Advances in Neural Information Processing Systems 24, pages 343–351, 2011. [17] E. Hazan, S. Kale, and S. Shalev-Shwartz. Near-optimal algorithms for online matrix prediction. In Proc. 23rd Annual Conference on Learning Theory, volume 23:38.1-38.13. JMLR W&CP, 2012. [18] S. Arora and S. Kale. A combinatorial, primal-dual approach to semidefinite programs. In Proceedings of the 29th Annual ACM Symposium on Theory of Computing, pages 227–236, 2007. [19] M.K. Warmuth. Winnowing subspaces. In Proceedings of the 24th International Conference on Machine Learning, pages 999–1006, 2007. [20] J. Nie, W. Kotłowski, and M. K. Warmuth. Online PCA with optimal regrets. In Proceedings of the 24th International Conference on Algorithmic Learning Theory, pages 98–112, 2013. [21] M. K. Warmuth and D. Kuzmin. Online variance minimization. Machine Learning, 87(1):1–32, 2012. [22] M. Herbster, S. Pasteris, and S. Pontil. Predicting a switching sequence of graph labelings. Journal of Machine Learning Research, 16:2003–2022, 2015. [23] A.B. Novikoff. On convergence proofs on perceptrons. In Proceedings of the Symposium on the Mathematical Theory of Automata, pages 615–622, 1962. [24] M. Herbster and M. Pontil. Prediction on a graph with a perceptron. In Advances in Neural Information Processing Systems 19, pages 577–584, 2006. [25] S. Wulff, R. Urner, and S. Ben-David. Monochromatic bi-clustering. In Proc. 30th International Conference on Machine Learning, volume 28, pages 145–153. JMLR W&CP, 2013. [26] P. Alquier, T.-T. Mai, and M. Pontil. Regret bounds for lifelong learning. Preprint, 2016. [27] M.-F. Balcan, A. Blum, and S. Vempala. Efficient representations for lifelong learning and autoencoding. In Proc. 28th Conference on Learning Theory, pages 191–210, 2015. [28] R. Bhatia. Matrix Analysis. Springer Verlag, New York, 1997. 9 | 2016 | 477 |
6,413 | Quantum Perceptron Models Nathan Wiebe Microsoft Research Redmond WA, 98052 nawiebe@microsoft.com Ashish Kapoor Microsoft Research Redmond WA, 98052 akapoor@microsoft.com Krysta M Svore Microsoft Research Redmond WA, 98052 ksvore@microsoft.com Abstract We demonstrate how quantum computation can provide non-trivial improvements in the computational and statistical complexity of the perceptron model. We develop two quantum algorithms for perceptron learning. The first algorithm exploits quantum information processing to determine a separating hyperplane using a number of steps sublinear in the number of data points N, namely O( √ N). The second algorithm illustrates how the classical mistake bound of O( 1 γ2 ) can be further improved to O( 1 √γ ) through quantum means, where γ denotes the margin. Such improvements are achieved through the application of quantum amplitude amplification to the version space interpretation of the perceptron model. 1 Introduction Quantum computation is an emerging technology that utilizes quantum effects to achieve significant, and in some cases exponential, speed-ups of algorithms over their classical counterparts. The growing importance of machine learning has in recent years led to a host of studies that investigate the promise of quantum computers for machine learning [1, 2, 3, 4, 5, 6, 7, 8, 9]. While a number of important quantum speedups have been found, the majority of these speedups are due to replacing a classical subroutine with an equivalent albeit faster quantum algorithm. The true potential of quantum algorithms may therefore remain underexploited since quantum algorithms have been constrainted to follow the same methodology behind traditional machine learning methods [10, 8, 9]. Here we consider an alternate approach: we devise a new machine learning algorithm that is tailored to the speedups that quantum computers can provide. We illustrate our approach by focusing on perceptron training [11]. The perceptron is a fundamental building block for various machine learning models including neural networks and support vector machines [12]. Unlike many other machine learning algorithms, tight bounds are known for the computational and statistical complexity of traditional perceptron training. Consequently, we are able to rigorously show different performance improvements that stem from either using quantum computers to improve traditional perceptron training or from devising a new form of perceptron training that aligns with the capabilities of quantum computers. We provide two quantum approaches to perceptron training. The first approach focuses on the computational aspect of the problem and the proposed method quadratically reduces the scaling of the complexity of training with respect to the number of training vectors. The second algorithm focuses on statistical efficiency. In particular, we use the mistake bounds for traditional perceptron training methods and ask if quantum computation lends any advantages. To this end, we propose an algorithm that quadratically improves the scaling of the training algorithm with respect to the margin between the classes in the training data. The latter algorithm combines quantum amplitude estimation in the version space interpretation of the perceptron learning problem. Our approaches showcase the trade-offs that one can consider in developing quantum algorithms, and the ultimate advantages of performing learning tasks on a quantum computer. 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. Feature Space Version Space Figure 1: Version space and feature space views of classification. This figure is from [18]. The rest of the paper is organized as follows: we first cover the background on perceptrons, version space and Grover search. We then present our two quantum algorithms and provide analysis of their computational and statistical efficiency before concluding. 2 Background 2.1 Perceptrons and Version Space Given a set of N separable training examples {φ1, .., φN} ∈IRD with corresponding labels {y1, .., yN}, yi ∈{+1, −1}, the goal of perceptron learning is to recover a hyperplane w that perfectly classifies the training set [11]. Formally, we want w such that yi · wT φi > 0 for all i. There are various simple online algorithms that start with a random initialization of the hyperplane and make updates as they encounter more and more data [11, 13, 14, 15]; however, the rule that we consider for online perceptron training is, upon misclassifying a vector (φ, y), w ←w + yφ. A remarkable feature of the perceptron model is that upper bounds exist for the number of updates that need to be made during this training procedure. In particular, if the training data is composed of unit vectors, φi ∈IRD, that are separated by a margin of γ then there are perceptron training algorithms that make at most O( 1 γ2 ) mistakes [16], independent of the dimension of the training vectors. Similar bounds also exist when the data is not separated [17] and also for other generalizations of perceptron training [13, 14, 15]. Note that in the worst case, the algorithm will need to look at all points in the training set at least once, consequently the computation complexity will be O(N). Our goal is to explore if the quantum procedures can provide improvements both in terms of computational complexity (that is better than O(N)) and statistical efficiency (improve upon O( 1 γ2 ). Instead of solely applying quantum constructs to the feature space, we also consider the version space interpretation of perceptrons which leads to the improved scaling with γ. Formally, version space is defined as the set of all possible hyperplanes that perfectly separate the data: VS := {w|yi · wT φi > 0 for all i}. Given a training datum, the traditional representation is to depict data as points in the feature space and use hyperplanes to depict the classifiers. However, there exists a dual representation where the hyperplanes are depicted as points and the data points are represented as hyperplanes that induce constraints on the feasible set of classifiers. Figure 1, which is borrowed from [18], illustrates the version space interpretation of perceptrons. Given three labeled data points in a 2D space, the dual space illustrates the set of normalized hyperplanes as a yellow ball with unit radius. The third dimension corresponds to the weights that multiply the two dimensions of the input data and the bias term. The planes represent the constraints imposed by observing the labeled data as every labeled data renders one-half of the space infeasible. The version space is then the intersection of all the half-spaces that are valid. Naturally, classifiers including SVMs [12] and Bayes point machines [19] lie in the version space. We note that there are quantum constructs such as Grover search and amplitude amplification which provide non-trivial speedups for the search task. This is the main reason why we resort to the version space interpretation. We can use this formalism to simply pose the problem of determining the 2 ψ Pψ/||Pψ|| ψ Pψ/||Pψ|| Utargψ ψ Pψ/||Pψ|| Utargψ Utargψ Uinit qa qa qa qa qa qa 2 Figure 2: A geometric description of the action of Ugrover on an initial state vector ψ. separating hyperplane as a search problem in the dual space. For example given a set of candidates hyperplanes, our problem reduces to searching amongst the sample set for the classifier that will successfully classify the entire set. Therefore training the perceptron is equivalent to finding any feasible point in the version space. We describe these quantum constructs in detail below. 2.2 Grover’s Search Both quantum approaches introduced in this work and their corresponding speed-ups stem from a quantum subroutine called Grover’s search [20, 21], which is a special case of a more general method referred to as amplitude amplification [22]. Rather than sampling from a probability distribution until a given marked element is found, the Grover search algorithm draws only one sample and then uses quantum operations to modify the distribution from which it sampled. The probability distribution is rotated, or more accurately the quantum state that yields the distribution is rotated, into one whose probability is sharply concentrated on the marked element. Once a sharply peaked distribution is identified, the marked item can be found using just one sample. In general, if the probability of finding such an element is known to be a then amplitude amplification requires O( p 1/a) operations to find the marked item with certainty. While Grover’s search is a quantum subroutine, it can in fact be understood using only geometric arguments. The only notions from quantum mechanics used are those of the quantum state vector and that of Born’s rule (measurement). A quantum state vector is a complex unit vector whose components have magnitudes that are equal to the square–roots of the probabilities. In particular, if ψ is a quantum state vector and p is the corresponding probability distribution then p = ψ† ◦ψ, (1) where the unit column vector ψ is called the quantum state vector which sits in the vector space Cn, ◦ is the Hadamard (pointwise) product and † is the complex conjugate transpose. A quantum state can be measured such that if we have a quantum state vector ψ and a basis vector w then the probability of measuring ψ = w is |⟨ψ, w⟩|2, where ⟨·, ·⟩denotes the inner product. We need to implement two unitary operations in order to perform the search algorithm: Uinit = 2ψψ† −11, Utarg = 11 −2P. (2) The operators Uinit and Utarg can be interpreted geometrically as reflections within a two–dimensional space spanned by the vectors ψ and Pψ. If we assume that Pψ ̸= 0 and Pψ ̸= ψ then these two reflection operations can be used to rotate ψ in the space span(ψ, Pψ). Specifically this rotation is Ugrover = UinitUtarg. Its action is illustrated in Figure 2. If the angle between the vector ψ and Pψ/∥Pψ∥is π/2 −θa, where θa := sin−1(|⟨ψ, Pψ/∥Pψ∥⟩|). It then follows from elementary geometry and the rule for computing the probability distribution from a quantum state (known as Born’s rule) that after j iterations of Grover’s algorithm the probability of finding a desirable outcome is p(ψ ∈νgood|j) = sin2((2j + 1)θa). (3) It is then easy to see that if θa ≪1 and a probability of success greater than 1/4 is desired then j ∈O(1/√θa) suffices to find a marked outcome. This is quadratically faster than is possible from statistical sampling, which requires O(1/θa) samples on average. Simple modifications to this algorithm allow it to be used in cases where θa is not known [21, 22]. 3 3 Online quantum perceptron Now that we have discussed Grover’s search we turn our attention to applying it to speed up online perceptron training. In order to do so, we first need to define the quantum model that we wish to use as our quantum analogue of perceptron training. While there are many ways of defining such a model but the following approach is perhaps the most direct. Although the traditional feature space perceptron training algorithm is online [16], meaning that the training examples are provided one at a time to it in a streaming fashion, we deviate from this model slightly by instead requiring that the algorithm be fed training examples that are, in effect, sampled uniformly from the training set. This is a slightly weaker model, as it allows for the possibility that some training examples will be drawn multiple times. However, the ability to draw quantum states that are in a uniform superposition over all vectors in the training set enables quantum computing to provide advantages over both classical methods that use either access model. We assume without loss of generality that the training set consists of N unit vectors, φ1, . . . , φN. If we then define Φ1, . . . , ΦN to be the basis vectors whose indices each coincide with a (B + 1)-bit representation of the corresponding (φj, yj) where yj ∈{−1, 1} is the class assigned to φj and let Φ0 be a fixed unit vector that is chosen to represent a blank memory register. We introduce the vectors Φj to make it clear that the quantum vectors states used to represent training vectors do not live in the same vector space as the training vectors themselves. We choose the quantum state vectors here to occupy a larger space than the training vectors because the Heisenberg uncertainty principle makes it much more difficult for a quantum computer to compute the class that the perceptron assigns to a training vector in such cases. For example, the training vector (φj, yj) ≡([0, 0, 1, 0]T , 1) can be encoded as an unsigned integer 00101 ≡5, which in turn can be represented by the unit vector Φ = [0, 0, 0, 0, 0, 1]T . More generally, if φj ∈IRD were a vector of floating point numbers then a similar vector could be constructed by concatenating the binary representations of the D floating point numbers that comprise it with (yj + 1)/2 and express the bit string as an unsigned integer, Q. The integer can then be expressed as a unit vector Φ : [Φ]q = δq,Q. While encoding the training data as an exponentially long vector is inefficient in a classical computer, it is not in a quantum computer because of the quantum computer’s innate ability to store and manipulate exponentially large quantum state vectors. Any machine learning algorithm, be it quantum or classical, needs to have a mechanism to access the training data. We assume that the data is accessed via an oracle that not only accesses the training data but also determines whether the data is misclassified. To clarify, let {uj : j = 1 : N} be an orthonormal basis of quantum state vectors that serve as addresses for the training vectors in the database. Given an input address for the training datum, the unitary operations U and U † allow the quantum computer to access the corresponding vector. Specifically, for all j U[uj ⊗Φ0] = uj ⊗Φj, U †[uj ⊗Φj] = uj ⊗Φ0. (4) Given an input address vector uj, the former corresponds to a database access and the latter inverts the database access. Note that because U and U † are linear operators we have that U PN j=1 uj ⊗Φ0 = P j uj ⊗Φj. A quantum computer can therefore access each training vector simultaneously using a single operation. The resultant vector is often called in the physics literature a quantum superposition of states and this feature of linear transformations is referred to as quantum parallelism within quantum computing. The next ingredient that we need is a method to test if the perceptron correctly assigns a training vector addressed by a particular uj. This process can be pictured as being performed by a unitary transformation that flips the sign of any basis-vector that is misclassified. By linearity, a single application of this process flips the sign of any component of the quantum state vector that coincides with a misclassified training vector. It therefore is no more expensive than testing if a given training vector is misclassified in a classical setting. We denote the operator, which depends on the perceptron weights w, Fw and require that Fw[uj ⊗Φ0] = (−1)fw(φj,yj)[uj ⊗Φ0], (5) where fw(φj) is a Boolean function that is 1 if and only if the perceptron with weights w misclassifies training vector φj. Since the classification step involves computing the dot–products of finite size vectors, this process is efficient given that the Φj are efficiently computable. 4 We apply Fw in the following way. Let Fw be a unitary operation such that FwΦj = (−1)fw(φj,yj)Φj. (6) Fw is easy to implement in the quantum computer using a multiply controlled phase gate and a quantum implementation of the perceptron classification algorithm, fw. We can then write Fw = U †(11 ⊗Fw)U. (7) Classifying the data based on the phases (the minus signs) output by Fw naturally leads to a very memory efficient training algorithm because only one training vector is ever stored in memory during the implementation of Fw given in Eq. (7). We can then use Fw to perform Grover’s search algorithm, by taking Utarg = Fw and Uinit = 2ψψ† −11 with ψ = Ψ := 1 √ N PN j=1 uj, to seek out training vectors that the current perceptron model misclassifies. This leads to a quadratic reduction in the number of times that the training vectors need to be accessed by Fw or its classical analogue. In the classical setting, the natural object to query is slightly different. The oracle that is usually assumed in online algorithms takes the form U c : Z 7→CD where U c(j) = φj. We will assume that a similar function exists in both the classical and the quantum settings for simplicity. In both cases, we will consider the cost of a query to U c to be proportional to the cost of a query to Fw. We use these operations in to implement a quantum search for training vectors that the perceptron misclassifies. This leads to a quadratic speedup relative to classical methods as shown in the following theorem. It is also worth noting that our algorithm uses a slight variant on the Grover search algorithm to ensure that the runtime is finite. Theorem 1. Given a training set that consists of unit vectors Φ1, . . . , ΦN that are separated by a margin of γ in feature space, the number of applications of Fw needed to infer a perceptron model, w, such that P(∃j : fw(φj) = 1) ≤ϵ using a quantum computer is Nquant where Ω( √ N) ∋Nquant ∈O √ N γ2 log 1 ϵγ2 ! , whereas the number of queries to fw needed in the classical setting, Nclass, where the training vectors are found by sampling uniformly from the training data is bounded by Ω(N) ∋Nclass ∈O N γ2 log 1 ϵγ2 . We assume in Theorem 1 that the training data in the classical case is accessed in a manner that is analogous to the sampling procedure used in the quantum setting. If instead the training data is supplied by a stream (as in the standard online model) then the upper bound changes to Nclass ∈ O(N/γ2) because all N training vectors can be deterministically checked to see if they are correctly classified by the perceptron. A quantum advantage is therefore obtained if N ≫log2(1/ϵγ2). In order to prove Theorem 1 we need to have two technical lemmas (proven in the supplemental material). The first bounds the complexity of the classical analogue to our training method: Lemma 1. Given only the ability to sample uniformly from the training vectors, the number of queries to fw needed to find a training vector that the current perceptron model fails to classify correctly, or conclude that no such example exists, with probability 1 −ϵγ2 is at most O(N log(1/ϵγ2)). The second proves the correctness of our online quantum perceptron algorithm and bounds the complexity of the algorithm: Lemma 2. Assuming that the training vectors {φ1, . . . , φN} are unit vectors and that they are drawn from two classes separated by a margin of γ in feature space, Algorithm 2 will either update the perceptron weights, or conclude that the current model provides a separating hyperplane between the two classes, using a number of queries to Fw that is bounded above by O( √ N log(1/ϵγ2)) with probability of failure at most ϵγ2. After stating these results, we can now provide the proof of Theorem 1. 5 Proof of Theorem 1. The upper bounds follow as direct consequences of Lemma 2 and Lemma 1. Novikoff’s theorem [16, 17] states that the algorithms described in both lemmas must be applied at most 1/γ2 times before finding the result. However, either the classical or the quantum algorithm may fail to find a misclassified vector at each of the O(1/γ2) steps. The union bound states that the probability that this happens is at most the sum of the respective probabilities in each step. These probabilities are constrained to be γ2ϵ, which means that the total probability of failing to correctly find a mistake is at most ϵ if both algorithms are repeated 1/γ2 times (which is the worst case number of times that they need to be repeated). The lower bound on the quantum query complexity follows from contradiction. Assume that there exists an algorithm that can train an arbitrary perceptron using o( √ N) query operations. Now we want to show that unstructured search with one marked element can be expressed as a perceptron training algorithm. Let w be a known set of perceptron weights and assume that the perceptron only misclassifies one vector φ1. Thus if perceptron training succeeds then w the value of φ1 can be extracted from the updated weights. This training problem is therefore equivalent to searching for a misclassified vector. Now let φj = [1 ⊕F(j), F(j)]T ⊗χj where χj is a unit vector that represents the bit string j and F(j) is a Boolean function. Assume that F(0) = 1 and F(j) = 0 if j ̸= 0, which is without loss of generality equivalent to Grover’s problem [20, 21]. Now assume that φj is assigned to class 2F(j) −1 and take w = [1/ √ 2, 1/ √ 2]T ⊗ 1 √ N P j χj. This perceptron therefore misclassifies φ0 and no other vector in the training set. Updating the weights yields φj, which in turn yields the value of j such that F(j) = 1, and so Grover’s search reduces to perceptron training. Since Grover’s search reduces to perceptron training in the case of one marked item the lower bound of Ω( √ N) queries for Grover’s search [21] applies to perceptron training. Since we assumed that perceptron training needs o( √ N) queries this is a contradiction and the lower bound must be Ω( √ N). We have assumed that in the classical setting that the user only has access to the training vectors through an oracle that is promised to draw a uniform sample from {(φ1, y1), . . . , (φN, yN)}. Since we are counting the number of queries to fw it is clear that in the worst possible case that the training vector that the perceptron makes a mistake on can be the last unique value sampled from this list. Thus the query complexity is Ω(N) classically. 4 Quantum version space perceptron The strategy for our quantum version space training algorithm is to pose the problem of determining a separating hyperplane as search. Specifically, the idea is to first generate K sample hyperplanes w1, . . . , wK from a spherical Gaussian distribution N(0, 11). Given a large enough K, we are guaranteed to have at least one hyperplane amongst the samples that would lie in the version space and perfectly separate the data. As discussed earlier Grover’s algorithm can provide quadratic speedup over the classical search consequently the efficiency of the algorithm is determined by K. Theorem 2 provides an insight on how to determine this number of hyperplanes to be sampled. Theorem 2. Given a training set that consists of d-dimensional unit vectors Φ1, . . . , ΦN with labels y1, . . . , yN that are separated by a margin of γ in feature space, then a D-dimensional vector w sampled from N(0, 11) perfectly separates the data with probability Θ(γ). The proof of this theorem is provided in the supplementary material. The consequence of Theorem 2 stated below is that the expected number of samples K, required such that a separating hyperplane exists in the set, only needs to scale as O( 1 γ ). This is remarkable because, similar to Novikoff’s theorem [16], the number of samples needed does not scale with D. Thus Theorem 2 implies that if amplitude amplification is used to boost the probability of finding a vector in the version space then the resulting quantum algorithm will need only O( 1 √γ ) quantum steps on average. Next we show how to use Grover’s algorithm to search for a hyperplane that lies in the version space. Let us take K = 2ℓ, for positive integer ℓ. Then given w1, . . . , wK be the sampled hyperplanes, we represent W1, . . . , WK to be vectors that encode a binary representation of these random perceptron vectors. In analogy to Φ0, we also define W0 to be a vector that represents an empty data register. We define the unitary operator V to generate these weights given an address vector uj using the following V [uj ⊗W0] = [uj ⊗Wj]. (8) 6 In this context we can also think of the address vector, uj, as representing a seed for a pseudo–random number generator that yields perceptron weights Wj. Also let us define the classical analogue of V to be V c which obeys V c(j) = wj. Now using V (and applying the Hadamard transform [23]) we can prepare the following quantum state Ψ := 1 √ K K X k=1 uk ⊗Wk, (9) which corresponds to a uniform distribution over the randomly chosen w. Now that we have defined the initial state, Ψ, for Grover’s search we need to define an oracle that marks the vectors inside the version space. Let us define the operator ˆFφ,y via ˆFφ,y[uj ⊗W0] = (−1)1+fwj (φ,y)[uj ⊗W0]. (10) This unitary operation looks at an address vector, uj, computes the corresponding perceptron model Wj, flips the sign of any component of the quantum state vector that is in the half space in version space specified by φ and then uncomputes Wj. This process can be realized using a quantum subroutine that computes fw, an application of V and V † and also the application of a conditional phase gate (which is a fundamental quantum operation that is usually denoted Z) [23]. The oracle ˆFφ,y does not allow us to directly use Grover’s search to rotate a quantum state vector that is outside the version space towards the version space boundary because it effectively only checks one of the half–space inequalities that define the version space. It can, however, be used to build an operation, ˆG, that reflects about the version space: ˆG[uj ⊗W0] = (−1)1+(fwj (φ1,y1)∨···∨fwj (φN,yN))[uj ⊗W0]. (11) The operation ˆG can be implemented using 2N applications of ˆFφ as well as a sequence of O(N) elementary quantum gates, hence we cost a query to ˆG as O(N) queries to ˆFφ,y. We use these components in our version space training algorithm to, in effect, amplify the margin between the two classes from γ to √γ. We give the asymptotic scaling of this algorithm in the following theorem. Theorem 3. Given a training set that consists of unit vectors Φ1, . . . , ΦN that are separated by a margin of γ in feature space, the number of queries to ˆFφ,y needed to infer a perceptron model with probability at least 1 −ϵ, w, such that w is in the version space using a quantum computer is Nquant where Nquant ∈O N √γ log3/2 1 ϵ . Proof. The proof of the theorem follows directly from bounds on K and the validity of our version space training algorithm. It is clear from previous discussions that the algorithm carries out Grover’s search, but instead of searching for a φ that is misclassified it instead searches for a w in version space. Its validity therefore follows by following the exact same steps followed in the proof of Lemma 2 but with N = K. However, since the algorithm need is not repeated 1/γ2 times in this context we can replace γ with 1 in the proof. Thus if we wish to have a probability of failure of at most ϵ′ then the number of queries made to ˆG is in O( √ K log(1/ϵ′)). This also guarantees that if any of the K vectors are in the version space then the probability of failing to find that vector is at most ϵ′. Next since one query to ˆG is costed at N queries to ˆFφ,y the query complexity (in units of queries to ˆFφ,y) becomes O(N √ K log(1/ϵ′)). The only thing that then remains is to bound the value of K needed. The probability of finding a vector in the version space is Θ(γ) from Theorem 2. This means that there exists α > 0 such that the probability of failing to find a vector in the version space K times is at most (1 −αγ)K ≤e−αγK. Thus this probability is at most δ for K ∈Ω 1 γ log(1/δ) . It then suffices to pick K ∈Θ(log(1/δ)/γ) for the algorithm. The union bound implies that the probability that either none of the vectors lie in the version space or that Grover’s search failing to find such an element is at most ϵ′ + δ ≤ϵ. Thus it suffices to pick 7 ϵ′ ∈Θ(ϵ) and δ ∈Θ(ϵ) to ensure that the total probability is at most ϵ. Therefore the total number of queries made to ˆFφ,y is in O(N log3/2(1/ϵ)/√γ) as claimed. The classical algorithm discussed previously has complexity O(N log(1/ϵ)/γ), which follows from the fact from Theorem 2 that K ∈Θ(log(1/ϵ)/γ) suffices to make the probability of not drawing an element of the version space at most ϵ. This demonstrates a quantum advantage if 1 γ ≫log(1/ϵ), and illustrates that quantum computing can be used to boost the effective margins of the training data. Quantum models of perceptrons therefore not only provide advantages in terms of the number of vectors that need to be queried in the training process, they also can make the perceptron much more perceptive by making training less sensitive to small margins. These performance improvements can also be viewed as mistake bounds for the version space perceptron. The inner loop in the version space algorithm attempts to sample from the version space and then once it draws a sample it tests it against the training vectors to see if it errs on any example. Since the inner loop is repeated O( √ K log(1/ϵ)) times, the maximum number of misclassified vectors that arises from this training process is from Theorem 2 O( 1 √γ log3/2(1/ϵ)) which, for constant ϵ, constitutes a quartic improvement over the standard mistake bound of 1/γ2 [16]. 5 Conclusion We have provided two distinct ways to look at quantum perceptron training that each afford different speedups relative to the other. The first provides a quadratic speedup with respect to the size of the training data. We further show that this algorithm is asymptotically optimal in that if a super–quadratic speedup were possible then it would violate known lower bounds for quantum searching. The second provides a quadratic reduction in the scaling of the training time (as measured by the number of interactions with the training data) with the margin between the two classes. This latter result is especially interesting because it constitutes a quartic speedup relative to the typical perceptron training bounds that are usually seen in the literature. Perhaps the most significant feature of our work is that it demonstrates that quantum computing can provide provable speedups for perceptron training, which is a foundational machine learning method. While our work gives two possible ways of viewing the perceptron model through the lens of quantum computing, other quantum variants of the perceptron model may exist. Seeking new models for perceptron learning that deviate from these classical approaches may not only provide a more complete understanding of what form learning takes within quantum systems, but also may lead to richer classes of quantum models that have no classical analogue and are not efficiently simulatable on classical hardware. Such models may not only revolutionize quantum learning but also lead to a deeper understanding of the challenges and opportunities that the laws of physics place on our ability to learn. References [1] M Lewenstein. Quantum perceptrons. Journal of Modern Optics, 41(12):2491–2501, 1994. [2] Esma A¨ımeur, Gilles Brassard, and S´ebastien Gambs. Machine learning in a quantum world. In Advances in artificial intelligence, pages 431–442. Springer, 2006. [3] Seth Lloyd, Masoud Mohseni, and Patrick Rebentrost. Quantum algorithms for supervised and unsupervised machine learning. arXiv preprint arXiv:1307.0411, 2013. [4] Nathan Wiebe, Ashish Kapoor, and Krysta Svore. Quantum nearest-neighbor algorithms for machine learning. Quantum Information and Computation, 15:318–358, 2015. [5] Seth Lloyd, Masoud Mohseni, and Patrick Rebentrost. Quantum principal component analysis. Nature Physics, 10(9):631–633, 2014. [6] Patrick Rebentrost, Masoud Mohseni, and Seth Lloyd. Quantum support vector machine for big data classification. Physical review letters, 113(13):130503, 2014. [7] Nathan Wiebe and Christopher Granade. Can small quantum systems learn? arXiv preprint arXiv:1512.03145, 2015. 8 [8] Nathan Wiebe, Ashish Kapoor, and Krysta M Svore. Quantum deep learning. arXiv preprint arXiv:1412.3489, 2014. [9] Mohammad H Amin, Evgeny Andriyash, Jason Rolfe, Bohdan Kulchytskyy, and Roger Melko. Quantum boltzmann machine. arXiv preprint arXiv:1601.02036, 2016. [10] Silvano Garnerone, Paolo Zanardi, and Daniel A Lidar. Adiabatic quantum algorithm for search engine ranking. Physical review letters, 108(23):230506, 2012. [11] Frank Rosenblatt. The perceptron: a probabilistic model for information storage and organization in the brain. Psychological review, 65(6):386, 1958. [12] Johan AK Suykens and Joos Vandewalle. Least squares support vector machine classifiers. Neural processing letters, 9(3):293–300, 1999. [13] Yaoyong Li, Hugo Zaragoza, Ralf Herbrich, John Shawe-Taylor, and Jaz Kandola. The perceptron algorithm with uneven margins. In ICML, volume 2, pages 379–386, 2002. [14] Claudio Gentile. A new approximate maximal margin classification algorithm. The Journal of Machine Learning Research, 2:213–242, 2002. [15] Shai Shalev-Shwartz and Yoram Singer. A new perspective on an old perceptron algorithm. In Learning Theory, pages 264–278. Springer, 2005. [16] Albert BJ Novikoff. On convergence proofs for perceptrons. Technical report, DTIC Document, 1963. [17] Yoav Freund and Robert E Schapire. Large margin classification using the perceptron algorithm. Machine learning, 37(3):277–296, 1999. [18] Thomas P Minka. A family of algorithms for approximate Bayesian inference. PhD thesis, Massachusetts Institute of Technology, 2001. [19] Ralf Herbrich, Thore Graepel, and Colin Campbell. Bayes point machines: Estimating the bayes point in kernel space. In IJCAI Workshop SVMs, pages 23–27, 1999. [20] Lov K Grover. A fast quantum mechanical algorithm for database search. In Proceedings of the twenty-eighth annual ACM symposium on Theory of computing, pages 212–219. ACM, 1996. [21] Michel Boyer, Gilles Brassard, Peter Høyer, and Alain Tapp. Tight bounds on quantum searching. arXiv preprint quant-ph/9605034, 1996. [22] Gilles Brassard, Peter Hoyer, Michele Mosca, and Alain Tapp. Quantum amplitude amplification and estimation. Contemporary Mathematics, 305:53–74, 2002. [23] Michael A Nielsen and Isaac L Chuang. Quantum computation and quantum information. Cambridge university press, 2010. 9 | 2016 | 478 |
6,414 | Direct Feedback Alignment Provides Learning in Deep Neural Networks Arild Nøkland Trondheim, Norway arild.nokland@gmail.com Abstract Artificial neural networks are most commonly trained with the back-propagation algorithm, where the gradient for learning is provided by back-propagating the error, layer by layer, from the output layer to the hidden layers. A recently discovered method called feedback-alignment shows that the weights used for propagating the error backward don’t have to be symmetric with the weights used for propagation the activation forward. In fact, random feedback weights work evenly well, because the network learns how to make the feedback useful. In this work, the feedback alignment principle is used for training hidden layers more independently from the rest of the network, and from a zero initial condition. The error is propagated through fixed random feedback connections directly from the output layer to each hidden layer. This simple method is able to achieve zero training error even in convolutional networks and very deep networks, completely without error backpropagation. The method is a step towards biologically plausible machine learning because the error signal is almost local, and no symmetric or reciprocal weights are required. Experiments show that the test performance on MNIST and CIFAR is almost as good as those obtained with back-propagation for fully connected networks. If combined with dropout, the method achieves 1.45% error on the permutation invariant MNIST task. 1 Introduction For supervised learning, the back-propagation algorithm (BP), see [2], has achieved great success in training deep neural networks. As today, this method has few real competitors due to its simplicity and proven performance, although some alternatives do exist. Boltzmann machine learning in different variants are biologically inspired methods for training neural networks, see [6], [10] and [5]. The methods use only local available signals for adjusting the weights. These methods can be combined with BP fine-tuning to obtain good discriminative performance. Contrastive Hebbian Learning (CHL), is similar to Boltzmann Machine learning, but can be used in deterministic feed-forward networks. In the case of weak symmetric feedback-connections it resembles BP [16]. Recently, target-propagation (TP) was introduced as an biologically plausible training method, where each layer is trained to reconstruct the layer below [7]. This method does not require symmetric weights and propagates target values instead of gradients backward. A novel training principle called feedback-alignment (FA) was recently introduced [9]. The authors show that the feedback weights used to back-propagate the gradient do not have to be symmetric with the feed-forward weights. The network learns how to use fixed random feedback weights in order to reduce the error. Essentially, the network learns how to learn, and that is a really puzzling result. 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. Back-propagation with asymmetric weights was also explored in [8]. One of the conclusions from this work is that the weight symmetry constraint can be significantly relaxed while still retaining strong performance. The back-propagation algorithm is not biologically plausible for several reasons. First, it requires symmetric weights. Second, it requires separate phases for inference and learning. Third, the learning signals are not local, but have to be propagated backward, layer-by-layer, from the output units. This requires that the error derivative has to be transported as a second signal through the network. To transport this signal, the derivative of the non-linearities have to be known. All mentioned methods require the error to travel backward through reciprocal connections. This is biologically plausible in the sense that cortical areas are known to be reciprocally connected [3]. The question is how an error signal is relayed through an area to reach more distant areas. For BP and FA the error signal is represented as a second signal in the neurons participating in the forward pass. For TP the error is represented as a change in the activation in the same neurons. Consider the possibility that the error in the relay layer is represented by neurons not participating in the forward pass. For lower layers, this implies that the feedback path becomes disconnected from the forward path, and the layer is no longer reciprocally connected to the layer above. The question arise whether a neuron can receive a teaching signal also through disconnected feedback paths. This work shows experimentally that directly connected feedback paths from the output layer to neurons earlier in the pathway is sufficient to enable error-driven learning in a deep network. The requirements are that the feedback is random and the whole network is adapted. The concept is quite different from back-propagation, but the result is very similar. Both methods seem to produce features that makes classification easier for the layers above. Figure 1c) and d) show the novel feedback path configurations that is further explored in this work. The methods are based on the feedback alignment principle and is named "direct feedback-alignment" (DFA) and "indirect feedback-alignment" (IFA). Figure 1: Overview of different error transportation configurations. Grey arrows indicate activation paths and black arrows indicate error paths. Weights that are adapted during learning are denoted as Wi, and weights that are fixed and random are denoted as Bi. a) Back-propagation. b) Feedbackalignment. c) Direct feedback-alignment. d) Indirect feedback-alignment. 2 Method Let (x, y) be mini-batches of input-output vectors that we want the network to learn. For simplicity, assume that the network has only two hidden layers as in Figure 1, and that the target output y is scaled between 0 and 1. Let the rows in Wi denote the weights connecting the layer below to a unit in hidden layer i, and let bi be a column vector with biases for the units in hidden layer i. The activations in the network are then calculated as a1 = W1x + b1, h1 = f(a1) (1) a2 = W2h1 + b2, h2 = f(a2) (2) 2 ay = W3h2 + b3, ˆy = fy(ay) (3) where f() is the non-linearity used in hidden layers and fy() the non-linearity used in the output layer. If we choose a logistic activation function in the output layer and a binary cross-entropy loss function, the loss for a mini-batch with size N and the gradient at the output layer e are calculated as J = −1 N X m,n ymn log ˆymn + (1 −ymn) log(1 −ˆymn) (4) e = δay = ∂J ∂ay = ˆy −y (5) where m and n are output unit and mini-batch indexes. For the BP, the gradients for hidden layers are calculated as δa2 = ∂J ∂a2 = (W T 3 e) ⊙f ′(a2), δa1 = ∂J ∂a1 = (W T 2 δa2) ⊙f ′(a1) (6) where ⊙is an element-wise multiplication operator and f ′() is the derivative of the non-linearity. This gradient is also called steepest descent, because it directly minimizes the loss function given the linearized version of the network. For FA, the hidden layer update directions are calculated as δa2 = (B2e) ⊙f ′(a2), δa1 = (B1δa2) ⊙f ′(a1) (7) where Bi is a fixed random weight matrix with appropriate dimension. For DFA, the hidden layer update directions are calculated as δa2 = (B2e) ⊙f ′(a2), δa1 = (B1e) ⊙f ′(a1) (8) where Bi is a fixed random weight matrix with appropriate dimension. If all hidden layers have the same number of neurons, Bi can be chosen identical for all hidden layers. For IFA, the hidden layer update directions are calculated as δa2 = (W2δa1) ⊙f ′(a2), δa1 = (B1e) ⊙f ′(a1) (9) where B1 is a fixed random weight matrix with appropriate dimension. Ignoring the learning rate, the weight updates for all methods are calculated as δW1 = −δa1xT , δW2 = −δa2hT 1 , δW3 = −ehT 2 (10) 3 Theoretical results BP provides a gradient that points in the direction of steepest descent in the loss function landscape. FA provides a different update direction, but experimental results indicate that the method is able to reduce the error to zero in networks with non-linear hidden units. This is surprising because the principle is distinct different from steepest descent. For BP, the feedback weights are the transpose of the forward weights. For FA the feedback weights are fixed, but if the forward weights are adapted, they will approximately align with the pseudoinverse of the feedback weights in order to make the feedback useful [9]. The feedback-alignment paper [9] proves that fixed random feedback asymptotically reduces the error to zero. The conditions for this to happen are freely restated in the following. 1) The network is linear with one hidden layer. 2) The input data have zero mean and standard deviation one. 3) The feedback matrix B satisfies B+B = I where B+ is the Moore-Penrose pseudo-inverse of B. 4) The forward weights are initialized to zero. 5) The output layer weights are adapted to minimize the error. Let’s call this novel principle the feedback alignment principle. It is not clear how the feedback alignment principle can be applied to a network with several nonlinear hidden layers. The experiments in [9] show that more layers can be added if the error is back-propagated layer-by-layer from the output. The following theorem points at a mechanism that can explain the feedback alignment principle. The mechanism explains how an asymmetric feedback path can provide learning by aligning the back-propagated and forward propagated gradients with it’s own, under the assumption of constant update directions for each data point. 3 Theorem 1. Given 2 hidden layers k and k + 1 in a feed-forward neural network where k connects to k + 1. Let hk and hk+1 be the hidden layer activations. Let the functional dependency between the layers be hk+1 = f(ak+1), where ak+1 = Whk + b. Here W is a weight matrix, b is a bias vector and f() is a non-linearity. Let the layers be updated according to the non-zero update directions δhk and δhk+1 where δhk ∥δhk∥and δhk+1 ∥δhk+1∥are constant for each data point. The negative update directions will minimize the following layer-wise criterion K = Kk + Kk+1 = δhT k hk ∥δhk∥+ δhT k+1hk+1 ∥δhk+1∥ (11) Minimizing K will maximize the gradient maximizing the alignment criterion L = Lk + Lk+1 = δhT k ck ∥δhk∥+ δhT k+1ck+1 ∥δhk+1∥ (12) where ck = ∂hk+1 ∂hk δhk+1 = W T (δhk+1 ⊙f ′(ak+1)) (13) ck+1 = ∂hk+1 ∂hT k δhk = (Wδhk) ⊙f ′(ak+1) (14) If Lk > 0, then is −δhk a descending direction in order to minimize Kk+1. Proof. Let i be the any of the layers k or k + 1. The prescribed update −δhi is the steepest descent direction in order to minimize Ki because by using the product rule and the fact that any partial derivative of δhi ∥δhi∥is zero we get −∂Ki ∂hi = −∂ ∂hi δhT i hi ∥δhi∥ = −∂ ∂hi δhi ∥δhi∥ hi −∂hi ∂hi δhi ∥δhi∥= −0hi − δhi ∥δhi∥= −αiδhi (15) Here αi = 1 ∥δhi∥is a positive scalar because δhi is non-zero. Let δai be defined as δai = ∂hi ∂ai δhi = δhi ⊙f ′(ai) where ai is the input to layer i. Using the product rule again, the gradients maximizing Lk and Lk+1 are ∂Li ∂ci = ∂ ∂ci δhT i ci ∥δhi∥ = ∂ ∂ci δhi ∥δhi∥ ci + ∂ci ∂ci δhi ∥δhi∥= 0ci + δhi ∥δhi∥= αiδhi (16) ∂Lk+1 ∂W = ∂Lk+1 ∂ck+1 ∂ck+1 ∂W = αk+1(δhk+1 ⊙f ′(ak+1))δhT k = αk+1δak+1δhT k (17) ∂Lk ∂W = ∂ck ∂W T ∂Lk ∂cT k = (δhk+1 ⊙f ′(ak+1))αkδhT k = αkδak+1δhT k (18) Ignoring the magnitude of the gradients we have ∂L ∂W = ∂Lk ∂W = ∂Lk+1 ∂W . If we project hi onto δhi we can write hi = hT i δhi ∥δhi∥2 δhi + hi,res = αiKiδhi + hi,res. For W, the prescribed update is δW = −δhk+1 ∂hk+1 ∂W = −(δhk+1⊙f ′(ak+1))hT k = −δak+1hT k = −δak+1(αkKkδhk+hk,res)T = −αkKkδak+1δhT k −δak+1hT k,res = −Kk ∂Lk ∂W −δak+1hT k,res (19) We can indirectly maximize Lk and Lk+1 by maximizing the component of ∂Lk ∂W in δW by minimizing Kk. The gradient to minimize Kk is the prescribed update −δhk. Lk > 0 implies that the angle β between δhk and the back-propagated gradient ck is within 90◦of each other because cos(β) = cT k δhk ∥ck∥∥δhk∥= Lk ∥ck∥> 0 ⇒|β| < 90◦. Lk > 0 also implies that ck is non-zero and thus descending. Then δhk will point in a descending direction because a vector within 90◦of the steepest descending direction will also point in a descending direction. 4 It is important to note that the theorem doesn’t tell that the training will converge or reduce any error to zero, but if the fake gradient is successful in reducing K, then will this gradient also include a growing component that tries to increase the alignment criterion L. The theorem can be applied to the output layer and the last hidden layer in a neural network. To achieve error-driven learning, we have to close the feedback loop. Then we get the update directions δhk+1 = ∂J ∂ay = e and δhk = Gk(e) where Gk(e) is a feedback path connecting the output to the hidden layer. The prescribed update will directly minimize the loss J given hk. If Lk turns positive, the feedback will provide a update direction δhk = Gk(e) that reduces the same loss. The theorem can be applied successively to deeper layers. For each layer i, the weight matrix Wi is updated to minimize Ki+1 in the layer above, and at the same time indirectly make it’s own update direction δhi = Gi(e) useful. Theorem 1 suggests that a large class of asymmetric feedback paths can provide a descending gradient direction for a hidden layer, as long as on average Li > 0. Choosing feedback paths Gi(e), visiting every layer on it’s way backward, with weights fixed and random, gives us the FA method. Choosing direct feedback paths Gi(e) = Bie, with Bi fixed and random, gives us the DFA method. Choosing a direct feedback path G1(e) = B1e connecting to the first hidden layer, and then visiting every layer on it’s way forward, gives us the IFA method. The experimental section shows that learning is possible even with indirect feedback like this. Direct random feedback δhi = Gi(e) = Bie has the advantage that δhi is non-zero for all non-zero e. This is because a random matrix Bi will have full rank with a probability very close to 1. A non-zero δhi is a requirement in order to achieve Li > 0. Keeping the feedback static will ensure that this property is preserved during training. In addition, a static feedback can make it easier to maximize Li because the direction of δhi is more constant. If the cross-entropy loss is used, and the output target values are 0 or 1, then the sign of the error ej for a given sample j will not change. This means that the quantity Bi sign(ej) will be constant during training because both Bi and sign(ej) are constant. If the task is to classify, the quantity will in addition be constant for all samples within a class. Direct random feedback will also provide a update direction δhi with a magnitude that only varies with the magnitude of the error e. If the forward weights are initialized to zero, then will Li = 0 because the back-propagated error is zero. This seems like a good starting point when using asymmetric feedback because the first update steps have the possibility to quickly turn this quantity positive. A zero initial condition is however not a requirement for asymmetric feedback to work. One of the experiments will show that even when starting from a bad initial condition, direct random and static feedback is able to turn this quantity positive and reduce the training error to zero. For FA and BP, the hidden layer growth is bounded by the layers above. If the layers above saturate, the hidden layer update δhi becomes zero. For DFA, the hidden layer update δhi will be non-zero as long as the error e is non-zero. To limit the growth, a squashing non-linearity like hyperbolic tangent or logistic sigmoid seems appropriate. If we add a tanh non-linearity to the hidden layer, the hidden activation is bounded within [−1, 1]. With zero initial weights, hi will be zero for all data points. The tanh non-linearity will not limit the initial growth in any direction. The experimental results indicate that this non-linearity is well suited together with DFA. If the hyperbolic tangent non-linearity is used in the hidden layer, the forward weights can be initialized to zero. The rectified linear activation function (ReLU) will not work with zero initial weights because the error derivative for such a unit is zero when the bias and incoming weights are all zero. 4 Experimental results To investigate if DFA learns useful features in the hidden layers, a 3x400 tanh network was trained on MNIST with both BP and DFA. The input test images and resulting features were visualized using t-SNE [15], see Figure 3. Both methods learns features that makes it easier to discriminate between the classes. At the third hidden layer, the clusters are well separated, except for some stray points. The visible improvement in separation from input to first hidden layer indicates that error DFA is able to learn useful features also in deeper hidden layers. 5 Figure 2: Left: Error curves for a network pre-trained with a frozen first hidden layer. Right: Error curves for normal training of a 2x800 tanh network on MNIST. Figure 3: t-SNE visualization of MNIST input and features. Different colors correspond to different classes. The top row shows features obtained with BP, the bottom row shows features obtained with DFA. From left to right: input images, first hidden layer features, second hidden layer features and third hidden layer features. Furthermore, another experiment was performed to see if error DFA is able to learn useful hidden representations in deeper layers. A 3x50 tanh network was trained on MNIST. The first hidden layer was fixed to random weights, but the 2 hidden layers above were trained with BP for 50 epochs. At this point, the training error was about 5%. Then, the first hidden layer was unfreezed and training continued with BP. The training error decreased to 0% in about 50 epochs. The last step was repeated, but this time the unfreezed layer was trained with DFA. As expected because of different update directions, the error first increased, then decreased to 0% after about 50 epochs. The error curves are presented in Figure2(Left). Even though the update direction provided by DFA is different from the back-propagated gradient, the resulting hidden representation reduces the error in a similar way. Several feed-forward networks were trained on MNIST and CIFAR to compare the performance of DFA with FA and BP. The experiments were performed with the binary cross-entropy loss and optimized with RMSprop [14]. For the MNIST dropout experiments, learning rate with decay and training time was chosen based on a validation set. For all other experiments, the learning rate was roughly optimized for BP and then used for all methods. The learning rate was constant for each dataset. Training was stopped when training error reached 0.01% or the number of epochs reached 300. A mini-batch size of 64 was used. No momentum or weight decay was used. The input data was scaled to be between 0 and 1, but for the convolutional networks, the data was whitened. For FA and DFA, the weights and biases were initialized to zero, except for the ReLU networks. For BP and/or ReLU, the initial weights and biases were sampled from a uniform distribution in the range 6 [−1/√fanin, 1/√fanin]. The random feedback weights were sampled from a uniform distribution in the range [−1/√fanout, 1/√fanout]. MODEL BP FA DFA 7x240 Tanh 2.16 ± 0.13% 2.20 ± 0.13% (0.02%) 2.32 ± 0.15% (0.03%) 100x240 Tanh 3.92 ± 0.09% (0.12%) 1x800 Tanh 1.59 ± 0.04% 1.68 ± 0.05% 1.68 ± 0.05% 2x800 Tanh 1.60 ± 0.06% 1.64 ± 0.03% 1.74 ± 0.08% 3x800 Tanh 1.75 ± 0.05% 1.66 ± 0.09% 1.70 ± 0.04% 4x800 Tanh 1.92 ± 0.11% 1.70 ± 0.04% 1.83 ± 0.07% (0.02%) 2x800 Logistic 1.67 ± 0.03% 1.82 ± 0.10% 1.75 ± 0.04% 2x800 ReLU 1.48 ± 0.06% 1.74 ± 0.10% 1.70 ± 0.06% 2x800 Tanh + DO 1.26 ± 0.03% (0.18%) 1.53 ± 0.03% (0.18%) 1.45 ± 0.07% (0.24%) 2x800 Tanh + ADV 1.01 ± 0.08% 1.14 ± 0.03% 1.02 ± 0.05% (0.12%) Table 1: MNIST test error for back-propagation (BP), feedback-alignment (FA) and direct feedbackalignment (DFA). Training error in brackets when higher than 0.01%. Empty fields indicate no convergence. The results on MNIST are summarized in Table 1. For adversarial regularization (ADV), the networks were trained on adversarial examples generated by the "fast-sign-method" [4]. For dropout regularization (DO) [12], a dropout probability of 0.1 was used in the input layer and 0.5 elsewhere. For the 7x240 network, target propagation achieved an error of 1.94% [7]. The results for all three methods are very similar. Only DFA was able to train the deepest network with the simple initialization used. The best result for DFA matches the best result for BP. MODEL BP FA DFA 1x1000 Tanh 45.1 ± 0.7% (2.5%) 46.4 ± 0.4% (3.2%) 46.4 ± 0.4% (3.2%) 3x1000 Tanh 45.1 ± 0.3% (0.2%) 47.0 ± 2.2% (0.3%) 47.4 ± 0.8% (2.3%) 3x1000 Tanh + DO 42.2 ± 0.2% (36.7%) 46.9 ± 0.3% (48.9%) 42.9 ± 0.2% (37.6%) CONV Tanh 22.5 ± 0.4% 27.1 ± 0.8% (0.9%) 26.9 ± 0.5% (0.2%) Table 2: CIFAR-10 test error for back-propagation (BP), feedback-alignment (FA) and direct feedbackalignment (DFA). Training error in brackets when higher than 0.1%. The results on CIFAR-10 are summarized in Table 2. For the convolutional network the error was injected after the max-pooling layers. The model was identical to the one used in the dropout paper [12], except for the non-linearity. For the 3x1000 network, target propagation achieved an error of 49.29% [7]. For the dropout experiment, the gap between BP and DFA is only 0.7%. FA does not seem to improve with dropout. For the convolutional network, DFA and FA are worse than BP. MODEL BP FA DFA 1x1000 Tanh 71.7 ± 0.2% (38.7%) 73.8 ± 0.3% (37.5%) 73.8 ± 0.3% (37.5%) 3x1000 Tanh 72.0 ± 0.3% (0.2%) 75.3 ± 0.1% (0.5%) 75.9 ± 0.2% (3.1%) 3x1000 Tanh + DO 69.8 ± 0.1% (66.8%) 75.3 ± 0.2% (77.2%) 73.1 ± 0.1% (69.8%) CONV Tanh 51.7 ± 0.2% 60.5 ± 0.3% 59.0 ± 0.3% Table 3: CIFAR-100 test error for back-propagation (BP), feedback-alignment (FA) and direct feedback-alignment (DFA). Training error in brackets when higher than 0.1%. The results on CIFAR-100 are summarized in Table 3. DFA improves with dropout, while FA does not. For the convolutional network, DFA and FA are worse than BP. The above experiments were performed to verify the DFA method. The feedback loops are the shortest possible, but other loops can also provide learning. An experiment was performed on MNIST 7 to see if a single feedback loop like in Figure 1d), was able to train a deep network with 4 hidden layers of 100 neurons each. The feedback was connected to the first hidden layer, and all hidden layers above were trained with the update direction forward-propagated through this loop. Starting from a random initialization, the training error reduced to 0%, and the test error reduced to 3.9%. 5 Discussion The experimental results indicate that DFA is able to fit the training data equally good as BP and FA. The performance on the test set is similar to FA but lagging a little behind BP. For the convolutional network, BP is clearly the best performer. Adding regularization seems to help more for DFA than for FA. Only DFA was successful in training a network with 100 hidden layers. If proper weight initialization is used, BP is able to train very deep networks as well [13][11]. The reason why BP fails to converge is probably the very simple initialization scheme used here. Proper initialization might help FA in a similar way, but this was not investigated any further. The DFA training procedure has a lot in common with supervised layer-wise pre-training of a deep network, but with an important difference. If all layers are trained simultaneously, it is the error at the top of a deep network that drives the learning, not the error in a shallow pre-training network. If the network above a target hidden layer is not adapted, FA and DFA will not give an improvement in the loss. This is in contrast to BP that is able to decrease the error even in this case because the feedback depends on the weights and layers above. DFA demonstrates a novel application of the feedback alignment principle. The brain may or may not implement this kind of feedback, but it is a step towards better better understanding mechanisms that can provide error-driven learning in the brain. DFA shows that learning is possible in feedback loops where the forward and feedback paths are disconnected. This introduces a large flexibility in how the error signal might be transmitted. A neuron might receive it’s error signals via a post-synaptic neuron (BP,CHL), via a reciprocally connected neuron (FA,TP), directly from a pre-synaptic neuron (DFA), or indirectly from an error source located several synapses away earlier in the informational pathway (IFA). Disconnected feedback paths can lead to more biologically plausible machine learning. If the feedback signal is added to the hidden layers before the non-linearity, the derivative of the non-linearity does not have to be known. The learning rule becomes local because the weight update only depends on the pre-synaptic activity and the temporal derivative of the post-synaptic activity. Learning is not a separate phase, but performed at the end of an extended forward pass. The error signal is not a second signal in the neurons participating in the forward pass, but a separate signal relayed by other neurons. The local update rule can be linked to Spike-Timing-Dependent Plasticity (STDP) believed to govern synaptic weight updates in the brain, see [1]. Disconnected feedback paths have great similarities with controllers used in dynamical control loops. The purpose of the feedback is to provide a change in the state that reduces the output error. For a dynamical control loop, the change is added to the state and propagated forward to the output. For a neural network, the change is used to update the weights. 6 Conclusion A biologically plausible training method based on the feedback alignment principle is presented for training neural networks with error feedback rather than error back-propagation. In this method, neither symmetric weights nor reciprocal connections are required. The error paths are short and enables training of very deep networks. The training signals are local or available at most one synapse away. No weight initialization is required. The method was able to fit the training set on all experiments performed on MNIST, Cifar-10 and Cifar-100. The performance on the test sets lags a little behind back-propagation. Most importantly, this work suggests that the restriction enforced by back-propagation and feedbackalignment, that the backward pass have to visit every neuron from the forward pass, can be discarded. Learning is possible even when the feedback path is disconnected from the forward path. 8 References [1] Yoshua Bengio, Dong-Hyun Lee, Jörg Bornschein, Thomas Mesnard, and Zhouhan Lin. Towards biologically plausible deep learning. CoRR, abs/1502.04156, 2015. [2] R. J. Williams D. E. Rumelhart, G. E. Hinton. Learning internal representations by error propagation. Nature, 323:533–536, 1986. [3] Charles D Gilbert and Wu Li. Top-down influences on visual processing. Nature Reviews Neuroscience, 14(5):350–363, 2013. [4] Ian J. Goodfellow, Jonathon Shlens, and Christian Szegedy. Explaining and harnessing adversarial examples. CoRR, abs/1412.6572, 2014. [5] Geoffrey E. Hinton, Simon Osindero, and Yee Whye Teh. A fast learning algorithm for deep belief nets. Neural Computation, 18(7):1527–1554, 2006. [6] Geoffrey E. Hinton and Terrence J. Sejnowski. Optimal Perceptual Inference. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, 1983. [7] Dong-Hyun Lee, Saizheng Zhang, Asja Fischer, and Yoshua Bengio. Difference target propagation. In ECML/PKDD (1), Machine Learning and Knowledge Discovery in Databases, pages 498–515. Springer International Publishing, 2015. [8] Qianli Liao, Joel Z. Leibo, and Tomaso A. Poggio. How important is weight symmetry in backpropagation? CoRR, abs/1510.05067, 2015. [9] Timothy P. Lillicrap, Daniel Cownden, Douglas B. Tweed, and Colin J. Akerman. Random feedback weights support learning in deep neural networks. CoRR, abs/1411.0247, 2014. [10] Ruslan Salakhutdinov and Geoffrey E. Hinton. Deep boltzmann machines. In Proceedings of the Twelfth International Conference on Artificial Intelligence and Statistics, AISTATS 2009, volume 5 of JMLR Proceedings, pages 448–455. JMLR.org, 2009. [11] Andrew M. Saxe, James L. McClelland, and Surya Ganguli. Exact solutions to the nonlinear dynamics of learning in deep linear neural networks. CoRR, abs/1312.6120, 2013. [12] Nitish Srivastava, Geoffrey E. Hinton, Alex Krizhevsky, Ilya Sutskever, and Ruslan Salakhutdinov. Dropout: a simple way to prevent neural networks from overfitting. Journal of Machine Learning Research, 15(1):1929–1958, 2014. [13] David Sussillo. Random walks: Training very deep nonlinear feed-forward networks with smart initialization. CoRR, abs/1412.6558, 2014. [14] T. Tieleman and G. Hinton. Lecture 6.5-rmsprop: Divide the gradient by a running average of its recent magnitude. COURSERA: Neural Networks for Machine Learning 4, 2012. [15] L.J.P. van der Maaten and G.E. Hinton. Visualizing high-dimensional data using t-sne. Journal of Machine Learning Research, 9:2579–2605, 2008. [16] Xiaohui Xie and H. Sebastian Seung. Equivalence of backpropagation and contrastive hebbian learning in a layered network. Neural Computation, 15(2):441–454, 2003. 9 | 2016 | 479 |
6,415 | Active Nearest-Neighbor Learning in Metric Spaces Aryeh Kontorovich Department of Computer Science Ben-Gurion University of the Negev Beer Sheva 8499000, Israel Sivan Sabato Department of Computer Science Ben-Gurion University of the Negev Beer Sheva 8499000, Israel Ruth Urner Max Planck Institute for Intelligent Systems Department for Empirical Inference Tübingen 72076, Germany Abstract We propose a pool-based non-parametric active learning algorithm for general metric spaces, called MArgin Regularized Metric Active Nearest Neighbor (MARMANN), which outputs a nearest-neighbor classifier. We give prediction error guarantees that depend on the noisy-margin properties of the input sample, and are competitive with those obtained by previously proposed passive learners. We prove that the label complexity of MARMANN is significantly lower than that of any passive learner with similar error guarantees. Our algorithm is based on a generalized sample compression scheme and a new label-efficient active model-selection procedure. 1 Introduction In this paper we propose a non-parametric pool-based active learning algorithm for general metric spaces, which outputs a nearest-neighbor classifier. The algorithm is named MArgin Regularized Metric Active Nearest Neighbor (MARMANN). In pool-based active learning [McCallum and Nigam, 1998] a collection of random examples is provided, and the algorithm can interactively query an oracle to label some of the examples. The goal is good prediction accuracy, while keeping the label complexity (the number of queried labels) low. MARMANN receives a pool of unlabeled examples in a general metric space, and outputs a variant of the nearest-neighbor classifier. The algorithm obtains a prediction error guarantee that depends on a noisy-margin property of the input sample, and has a provably smaller label complexity than any passive learner with a similar guarantee. The theory of active learning has received considerable attention in the past decade [e.g., Dasgupta, 2004, Balcan et al., 2007, 2009, Hanneke, 2011, Hanneke and Yang, 2015]. Active learning has been mostly studied in a parametric setting (that is, learning with respect to a fixed hypothesis class with a bounded capacity). Various strategies have been analyzed for parametric classification [e.g., Dasgupta, 2004, Balcan et al., 2007, Gonen et al., 2013, Balcan et al., 2009, Hanneke, 2011, Awasthi et al., 2013].An active model selection procedure has also been developed for the parametric setting Balcan et al. [2010]. However, the number of labels used there depends quadratically on the number of possible model classes, which is prohibitive in our non-parametric setting. The potential benefits of active learning for non-parametric classification in metric spaces are less well understood. The paradigm of cluster-based active learning [Dasgupta and Hsu, 2008] has been shown to provide label savings under some distributional clusterability assumptions [Urner et al., 2013, Kpotufe et al., 2015]. Certain active learning methods for nearest neighbor classification are known to be Bayes consistent [Dasgupta, 2012], and an active querying rule, based solely on information in 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. the unlabeled data, has been shown to be beneficial for nearest neighbors under covariate shift [Berlind and Urner, 2015]. Castro and Nowak [2007] analyze minimax rates for a class of distributions in Euclidean space, characterized by decision boundary regularity and noise conditions. However, no active non-parametric strategy for general metric spaces, with label complexity guarantees for general distributions, has been proposed so far. Here, we provide the first such algorithm and guarantees. The passive nearest-neighbor classifier is popular among theorists and practitioners alike [Fix and Hodges, 1989, Cover and Hart, 1967, Stone, 1977, Kulkarni and Posner, 1995]. This paradigm is applicable in general metric spaces, and its simplicity is an attractive feature for both implementation and analysis. When appropriately regularized [e.g. Stone, 1977, Devroye and Györfi, 1985, von Luxburg and Bousquet, 2004, Gottlieb et al., 2010, Kontorovich and Weiss, 2015] this type of learner can be made Bayes consistent. Another desirable property of nearest-neighbor-based methods is their ability to generalize at a rate that scales with the intrinsic data dimension, which can be much lower than that of the ambient space [Kpotufe, 2011, Gottlieb et al., 2014a, 2016a, Chaudhuri and Dasgupta, 2014]. Furthermore, margin-based regularization makes nearest neighbors ideally suited for sample compression, which yields a compact representation, faster classification runtime, and improved generalization performance [Gottlieb et al., 2014b, Kontorovich and Weiss, 2015]. The resulting error guarantees can be stated in terms of the sample’s noisy-margin, which depends on the distances between differently-labeled examples in the input sample. Our contribution. We propose MARMANN, a non-parametric pool-based active learning algorithm that obtains an error guarantee competitive with that of a noisy-margin-based passive learner, but can provably use significantly fewer labels. This is the first non-parametric active learner for general metric spaces that achieves prediction error that is competitive with passive learning for general distributions, and provably improves label complexity. Our approach. Previous passive learning approaches to classification using nearest-neighbor rules under noisy-margin assumptions [Gottlieb et al., 2014b, 2016b] provide statistical guarantees using sample compression bounds [Graepel et al., 2005]. The finite-sample guarantees depend on the number of noisy labels relative to an optimal margin scale. A central challenge in the active setting is performing model selection (selecting the margin scale) with a low label complexity. A key insight that we exploit in this work is that by designing a new labeling scheme for the compression set, we can construct the compression set and estimate its error with label-efficient procedures. We obtain statistical guarantees for this approach using a generalized sample compression analysis. We derive a label-efficient (as well as computationally efficient) active model-selection procedure. This procedure finds a good scale by estimating the sample error for some scales, using a small number of active querying rounds. Crucially, unlike cross-validation, our model-selection procedure does not require a number of labels that depends on the worst possible scale, nor does it test many scales. This allows our label complexity bounds to be low, and to depend only on the final scale selected by the algorithm. Our error guarantee is a constant factor over the error guarantee of the passive learner of Gottlieb et al. [2016b]. An approach similar to Gottlieb et al. [2016b], proposed in Gottlieb et al. [2014a], has been shown to be Bayes consistent [Kontorovich and Weiss, 2015]. The Bayes-consistency of the passive version of our approach is the subject of ongoing work. Paper outline. We define the setting and notations in Section 2. In Section 3 we provide our main result, Theorem 3.2, giving error and label complexity guarantees for MARMANN. Section 4 shows how to set the nearest neighbor rule for a given scale, and Section 5 describes the model selection procedure. Some of the analysis is omitted due to lack of space. The full analysis is available at Kontorovich et al. [2016]. 2 Setting and notations We consider learning in a general metric space (X, ρ), where X is a set and ρ is the metric on X. Our problem setting is that of classification of the instance space X into some finite label set Y. Assume that there is some distribution D over X × Y, and let S ∼Dm be a labeled sample of size m, where m is an integer. Denote the sequence of unlabeled points in S by U(S). We sometimes treat S and U(S) as multisets, since the order is unimportant. The error of a classifier h : X →Y on D is denoted err(h, D) := P[h(X) ̸= Y ], where (X, Y ) ∼D. The empirical error on a labeled sample S instantiates to err(h, S) = 1 |S| P I[h(X) ̸= Y ]. A passive learner receives a labeled sample Sin as input. An active learner receives the unlabeled part of the sample Uin := U(Sin) as input, and 2 is allowed to adaptively select examples from Uin and request their label from Sin. When either learner terminates, it outputs a classifier ˆh : X →Y, with the goal of achieving a low err(ˆh, D). An additional goal of the active learner is to achieve a performance competitive with that of the passive learner, while querying considerably fewer labels. The diameter of a set A ⊆X is defined by diam(A) := supa,a′∈A ρ(a, a′). Denote the index of the closest point in U to x ∈X by κ(x, U) := argmini:xi∈U ρ(x, xi). We assume here and throughout this work that when there is more than one minimizer for ρ(x, xi), ties are broken arbitrarily (but in a consistent fashion). For a set Z ⊆X, denote κ(Z, U) := {κ(z, U) | z ∈Z}. Any labeled sample S = ((xi, yi))i∈[k] naturally induces the nearest-neighbor classifier hnn S : X →Y, via hnn S (x) := yκ(x,U(S)). For x ∈X, and t > 0, denote by ball(x, t) the (closed) ball of radius t around x: ball(x, t) := {x′ ∈X | ρ(x, x′) ≤t}. The doubling dimension, the effective dimension of the metric space, which controls generalization and runtime performance of nearest-neighbors [Kpotufe, 2011, Gottlieb et al., 2014a], is defined as follows. Let λ = λ(X) be the smallest number such that every ball in X can be covered by λ balls of half its radius, where all balls are centered at points of X. Formally, λ(X) := min{λ ∈N : ∀x ∈X, r > 0, ∃x1, . . . , xλ ∈X : ball(x, r) ⊆∪λ i=1ball(xi, r/2)}. Then the doubling dimension of X is defined by ddim(X) := log2 λ. In line with modern literature, we work in the low-dimension, big-sample regime, where the doubling dimension is assumed to be constant and hence sample complexity and algorithmic runtime may depend on it exponentially. This exponential dependence is unavoidable, even under margin assumptions, as previous analysis [Kpotufe, 2011, Gottlieb et al., 2014a] indicates. A set A ⊆X is t-separated if infa,a′∈A:a̸=a′ ρ(a, a′) ≥t. For A ⊆B ⊆X, the set A is a t-net of B if A is t-separated and B ⊆S a∈A ball(a, t). Constructing a minimum size t-net for a general set B is NP-hard [Gottlieb and Krauthgamer, 2010], however efficient procedures exist for constructing some t-net [Krauthgamer and Lee, 2004, Gottlieb et al., 2014b]. The size of any t-net is at most 2ddim(B) times the smallest possible size (see Kontorovich et al. [2016]). In addition, the size of any t-net is at most ⌈diam(B)/t⌉ddim(X)+1 [Krauthgamer and Lee, 2004]. Throughout the paper, we fix a deterministic procedure for constructing a t-net, and denote its output for a multiset U ⊆X by Net(U, t). Let Par(U, t) be a partition of X into regions induced by Net(U, t), that is: for Net(U, t) = {x1, . . . , xN}, define Par(U, t) := {P1, . . . , PN}, where Pi = {x ∈X | κ(x, Net(U, t)) = i}. For t > 0, denote N(t) := |Net(Uin, t)|. For a labeled multiset S ⊆X × Y and y ∈Y, denote Sy := {x | (x, y) ∈S}; in particular, U(S) = ∪y∈YSy. 3 Main results Non-parameteric binary classification admits performance guarantees that scale with the sample’s noisy-margin [von Luxburg and Bousquet, 2004, Gottlieb et al., 2010, 2016b]. We say that a labeled multiset S is (ν, t)-separated, for ν ∈[0, 1] and t > 0 (representing a margin t with noise ν), if one can remove a ν-fraction of the points in S, and in the resulting multiset, points with different labels are at least t-far from each other. Formally, S is (ν, t)-separated if there exists a subsample ˜S ⊆S such that |S \ ˜S| ≤ν|S| and ∀y1 ̸= y2 ∈Y, a ∈˜Sy1, b ∈˜Sy2, we have ρ(a, b) ≥t. For a given labeled sample S, denote by ν(t) the smallest value ν such that S is (ν, t)-separated. Gottlieb et al. [2016b] propose a passive learner with the following guarantees as a function of the separation of S. Setting α := m/(m −N), define the following form of a generalization bound: GB(ϵ, N, δ, m, k) := αϵ + 2 3 (N + 1) log(mk) + log( 1 δ ) m −N + 3 √ 2 s αϵ((N + 1) log(mk) + log( 1 δ )) m −N . Theorem 3.1 (Gottlieb et al. [2016b]). Let m be an integer, Y = {0, 1}, δ ∈(0, 1). There exists a passive learning algorithm that returns a nearest-neighbor classifier hnn Spas, where Spas ⊆Sin, such that, with probability 1 −δ, err(hnn Spas, D) ≤ min t>0:N (t)<m GB(ν(t), N(t), δ, m, 1). The passive algorithm of Gottlieb et al. [2016b] generates Spas of size approximately N(t) for the optimal scale t > 0 (found by searching over all scales), removing the |Sin|ν(t) points that 3 obstruct the t-separation between different labels in Sin, and then selecting a subset of the remaining labeled examples to form Spas, so that the examples are a t-net for Sin. We propose a different approach for generating a compression set for a nearest-neighbor rule. This approach, detailed in the following sections, does not require finding and removing all the obstructing points in Sin, and can be implemented in an active setting using a small number of labels. The resulting active learning algorithm, MARMANN, has an error guarantee competitive with that of the passive learner and a label complexity that can be significantly lower. Our main result is the following guarantee for MARMANN. Theorem 3.2. Let Sin ∼Dm, where m ≥max(6, |Y|), δ ∈(0, 1 4). Let ˆS be the output of MARMANN(Uin, δ), where ˆS ⊆X × Y, and let ˆN := | ˆS|. Let ˆh := hnn ˆS and ˆϵ := err(ˆh, Sin), and denote ˆG := GB(ˆϵ, ˆN, δ, m, 1). With a probability of 1−δ over Sin and randomness of MARMANN, err(ˆh, D) ≤2 ˆG ≤O min t>0:N (t)<m GB(ν(t), N(t), δ, m, 1) , and the number of labels from Sin requested by MARMANN is at most O log3(m δ ) 1 ˆG log( 1 ˆG ) + m ˆG . Here O(·) hides only universal numerical constants. To observe the advantages of MARMANN over a passive learner, consider a scenario in which the upper bound GB of Theorem 3.1, as well as the Bayes error of D, are of order Θ(1/√m). Then ˆG = Θ(1/√m) as well. Therefore, MARMANN obtains a prediction error guarantee of Θ(1/√m), similarly to the passive learner, but it uses only ˜Θ(√m) labels instead of m. Moreover, no learner that selects labels randomly from Sin can compete with MARMANN: In Kontorovich et al. [2016] we adapt an argument of Devroye et al. [1996] to show that for any passive learner that uses ˜Θ(√m) random labels from Sin, there exists a distribution D with the above properties, for which the prediction error of the passive learner in this case is ˜Ω(m−1/4), a decay rate which is almost quadratically slower than the O(1/√m) rate achieved by MARMANN. Thus, the guarantees of MARMANN cannot be matched by any passive learner. MARMANN operates as follows. First, a scale ˆt > 0 is selected, by calling ˆt ←SelectScale(δ), where SelectScale is our model selection procedure. SelectScale has access to Uin, and queries labels from Sin as necessary. It estimates the generalization error bound GB for several different scales, and executes a procedure similar to binary search to identify a good scale. The binary search keeps the number of estimations (and thus requested labels) small. Crucially, our estimation procedure is designed to prevent the search from spending a number of labels that depends on the net size of the smallest possible scale t, so that the total label complexity of MARMANN depends only on error of the selected ˆt. Second, the selected scale ˆt is used to generate the compression set by calling ˆS ←GenerateNNSet(ˆt, [N(ˆt)], δ), where GenerateNNSet is our compression set generation procedure. For clarity of presentation, we first introduce in Section 4 the procedure GenerateNNSet, which determines the compression set for a given scale, and then in Section 5, we describe how SelectScale chooses the appropriate scale. 4 Active nearest-neighbor at a given scale The passive learner of Gottlieb et al. [2014a, 2016b] generates a compression set by first finding and removing from Sin all points that obstruct (ν, t)-separation at a given scale t > 0. We propose below a different approach for generating a compression set, which seems more conducive to active learning: as we show below, it also generates a low-error nearest neighbor rule, just like the passive approach. At the same time, it allows us to estimate the error on many different scales using few label queries. A small technical difference, which will be evident below, is that in this new approach, examples in the compression set might have a different label than their original label in Sin. Standard sample compression analysis [e.g. Graepel et al., 2005] assumes that the classifier is determined by a small number of labeled examples from Sin. This does not allow the examples in the compression set to have a different label than their original label in Sin. Therefore, we require a slight generalization of previous compression analysis, which allows setting arbitrary labels for examples that are assigned to the compression set. The following theorem quantifies the effect of this change on generalization. 4 Theorem 4.1. Let m ≥|Y| be an integer, δ ∈(0, 1 4). Let Sin ∼Dm. With probability at least 1 −δ, if there exist N < m and S ⊆(X × Y)N such that U(S) ⊆Uin and ϵ := err(hnn S , Sin) ≤1 2, then err(hnn S , D) ≤GB(ϵ, N, δ, m, |Y|) ≤2GB(ϵ, N, 2δ, m, 1). The proof is similar to that of standard sample compression schemes. If the compression set includes only the original labels, the compression analysis of Gottlieb et al. [2016b] gives the bound GB(ϵ, N, δ, m, 1). Thus the effect of allowing the labels to change is only logarithmic in |Y|, and does not appreciably degrade the prediction error. We now describe the generation of the compression set for a given scale t > 0. Recall that ν(t) is the smallest value for which Sin is (ν, t)-separated. We define two compression sets. The first one, denoted Sa(t), represents an ideal compression set, which induces an empirical error of at most ν(t), but calculating it might require many labels. The second compression set, denoted ˆSa(t), represents an approximation to Sa(t), which can be constructed using a small number of labels, and induces a sample error of at most 4ν(t) with high probability. MARMANN constructs only ˆSa(t), while Sa(t) is defined for the sake of analysis only. We first define the ideal set Sa(t) := {(x1, y1), . . . , (xN, yN)}. The examples in Sa(t) are the points in Net(Uin, t/2), and the label of each example is the majority label out of the examples in Sin to which xi is closest. Formally, {x1, . . . , xN} := Net(Uin, t/2), and for i ∈[N], yi := argmaxy∈Y |Sy ∩Pi|, where Pi = {x ∈X | κ(x, Net(U, t/2)) = i} ∈Par(Uin, t/2). For i ∈[N], let Λi := Syi ∩Pi. The following lemma bounds the empirical error of hnn Sa(t). Lemma 4.2. For every t > 0, err(hnn Sa(t), Sin) ≤ν(t). Proof. Since Net(Uin, t/2) is a t/2-net, diam(P) ≤t for any P ∈Par(Uin, t/2). Let ˜S ⊆S be a subsample that witnesses the (ν(t), t)-separation of S, so that | ˜S| ≥m(1 −ν(t)), and for any two points (x, y), (x′, y′) ∈˜S, if ρ(x, x′) ≤t then y = y′. Denote ˜U := U( ˜S). Since maxP ∈Par(Uin,t/2) diam(P) ≤t, for any i ∈[N] all the points in ˜U ∩Pi must have the same label in ˜S. Therefore, ∃y ∈Y such that ˜U ∩Pi ⊆˜Sy ∩Pi. Hence | ˜U ∩Pi| ≤|Λi|. It follows m · err(hnn Sa(t), Sin) ≤|S| − X i∈[N] |Λi| ≤|S| − X i∈[N] | ˜U ∩Pi| = |S| −| ˜S| = m · ν(t). Dividing by m we get the statement of the theorem. Now, calculating Sa(t) requires knowing most of the labels in Sin. MARMANN constructs instead an approximation ˆSa(t), in which the examples are the points in Net(Uin, t/2) (so that U( ˆSa(t)) = U(Sa(t)) ), but the labels are determined using a bounded number of labels requested from Sin. The labels in ˆSa(t) are calculated by the simple procedure GenerateNNSet given in Alg. 1. The empirical error of the output of GenerateNNSet is bounded in Theorem 4.3 below.1 A technicality in Alg. 1 requires explanation: In MARMANN, the generation of ˆSa(t) will be split into several calls to GenerateNNSet, so that different calls determine the labels of different points in ˆSa(t). Therefore GenerateNNSet has an additional argument I, which specifies the indices of the points in Net(Uin, t/2) for which the labels should be returned this time. Crucially, if during the run of MARMANN, GenerateNNSet is called again for the same scale t and the same point in Net(Uin, t/2), then GenerateNNSet returns the same label that it returned before, rather than recalculating it using fresh labels from Sin. This guarantees that despite the randomness in GenerateNNSet, the full ˆSa(t) is well-defined within any single run of MARMANN, and is distributed like the output of GenerateNNSet(t, [N(t/2)], δ), which is convenient for the analysis. Theorem 4.3. Let ˆSa(t) be the output of GenerateNNSet(t, [N(t/2)], δ). With a probability at least 1 − δ 2m2 , we have err(hnn S , Sin) ≤4ν(t). Denote this event by E(t). 1In the case of binary labels (|Y| = 2), the problem of estimating Sa(t) can be formulated as a special case of the benign noise setting for parametric active learning, for which tight lower and upper bounds are provided in Hanneke and Yang [2015]. However, our case is both more general (as we allow multiclass labels) and more specific (as we are dealing with a specific hypothesis class). Thus we provide our own procedure and analysis. 5 Algorithm 1 GenerateNNSet(t, I, δ) input Scale t > 0, a target set I ⊆[N(t/2)], confidence δ ∈(0, 1). output A labeled set S ⊆X × Y of size |I| {x1, . . . , xN} ←Net(Uin, t/2), {P1, . . . , PN} ←Par(Uin, t/2), S ←() for i ∈I do if ˆyi has not already been calculated for Uin with this values of t then Draw Q := 18 log(2m3/δ) points uniformly at random from Pi and query their labels. Let ˆyi be the majority label observed in these Q queries. end if S ←S ∪{(xi, ˆyi)}. end for Output S Proof. By Lemma 4.2, err(hnn Sa(t), Sin) ≤ν(t). In Sa(t), the labels assigned to each point in Net(Uin, t/2) are the majority labels (based on Sin) of the points in the regions in Par(Uin, t/2). Denote the majority label for region Pi by yi := argmaxy∈Y |Sy ∩Pi|. We now compare these labels to the labels ˆyi assigned by Alg. 1. Let p(i) = |Λi|/|Pi| be the fraction of points in Pi which are labeled by the majority label yi. Let ˆp(i) be the fraction of labels equal to yi out of those queried by Alg. 1 in round i. Let β := 1/6. By Hoeffding’s inequality and union bounds, we have that with a probability of at least 1 −N(t/2) exp(−Q 18) ≥1 − δ 2m2 , we have maxi∈[N (t/2)] |ˆp(i) −p(i)| ≤β. Denote this “good” event by E′. We now prove that E′ ⇒E(t). Let J ⊆[N(t/2)] = {i | ˆp(i) > 1 2}. It can be easily seen that ˆyi = yi for all i ∈J. Therefore, for all x such that κ(x, U(Sa(t))) ∈J, hnn S (x) = hnn Sa(t)(x), and hence err(hnn S , Uin) ≤PX∼Uin[κ(X, U(Sa(t))) /∈J] + err(hnn Sa(t), Uin). The second term is at most ν(t), and it remains to bound the first term, on the condition that E′ holds. We have PX∼U[κ(X, U(Sa(t))) /∈J] = 1 m P i/∈J |Pi|. If E′ holds, then for any i /∈J, p(i) ≤1 2 +β, therefore |Pi| −|Λi| = (1 −p(i))|Pi| ≥( 1 2 −β)|Pi|. Therefore 1 −1 m X i/∈J |Λi| ≥1 m X i/∈J |Pi|( 1 2 −β) = PX∼U[κ(X, U(Sa(t))) /∈J]( 1 2 −β). On the other hand, as in the proof of Lemma 4.2, 1 −1 m P i∈[N (t/2)] |Λi| ≤ν(t). Thus, under E′, PX∼U[κ(X, S) /∈J] ≤ ν(t) 1 2 −β = 3ν(t). It follows that under E′, err(hnn S , Uin) ≤4ν(t). 5 Model Selection We now show how to select the scale ˆt that will be used to generate the output nearest-neighbor rule. The main challenge is to do this with a low label complexity: Generating the full classification rule for scale t requires a number of labels that depends on N(t), which might be very large. We would like the label complexity of MARMANN to depend only on N(ˆt) (where ˆt is the selected scale), which is of the order m ˆG. Therefore, during model selection we can only invest a bounded number of labels in each tested scale. In addition, to keep the label complexity low, we cannot test all scales. For t > 0, let ˆSa(t) be the model that MARMANN would generate if the selected scale were set to t. Our model selection procedure performs a search, similar to binary search, over the possible scales. For each tested scale t, the procedure estimates ϵ(t) := err(hnn ˆSa(t), S) within a certain accuracy, using an estimation procedure we call EstimateErr. EstimateErr outputs an estimate ˆϵ(t) of ϵ(t), up to a given accuracy θ > 0, using labels requested from Sin. It draws random examples from Sin, asks for their label, and calls GenerateNNSet (which also might request labels) to find the prediction error of hnn ˆSa(t) on these random examples. The estimate ˆϵ(t) is set to this prediction error. The number of random examples drawn by EstimateErr is determined based on the accuracy θ, using empirical Bernstein bounds [Maurer and Pontil, 2009]. Theorem 5.1 gives a guarantee for the accuracy and label complexity of EstimateErr. The full implementation of EstimateErr and the proof of Theorem 5.1 can be found in the long version of this paper Kontorovich et al. [2016]. 6 Theorem 5.1. Let t, θ > 0 and δ ∈(0, 1), and let ˆϵ(t) ←EstimateErr(t, θ, δ). Let Q be as defined in Alg. 1. The following properties (which we denote below by V (t)) hold with a probability of 1 − δ 2m2 over the randomness of EstimateErr (and conditioned on ˆSa(t)). 1. If ˆϵ(t) ≤θ, then ϵ(t) ≤5θ/4. Otherwise, 4ϵ(t) 5 ≤ˆϵ(t) ≤4ϵ(t) 3 . 2. EstimateErr requests at most 520(Q+1) log( 1040m2 δψ′ ) ψ′ labels, where ψ′ := max(θ, ϵ(t)). The model selection procedure SelectScale, given in Alg. 2, implements its search based on the guarantees in Theorem 5.1. First, we introduce some notation. Let G∗= mint GB(ν(t), N(t), δ, m, 1). We would like MARMANN to obtain a generalization guarantee that is competitive with G∗. Denote φ(t) := ((N(t) + 1) log(m) + log( 1 δ ))/m, and let G(ϵ, t) := ϵ + 2 3φ(t) + 3 √ 2 p ϵφ(t). Note that for all ϵ, t, GB(ϵ, N(t), δ, m, 1) = m m −N(t)G(ϵ, t). When referring to G(ν(t), t), G(ϵ(t), t), or G(ˆϵ(t), t) we omit the second t for brevity. Instead of directly optimizing GB, we will select a scale based on our estimate G(ˆϵ(t)) of G(ϵ(t)). Let Dist denote the set of pairwise distances in the unlabeled dataset Uin (note that |Dist| < m 2 ). We remove from Dist some distances, so that the remaining distances have a net size N(t) that is monotone non-increasing in t. We also remove values with a very large net size. Concretely, define Distmon := Dist \ {t | N(t) + 1 > m/2} \ {t | ∃t′ ∈Dist, t′ < t and N(t′) < N(t)}. Then for all t, t′ ∈Distmon such that t′ < t, we have N(t′) ≥N(t). The output of SelectScale is always a value in Distmon. The following lemma shows that it suffices to consider these scales. Lemma 5.2. Assume m ≥6 and let t∗ m ∈argmint∈Dist G(ν(t)). If G∗≤1/3 then t∗ m ∈Distmon. Proof. Assume by way of contradiction that t∗ m ∈Dist \ Distmon. First, since G(ν(t∗ m)) ≤G∗≤ 1/3 we have N (t∗ m)+1 m−N (t∗m) log(m) ≤1 2. Therefore, since m ≥6, it is easy to verify N(t∗ m) + 1 ≤m/2. Therefore, by definition of Distmon there exists a t ≤t∗ m with φ(t) < φ(t∗ m). Since ν(t) is monotone over all of t ∈Dist, we also have ν(t) ≤ν(t∗ m). Now, φ(t) < φ(t∗ m) and ν(t) ≤ν(t∗ m) together imply that G(ν(t)) < G(ν(t∗ m)), a contradiction. Hence, t∗ m ∈Distmon. SelectScale follows a search similar to binary search, however the conditions for going right and for going left are not complementary. The search ends when either none of these two conditions hold, or when there is nothing left to try. The final output of the algorithm is based on minimizing G(ˆϵ(t)) over some of the values tested during search. For c > 0, define γ(c) := 1 + 2 3c + 3 √ 2c and ˜γ(c) := 1 c + 2 3 + 3 √ 2c. For all t, ϵ > 0 we have the implications ϵ ≥cφ(t) ⇒γ(c)ϵ ≥G(ϵ, t) and φ(t) ≥cϵ ⇒˜γ(c)φ(t) ≥G(ϵ, t). (1) The following lemma uses Eq. (1) to show that the estimate G(ˆϵ(t)) is close to the true G(ϵ(t)). Lemma 5.3. Let t > 0, δ ∈ (0, 1), and suppose that SelectScale calls ˆϵ(t) ← EstimateErr(t, φ(t), δ). Suppose that V (t) as defined in Theorem 5.1 holds. Then 1 6G(ˆϵ(t)) ≤ G(ϵ(t)) ≤6.5G(ˆϵ(t)). Proof. Under V (t), we have that if ˆϵ(t) < φ(t) then ϵ(t) ≤ 5 4φ(t). In this case, G(ϵ(t)) ≤ ˜γ(4/5)φ(t) ≤4.3φ(t), by Eq. (1). Therefore G(ϵ(t)) ≤3·4.3 2 G(ˆϵ(t)). In addition, G(ϵ(t)) ≥2 3φ(t) (from the definition of G), and by Eq. (1) and ˜γ(1) ≤4, φ(t) ≥1 4G(ˆϵ(t)). Therefore G(ϵ(t)) ≥ 1 6G(ˆϵ(t)). On the other hand, if ˆϵ(t) ≥φ(t), then by Theorem 5.1 4 5ϵ(t) ≤ˆϵ(t) ≤4 3ϵ(t). Therefore G(ˆϵ(t)) ≤4 3G(ϵ(t)) and G(ϵ(t)) ≤5 4G(ˆϵ(t)). Taking the worst-case of both possibilities, we get the bounds in the lemma. The next theorem bounds the label complexity of SelectScale. Let Ttest ⊆Distmon be the set of scales that are tested during SelectScale (that is, their ˆϵ(t) was estimated). 7 Algorithm 2 SelectScale(δ) input δ ∈(0, 1) output Scale ˆt T ←Distmon, # T maintains the current set of possible scales while T ̸= ∅do t ←the median value in T # break ties arbitrarily ˆϵ(t) ←EstimateErr(t, φ(t), δ). if ˆϵ(t) < φ(t) then T ←T \ [0, t] # go right in the binary search else if ˆϵ(t) > 11 10φ(t) then T ←T \ [t, ∞) # go left in the binary search else t0 ←t, T0 ←{t0}. break from loop end if end while if T0 was not set yet then If the algorithm ever went to the right, let t0 be the last value for which this happened, and let T0 := {t0}. Otherwise, T0 := ∅. end if Let TL be the set of all t that were tested and made the search go left Output ˆt := argmint∈TL∪T0 G(ˆϵ(t)) Theorem 5.4. Suppose that the event V (t) defined in Theorem 5.1 holds for all t ∈Ttest for the calls ˆϵ(t) ←EstimateErr(t, φ(t), δ). If the output of SelectScale is ˆt, then the number of labels requested by SelectScale is at most 19240|Ttest|(Q + 1) 1 G(ϵ(ˆt)) log(38480m2 δG(ϵ(ˆt)) ), where Q is as defined in Alg. 1. The following theorem provides a competitive error guarantee for the selected scale ˆt. Theorem 5.5. Suppose that V (t) and E(t), defined in Theorem 5.1 and Theorem 4.3, hold for all values t ∈Ttest, and that G∗≤1/3. Then SelectScale outputs ˆt ∈Distmon such that GB(ϵ(ˆt), N(ˆt), δ, m, 1) ≤O(G∗), where O(·) hides numerical constants only. The idea of the proof is as follows: First, we show (using Lemma 5.3) that it suffices to prove that G(ν(t∗ m)) ≥O(G(ˆϵ(ˆt))) to derive the bound in the theorem. Now, SelectScale ends in one of two cases: either T0 is set within the loop, or T = ∅and T0 is set outside the loop. In the first case, neither of the conditions for turning left and turning right holds for t0, so we have ˆϵ(t0) = Θ(φ(t0)) (where Θ hides numerical constants). We show that in this case, whether t∗ m ≥t0 or t∗ m ≤t0, G(ν(t∗ m)) ≥O(G(ˆϵ(t0))). In the second case, there exist (except for edge cases, which are also handled) two values t0 ∈T0 and t1 ∈TL such that t0 caused the binary search to go right, and t1 caused it to go left, and also t0 ≤t1, and (t0, t1) ∩Distmon = ∅. We use these facts to show that for t∗ m ≥t1, G(ν(t∗ m)) ≥O(G(ˆϵ(t1))), and for t∗ m ≤t0, G(ν(t∗ m)) ≥O(G(ˆϵ(t0))). Since ˆt minimizes over a set that includes t0 and t1, this gives G(ν(t∗ m)) ≥O(G(ˆϵ(ˆt))) in all cases. The proof of the main theorem, Theorem 3.2, which gives the guarantee for MARMANN, is almost immediate from Theorem 4.1, Theorem 4.3, Theorem 5.5 and Theorem 5.4. Acknowledgements Sivan Sabato was partially supported by the Israel Science Foundation (grant No. 555/15). Aryeh Kontorovich was partially supported by the Israel Science Foundation (grants No. 1141/12 and 755/15) and a Yahoo Faculty award. We thank Lee-Ad Gottlieb and Dana Ron for helpful discussions. 8 References P. Awasthi, M.-F. Balcan, and P. M. Long. The power of localization for efficiently learning linear separators with malicious noise. CoRR, abs/1307.8371, 2013. M. Balcan, S. Hanneke, and J. W. Vaughan. The true sample complexity of active learning. Machine Learning, 80(2-3):111–139, 2010. M.-F. Balcan, A. Broder, and T. Zhang. Margin-based active learning. In COLT, 2007. M.-F. Balcan, A. Beygelzimer, and J. Langford. Agnostic active learning. J. Comput. Syst. Sci., 75(1), 2009. C. Berlind and R. Urner. Active nearest neighbors in changing environments. In ICML, pages 1870–1879, 2015. R. M. Castro and R. D. Nowak. Learning Theory: 20th Annual Conference on Learning Theory, COLT 2007, San Diego, CA, USA; June 13-15, 2007. Proceedings, chapter Minimax Bounds for Active Learning, pages 5–19. Springer Berlin Heidelberg, Berlin, Heidelberg, 2007. K. Chaudhuri and S. Dasgupta. Rates of convergence for nearest neighbor classification. In NIPS, 2014. T. M. Cover and P. E. Hart. Nearest neighbor pattern classification. IEEE Transactions on Information Theory, 13:21–27, 1967. S. Dasgupta. Analysis of a greedy active learning strategy. In NIPS, pages 337–344, 2004. S. Dasgupta. Consistency of nearest neighbor classification under selective sampling. In COLT, 2012. S. Dasgupta and D. Hsu. Hierarchical sampling for active learning. In ICML, pages 208–215, 2008. L. Devroye and L. Györfi. Nonparametric density estimation: the L1 view. Wiley Series in Probability and Mathematical Statistics: Tracts on Probability and Statistics. John Wiley & Sons, Inc., New York, 1985. L. Devroye, L. Györfi, and G. Lugosi. A probabilistic theory of pattern recognition, volume 31 of Applications of Mathematics (New York). Springer-Verlag, New York, 1996. ISBN 0-387-94618-7. E. Fix and J. Hodges, J. L. Discriminatory analysis. nonparametric discrimination: Consistency properties. International Statistical Review / Revue Internationale de Statistique, 57(3):pp. 238–247, 1989. A. Gonen, S. Sabato, and S. Shalev-Shwartz. Efficient active learning of halfspaces: an aggressive approach. Journal of Machine Learning Research, 14(1):2583–2615, 2013. L. Gottlieb and R. Krauthgamer. Proximity algorithms for nearly-doubling spaces. In APPROX-RANDOM, pages 192–204, 2010. L. Gottlieb, L. Kontorovich, and R. Krauthgamer. Efficient classification for metric data. In COLT, pages 433–440, 2010. L. Gottlieb, A. Kontorovich, and R. Krauthgamer. Efficient classification for metric data. IEEE Transactions on Information Theory, 60(9):5750–5759, 2014a. L. Gottlieb, A. Kontorovich, and P. Nisnevitch. Near-optimal sample compression for nearest neighbors. In NIPS, pages 370–378, 2014b. L. Gottlieb, A. Kontorovich, and R. Krauthgamer. Adaptive metric dimensionality reduction. Theoretical Computer Science, pages 105–118, 2016a. L. Gottlieb, A. Kontorovich, and P. Nisnevitch. Nearly optimal classification for semimetrics. In Artificial Intelligence and Statistics (AISTATS), 2016b. T. Graepel, R. Herbrich, and J. Shawe-Taylor. PAC-Bayesian compression bounds on the prediction error of learning algorithms for classification. Machine Learning, 59(1-2):55–76, 2005. S. Hanneke. Rates of convergence in active learning. The Annals of Statistics, 39(1):333–361, 2011. S. Hanneke and L. Yang. Minimax analysis of active learning. JMLR, 16:3487–3602, 2015. A. Kontorovich and R. Weiss. A Bayes consistent 1-NN classifier. In AISTATS, 2015. A. Kontorovich, S. Sabato, and R. Urner. Active nearest-neighbor learning in metric spaces. CoRR, abs/1605.06792, 2016. URL http://arxiv.org/abs/1605.06792. S. Kpotufe. k-NN regression adapts to local intrinsic dimension. In NIPS, 2011. S. Kpotufe, R. Urner, and S. Ben-David. Hierarchical label queries with data-dependent partitions. In COLT, pages 1176–1189, 2015. R. Krauthgamer and J. R. Lee. Navigating nets: Simple algorithms for proximity search. In 15th Annual ACM-SIAM Symposium on Discrete Algorithms, pages 791–801, Jan. 2004. S. R. Kulkarni and S. E. Posner. Rates of convergence of nearest neighbor estimation under arbitrary sampling. IEEE Transactions on Information Theory, 41(4):1028–1039, 1995. A. Maurer and M. Pontil. Empirical Bernstein bounds and sample-variance penalization. In COLT, 2009. A. K. McCallum and K. Nigam. Employing EM and pool-based active learning for text classification. In ICML, 1998. C. J. Stone. Consistent nonparametric regression. The Annals of Statistics, 5(4):595–620, 1977. R. Urner, S. Wulff, and S. Ben-David. PLAL: cluster-based active learning. In COLT, pages 376–397, 2013. U. von Luxburg and O. Bousquet. Distance-based classification with Lipschitz functions. Journal of Machine Learning Research, 5:669–695, 2004. 9 | 2016 | 48 |
6,416 | Average-case hardness of RIP certification Tengyao Wang Centre for Mathematical Sciences Cambridge, CB3 0WB, United Kingdom t.wang@statslab.cam.ac.uk Quentin Berthet Centre for Mathematical Sciences Cambridge, CB3 0WB, United Kingdom q.berthet@statslab.cam.ac.uk Yaniv Plan 1986 Mathematics Road Vancouver BC V6T 1Z2, Canada yaniv@math.ubc.ca Abstract The restricted isometry property (RIP) for design matrices gives guarantees for optimal recovery in sparse linear models. It is of high interest in compressed sensing and statistical learning. This property is particularly important for computationally efficient recovery methods. As a consequence, even though it is in general NP-hard to check that RIP holds, there have been substantial efforts to find tractable proxies for it. These would allow the construction of RIP matrices and the polynomial-time verification of RIP given an arbitrary matrix. We consider the framework of average-case certifiers, that never wrongly declare that a matrix is RIP, while being often correct for random instances. While there are such functions which are tractable in a suboptimal parameter regime, we show that this is a computationally hard task in any better regime. Our results are based on a new, weaker assumption on the problem of detecting dense subgraphs. Introduction In many areas of data science, high-dimensional signals contain rich structure. It is of great interest to leverage this structure to improve our ability to describe characteristics of the signal and to make future predictions. Sparsity is a structure of wide applicability (see, e.g. Mallat, 1999; Rauhut and Foucart, 2013; Eldar and Kutyniok, 2012), with a broad literature dedicated to its study in various scientific fields. The sparse linear model takes the form y = Xβ + ε, where y ∈Rn is a vector of observations, X ∈Rn×p is a design matrix, ε ∈Rn is noise, and the vector β ∈Rp is assumed to have a small number k of non-zero entries. Estimating β or the mean response, Xβ, are among the most widely studied problems in signal processing, as well as in statistical learning. In high-dimensional problems, one would wish to recover β with as few observations as possible. For an incoherent design matrix, it is known that an order of k2 observations suffice (Donoho, Elad and Temlyakov, 2006; Donoho and Elad, 2003). However, this appears to require a number of observations far exceeding the information content of β, which has only k variables, albeit with unknown locations. This dependence in k can be greatly improved by using design matrices that are almost isometries on some low dimensional subspaces, i.e., matrices that satisfy the restricted isometry property with parameters k and θ, or RIP(k, θ) (see Definition 1.1). It is a highly robust property, and in fact implies that many different polynomial time methods, such as greedy methods (Blumensath and Davies, 2009; Needell and Tropp, 2009; Dai and Milenkovic, 2009) and convex optimization (Candès, 2008; Candès, Romberg and Tao, 2006b; Candès and Tao, 2005), are stable in recovering β. 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. Random matrices are known to satisfy the RIP when the number n of observation is more than about k log(p)/θ2. These results were developed in the field of compressed sensing (Candès, Romberg and Tao, 2006a; Donoho, 2006; Rauhut and Foucart, 2013; Eldar and Kutyniok, 2012) where the use of randomness still remains pivotal for near-optimal results. Properties related to the conditioning of design matrices have also been shown to play a key role in the statistical properties of computationally efficient estimators of β (Zhang, Wainwright and Jordan, 2014). While the assumption of randomness allows great theoretical leaps, it leaves open questions for practitioners. Scientists working on data closely following this model cannot always choose their design matrix X, or at least choose one that is completely random. Moreover, it is in general practically impossible to check that a given matrix satisfies these desired properties, as RIP certification is NP-hard (Bandeira et al., 2012). Having access to a function, or statistic, of X that could be easily computed, which determines how well β may be estimated, would therefore be of a great help. The search for such statistics has been of great importance for over a decade now, and several have been proposed (d’Aspremont and El Ghaoui, 2011; Lee and Bresler, 2008; Juditsky and Nemirovski, 2011; d’Aspremont, Bach and El Ghaoui, 2008). Perhaps the simplest and most popular is the incoherence parameter, which measures the maximum inner product between distinct, normalized, columns of X. However, all of these are known to necessarily fail to guarantee good recovery when p ≥2n unless n is of order k2 (d’Aspremont and El Ghaoui, 2011). Given a specific problem instance, the strong recovery guarantees of compressed sensing cannot be verified based on these statistics. In this article, we study the problem of average-case certification of the Restricted Isometry Property (RIP). A certifier takes as input a design matrix X, always outputs ‘false’ when X does not satisfy the property, and outputs ‘true’ for a large proportion of matrices (see Definition 2.1). Indeed, worstcase hardness does not preclude a problem from being solvable for most instances. The link between restricted isometry and incoherence implies that polynomial time certifiers exists in a regime where n is of order k2 log(p)/θ2. It is natural to ask whether the RIP can be certified for sample size n ≫k log(p)/θ2, where most matrices (with respect to, say, the Gaussian measure) are RIP. If it does, it would also provide a Las Vegas algorithm to construct RIP design matrices of optimal sizes. This should be compared with the currently existing limitations for the deterministic construction of RIP matrices. Our main result is that certification in this sense is hard even in a near-optimal regime, assuming a new, weaker assumption on detecting dense subgraphs, related to the Planted Clique hypothesis. Theorem (Informal). For any α < 1, there is no computationally efficient, average-case certifier for the class RIPn,p(k, θ) uniformly over an asymptotic regime where n ≪k1+α/θ2. This suggests that even in the average case, RIP certification requires almost k2 log(p)/θ2 observations. This contrasts highly with the fact that a random matrix satisfies RIP with high probability when n exceeds about k log(p)/θ2. Thus, there appears to be a large gap between what a practitioner may be able to certify given a specific problem instance, and what holds for a random matrix.On the other hand, if a certifier is found which fills this gap, the result would not only have huge practical implications in compressed sensing and statistical learning, but would also disprove a long-standing conjecture from computational complexity theory. We focus solely on the restricted isometry property, but other conditions under which compressed sensing is possible are also known. Extending our results to the restricted eigenvalue condition Bickel, Ritov and Tsybakov (2009) or other conditions (see, van de Geer and Buhlmann, 2009, and references therein) is an interesting path for future research. Our result shares many characteristics with a hypothesis by Feige (2002) on the hardness of refuting random satisfiability formulas. Indeed, our statement is also about the hardness of verifying that a property holds for a particular instance (RIP for design matrices, instead of unsatisfiability for boolean formulas). It concerns a regime where such a property should hold with high probability (n of order k1+α/θ2, linear regime for satisfiability), cautiously allowing only one type of errors, false negatives, for a problem that is hard in the worst case. In these two examples, such certifiers exist in a sub-optimal regime. Our problem is conceptually different from results regarding the worst-case hardness of certifying this property (see, e.g. Bandeira et al., 2012; Koiran and Zouzias, 2012; Tillmann and Pfetsch, 2014). It is closer to another line of work concerned with computational lower bounds for statistical learning problems based on average-case assumptions. The planted clique assumption has been used to prove computational hardness results for statistical problems such as estimation and testing of sparse principal components (Berthet and Rigollet, 2013a,b; Wang, Berthet 2 and Samworth, 2016), testing and localization of submatrix signals (Ma and Wu, 2013; Chen and Xu, 2014), community detection (Hajek, Wu and Xu, 2015) and sparse canonical correlation analysis (Gao, Ma and Zhou, 2014). The intractability of noisy parity recovery problem (Blum, Kalai and Wasserman, 2003) has also been used recently as an average-case assumption to deduce computational hardness of detection of satisfiability formulas with lightly planted solutions (Berthet and Ellenberg, 2015). Additionally, several unconditional computational hardness results are shown for statistical problems under constraints of learning models (Feldman et al., 2013). The present work has two main differences compared to previous computational lower bound results. First, in a detection setting, these lower bounds concern two specific distributions (for the null and alternative hypothesis), while ours is valid for all sub-Gaussian distributions, and there is no alternative distribution. Secondly, our result is not based on the usual assumption for the Planted Clique problem. Instead, we use a weaker assumption on a problem of detecting planted dense graphs. This does not mean that the planted graph is a random graph with edge probability q > 1/2 as considered in (Arias-Castro and Verzelen, 2013; Bhaskara et al., 2010; Awasthi et al., 2015), but that it can be any graph with an unexpectedly high number of edges (see section 3.1). This choice is made to strengthen our result: it would ‘survive’ the discovery of an algorithm that would use very specific properties of cliques (or even of random dense graphs) to detect their presence. As a consequence, the analysis of our reduction is more technically complicated. Our work is organized in the following manner: We recall in Section 1 the definition of the restricted isometry property, and some of its known properties. In Section 2, we define the notion of certifier, and prove the existence of a computationally efficient certifier in a sub-optimal regime. Our main result is developed in Section 3, focused on the hardness of average-case certification. The proofs of the main results are in Appendix A of the supplementary material and those of auxiliary results in Appendix B of the the supplementary material. 1 Restricted Isometric Property 1.1 Formulation We use the definition of Candès and Tao (2005), who introduced this notion. Below, for a vector u ∈Rp, we define ∥u∥0 is the number of its non-zero entries. Definition (RIP). A matrix X ∈Rn×p satisfies the restricted isometry property with sparsity k ∈ {1, . . . , p} and distortion θ ∈(0, 1), denoted by X ∈RIPn,p(k, θ), if it holds that 1 −θ ≤∥Xu∥2 2 ≤1 + θ, for every u ∈Sp−1(k) := {u ∈Rp : ∥u∥2 = 1, ∥u∥0 ≤k}. This can be equivalently defined by a property on submatrices of the design matrix: X is in RIPn,p(k, θ) if and only if for any set S of k columns of X, the submatrix, X∗S, formed by taking any these columns is almost an isometry, i.e. if the spectrum of its Gram matrix is contained in the interval [1 −θ, 1 + θ]: ∥X⊤ ∗SX∗S −Ik∥op ≤θ . Denote by ∥· ∥op,k the k-sparse operator norm, defined for a matrix A as ∥A∥op,k = supx∈Sp−1(k) ∥Ax∥2. This yields another equivalent formulation of the RIP property: X ∈ RIPn,p(k, θ) if and only if ∥X⊤X −Ip∥op,k ≤θ . We assume in the following discussion that the distortion parameter θ is upper-bounded by 1. For v ∈Rp and T ⊆{1, . . . , p}, we write vT for the #T-dimensional vector obtained by restricting v to coordinates indexed by T. Similarly, for an n × p matrix A and subsets S ⊆{1, . . . , n} and T ⊆{1, . . . , p}, we write AS∗for the submatrix obtained by restricting A to rows indexed by S, A∗T for the submatrix obtained by restricting A to columns indexed by T. 1.2 Generation via random design Matrices that satisfy the restricted isometry property have many interesting applications in highdimensional statistics and compressed sensing. However, there is no known way to generate them 3 deterministically in general. It is even NP-hard to check whether a given matrix X belongs to RIPn,p(k, θ) (see, e.g Bandeira et al., 2012). Several deterministic constructions of RIP matrices exist for sparsity level k ≲θ√n. For example, using equitriangular tight frames and Gershgorin’s circle theorem, one can construct RIP matrices with sparsity k ≤√n and distortion θ bounded away from 0 (see, e.g. Bandeira et al., 2012). The limitation k ≤θ√n is known as the ‘square root bottleneck’. To date, the only constructions that break the ‘square root bottleneck’ are due to Bourgain et al. (2011) and Bandeira, Mixon and Moreira (2014), both of which give RIP guarantee for k of order n1/2+ϵ for some small ϵ > 0 and fixed θ (the latter construction is conditional on a number-theoretic conjecture being true). Interestingly though, it is easy to generate large matrices satisfying the restricted isometry property through random design, and compared to the fixed design matrices mentioned in the previous paragraph, these random design constructions are much less restrictive on the sparsity level, typically allowing k up to the order n/ log(p) (assuming θ is bounded away from zero). They can be constructed easily from any centred sub-Gaussian distribution. We recall that a distribution Q (and its associated random variable) is said to be sub-Gaussian with parameter σ if R R eλx dQ(x) ≤eλ2σ2/2 for all λ ∈R. Definition. Define Q = Qσ to be the set of sub-Gaussian distributions Q over R with zero mean, unit variance, and sub-Gaussian parameter at most σ. The most common choice for a Q ∈Q is the standard normal distribution N(0, 1). Note that by Taylor expansion, for any Q ∈Q, we necessarily have σ2 ≥ R R x2 dQ(x) = 1. In the rest of the paper, we treat σ as fixed. Define the normalized distribution ˜Q to be the distribution of Z/√n for Z ∼Q. The following well-known result states that by concentration of measure, random matrices generated with distribution ˜Q⊗(n×p) satisfy restricted isometries (see, e.g. Candès and Tao (2005) and Baraniuk et al. (2008)). For completeness, we include a proof that establishes these particular constants stated here. All proofs are deferred to Appendix A or Appendix B of the supplementary material. Proposition 1. Suppose X is a random matrix with distribution ˜Q⊗(n×p), where Q ∈Q. It holds that P X ∈RIPn,p(k, θ) ≥1 −2 exp k log 9ep k − nθ2 256σ4 . (1) In order to clarify the notion of asymptotic regimes used in this paper, we introduce the following definition. Definition. For 0 ≤α ≤1, define the asymptotic regime Rα := (pn, kn, θn)n : p, k →∞and n ≫k1+α n log(pn) θ2n . We note that in this notation, Proposition 1 implies that for (p, k, θ) = (pn, kn, θn) ∈R0 we have, limn→∞˜Q⊗(n×p)(X ∈RIPn,p(k, θ)) = 1, and this convergence is uniform over Q ∈Q. 2 Certification of Restricted Isometry 2.1 Objectives and definition In practice, it is useful to know with certainty whether a particular realization of a random design matrix satisfies the RIP condition. It is known that the problem of deciding if a given matrix is RIP is NP-hard (Bandeira et al., 2012). However, NP-hardness is a only a statement about worst-case instances. It would still be of great use to have an algorithm that can correctly decide RIP property for an average instance of a design matrix, with some accuracy. Such an algorithm should identify a high proportion of RIP matrices generated through random design and make no false positive claims. We call such an algorithm an average-case certifier, or a certifier for short. Definition (Certifier). Given a parameter sequence (p, k, θ) = (pn, kn, θn), we define a certifier for ˜Q⊗(n×p)-random matrices to be a sequence (ψn)n of measurable functions ψn : Rn×p →{0, 1}, such that ψ−1 n (1) ⊆RIPn,p(k, θ) and lim sup n→∞ ˜Q⊗(n×p) ψ−1 n (0) ≤1/3. (2) 4 Note the definition of a certifier depends on both the asymptotic parameter sequence (pn, kn, θn) and the sub-Gaussian distribution Q. However, when it is clear from the context, we will suppress the dependence and refer to certifiers for RIPn,p(k, θ) properties of ˜Q⊗(n×p)-random matrices simply as ‘certifiers’. The two defining properties in (2) can be understood as follows. The first condition means that if a certifier outputs 1, we know with certainty that the matrix is RIP. The second condition means that the certifier is not overly conservative; it is allowed to output 0 for at most one third (with respect to ˜Q⊗(n×p) measure) of the matrices. The choice of 1/3 in the definition of a certifier is made to simplify proofs. However, all subsequent results will still hold if we replace 1/3 by any constant in (0, 1). In view of Proposition 1, the second condition in (2) can be equivalently stated as lim inf n→∞ ˜Q⊗(n×p) ψn(X) = 1 X ∈RIPn,p(k, θ) ≥2/3. With such a certifier, given an arbitrary problem fitting the sparse linear model, the matrix X could be tested for the restricted isometry property, with some expectation of a positive result. This would be particularly interesting given a certifier in the parameter regime n ≪θ2 nk2 n, in which presently known polynomial-time certifiers cannot give positive results. Even though it is not the main focus of our paper, we also note that a certifier ψ with the above properties for some distribution Q ∈Q would form a certifier/distribution couple (ψ, Q), that yields in the usual manner a Las Vegas algorithm to generate RIP matrices. The (random) algorithm keeps generating random matrices X ∼˜Q⊗(n×p) until ψn(X) = 1. The number of times that the certifier is invoked has a geometric distribution with success probability ˜Q⊗(n×p) ψ−1 n (1) . Hence, the Las Vegas algorithm runs in randomized polynomial time if and only if ψn runs in randomized polynomial time. 2.2 Certifier properties Although our focus is on algorithmically efficient certifiers, we establish first the properties of a certifier that is computationally intractable. This certifier serves as a benchmark for the performance of other candidates. Indeed, we exhibit in the following proposition a certifier, based on the k-sparse operator norm, that works uniformly well in the same asymptotic parameter regime R0, where ˜Q⊗(n×p)-random matrices are RIP with asymptotic probability 1. For clarity, we stress that our criterion when judging a certifier will always be its uniform performance over asymptotic regimes Rα for some α ∈[0, 1]. Proposition 2. Suppose (p, k, θ) = (pn, kn, θn) ∈R0. Furthermore, Let Q ∈Q and X ∼ ˜Q⊗(n×p). Then the sequence of tests (ψop,k)n based on sparse operator norms, defined by ψop,k(X) := 1 ∥X⊤X −Ip∥op,k ≤θ . is a certifier for ˜Q⊗(n×p)-random matrices. By a direct reduction from the clique problem, one can show that it is NP-hard to compute the ksparse operator norm of a matrix. Hence the certifier ψop,k is computationally intractable. The next proposition concerns the certifier property of a test based on the maximum incoherence between columns of the design matrix. It follows directly from a well-known result on the incoherence parameter of a random matrix (see, e.g. Rauhut and Foucart (2013, Proposition 6.2)) and allows the construction of a polynomial-time certifier that works uniformly well in the asymptotic parameter regime R1. Proposition 3. Suppose (p, k, θ) = (pn, kn, θn) satisfies n ≥196σ4k2 log(p)/θ2. Let Q ∈Q and X ∼˜Q⊗(n×p), then the tests ψ∞defined by ψ∞(X) := 1 ∥X⊤X −Ip∥∞≤14σ2 r log(p) n is a certifier for ˜Q⊗(n×p)-random matrices. 5 Proposition 3 shows that, when the sample size n is above k2 log(p)/θ2 in magnitude (in particular, this is satisfied asymptotically when (p, k, θ) = (pn, kn, θn) ∈R1), there is a polynomial time certifier. In other words, in this high-signal regime, the average-case decision problem for RIP property is much more tractable than indicated by the worst-case result. On the other hand, the certifier in Proposition 3 works in a much smaller parameter range when compared to ψop,k in Proposition 2. Combining Proposition 2 and 3, we have the following schematic diagram (Figure 1). When the sample size is lower than specified in R0, the property does not hold, with high probability, and no certifier exists. A computationally intractable certifier works uniformly over R0. On the other end of the spectrum, when the sample size is large enough to be in R1, a simple certifier based on the maximum incoherence of the design matrix is known to work in polynomial time. This leaves open the question of whether (randomized) polynomial time certifiers can work uniformly well in R0, or Rα for any α ∈[0, 1). We will see in the next section that, assuming a weaker variant of the Planted Clique hypothesis from computational complexity theory, R1 is essentially the largest asymptotic regime where a randomized polynomial time certifier can exist. Figure 1: Schematic digram for existence of certifiers in different asymptotic regimes. 3 Hardness of Certification 3.1 Planted dense subgraph assumptions We show in this section that certification of RIP property is an average-case hard problem in the parameter regime Rα for any α < 1. This is precisely the regime not covered by Proposition 3. The average-case hardness result is proved via reduction to the planted dense subgraph assumption. For any integer m ≥0, denote Gm the collection of all graphs on m vertices. We write V (G) and E(G) for the set of vertices and edges of a graph G. For H ∈Gκ where κ ∈{0, . . . , m}, let G(m, 1/2, H) be the random graph model that generates a random graph G on m vertices as follows. It first picks κ random vertices K ⊆V (G) and plants an isomorphic copy of H on these κ vertices, then every pair of vertices not in K × K is connected by an edge independently with probability 1/2. We write PH for the probability measure on Gm associated with G(m, 1/2, H). Note that if H is the empty graph, then G(m, 1/2, ∅) describes the Erd˝os–Rényi random graph. With a slight abuse of notation, we write P0 in place of P∅. On the other hand, for ϵ ∈(0, 1/2], if H belongs to the set H = Hκ,ϵ := H ∈Gκ : #E(H) ≥(1/2 + ϵ)κ(κ −1) 2 , then G(m, 1/2, H) generates random graphs that contain elevated local edge density. The planted dense graph problem concerns testing apart the following two hypotheses: H0 : G ∼G(m, 1/2, ∅) and H1 : G ∼G(m, 1/2, H) for some H ∈Hκ,ϵ. (3) It is widely believed that for κ = O(m1/2−δ), there does not exist randomized polynomial time tests to distinguish between H0 and H1 (see, e.g. Jerrum (1992); Feige and Krauthgamer (2003); Feldman et al. (2013)). More precisely, we have the following assumption. Assumption (A1) 1. Fix ϵ ∈(0, 1/2] and δ ∈(0, 1/2). let (κm)m be any sequence of integers such that κm →∞and κm = O m1/2−δ . For any sequence of randomized polynomial time tests (φm : Gm →{0, 1})m, we have lim inf m n P0 φ(G) = 1 + max H∈Hκ,ϵ PH φ(G) = 0) o > 1/3 . 6 We remark that if ϵ = 1/2, then Hκ,ϵ contains only the κ-complete graph and the testing problem becomes the well-known planted clique problem (cf. Jerrum (1992) and references in Berthet and Rigollet (2013a,b)). The difficulty of this problem has been used as a primitive for the hardness of other tasks, such as cryptographic applications, in Juels and Peinado (2000), testing for k-wise dependence in Alon et al. (2007), approximating Nash equilibria in Hazan and Krauthgamer (2011). In this case, Assumption (A1) is a version of the planted clique hypothesis (see, e.g. Berthet and Rigollet (2013b, Assumption APC)). We emphasize that Assumption A1 is significantly milder than the planted clique hypothesis (since it allows any ϵ ∈(0, 1/2]), or that a hypothesis on planted random graphs. We also note that when κ ≥Cϵ √m, spectral methods can be used to detect such graphs with high probability. Indeed, when G contains a graph of H, denoting AG its adjacency matrix, then AG −11⊤/2 has a leading eigenvalue greater than ϵ(κ −1), whereas it is of order √m for a usual Erd˝os–Rényi random graph. The following theorem relates the hardness of the planted dense subgraph testing problem to the hardness of certifying restricted isometry of random matrices. We recall that the distribution of X is that of an n×p random matrix with entries independently and identically sampled from ˜Q d= Q/√n, for some Q ∈Q. We also write Ψrp for the class of randomized polynomial time certifiers. Theorem 4. Assume (A1) and fix any α ∈[0, 1). Then there exists a sequence (p, k, θ) = (pn, kn, θn) ∈Rα, such that there is no certifier/distribution couple (ψ, Q) ∈Ψrp ×Q with respect to this sequence of parameters. Our proof of Theorem 4 relies on the following ideas: Given a graph G, an instance of the planted clique problem in the assumed hard regime, we construct n random vectors based on the adjacency matrix of a bipartite subgraph of G, between two random sets of vertices. Each coefficient of these vectors is then randomly drawn from one of two carefully chosen distributions, conditionally on the presence or absence of a particular edge. This construction ensures that if the graph is an Erd˝os– Rényi random graph (i.e. with no planted graph), the vectors are independent with independent coefficients, with distribution ˜Q. Otherwise, we show that with high probability, the presence of an unusually dense subgraph will make it very likely that the matrix does not satisfy the restricted isometry property, for a set of parameters in Rα. As a consequence, if there existed a certifier/distribution couple (ψ, Q) ∈Ψrp × Q in this range of parameters, it could be used - by using as input in the certifier the newly constructed matrix - to determine with high probability the distribution of G, violating our assumption (A1). We remark that this result holds for any distribution in Q, in contrast to computational lower bounds in statistical learning problems, that apply to a specific distribution. For the sake of simplicity, we have kept the coefficients of X identically distributed, but our analysis is not dependent on that fact, and our result can be directly extended to the case where the coefficients are independent, with different distributions in Q. Theorem 4 may be viewed as providing an asymptotic lower bound of the sample size n for the existence of a computationally feasible certifier. It establishes this computational lower bound by exhibiting some specific ‘hard’ sequences of parameters inside Rα, and show that any algorithm violating the computational lower bound could be exploited to solve the planted dense subgraph problem. All hardness results, whether in a worst-case (NP-hardness, or other) or the average-case (by reduction from a hard problem), are by nature statements on the impossibility of accomplishing a task in a computationally efficient manner, uniformly over a range of parameters. They are therefore always based on the construction of a ‘hard’ sequence of parameters used in the reduction, for which a contradiction is shown. Here, the ‘hard’ sequence is explicitly constructed in the proof to be some (p, k, θ) = (pn, kn, θn) satisfying p ≥n and n1/(3−α−4β) ≪k ≪n1/(2−β)−δ, for β ∈[0, (1 −α)/3) and any small δ > 0. The tuning parameter β is to allow additional flexibility in choosing these ‘hard’ sequences. More precisely, using an averaging trick first seen in Ma and Wu (2013), we are able to show that the existence of such ‘hard’ sequences is not confined only in the sparsity regime k ≪n1/2 . We note that in all our ‘hard’ sequences, θn must depend on n. An interesting extension is to see if similar computational lower bounds hold when restricted to a subset of Rα where θ is constant. 7 References Alon, N., Andoni, A., Kaufman, T., Matulef, K., Rubinfeld, R., and Xie, N. (2007) Testing k-wise and almost k-wise independence. Proceedings of the Thirty-ninth ACM STOC. 496–505. Arias-Castro, E., Verzelen, N. (2013) Community Detection in Dense Random Networks. Ann. Statist.,42, 940-969 Awasthi, P., Charikar, M., Lai, K. A. and Risteki, A. (2015) Label optimal regret bounds for online local learning. J. Mach. Learn. Res. (COLT), 40. Bandeira, A. S., Dobriban, E., Mixon, D. G. and Sawin, W. F. (2012) Certifying the restricted isometry property is hard. IEEE Trans. Information Theory, 59, 3448–3450. Bandeira, A. S., Mixon, D. G. and Moreira, J. (2014) A conditional construction of restricted isometries. International Mathematics Research Notices, to appear. Baraniuk, R., Davenport, M., DeVore, R. and Wakin, M. (2008) A simple proof of the restricted isometry property for random matrices. Constructive Approximation, 28, 253–263. Berthet, Q. and Ellenberg, J. S. (2015) Detection of Planted Solutions for Flat Satisfiability Problems. Preprint Berthet, Q. and Rigollet P. (2013) Optimal detection of sparse principal components in high dimension. Ann. Statist., 41, 1780–1815. Berthet, Q. and Rigollet P. (2013) Complexity theoretic lower bounds for sparse principal component detection. J. Mach. Learn. Res. (COLT), 30, 1046–1066. Bhaskara, A., Charikar, M., Chlamtac, E., Feige, U. and Vijayaraghavan, A. (2010) Detecting High Log-Densities an O(n1/4) Approximation for Densest k-Subgraph. Proceedings of the fortysecond ACM symposium on Theory of computing, 201–210. Bickel, P., Ritov, Y. and Tsybakov, A. (2009) Simultaneous analysis of Lasso and Dantzig selector Ann. Statist., 37,1705–1732 Blum, A., Kalai, A. and Wasserman, H. (2003) Noise-tolerant learning, the parity problem, and the statistical query model. Journal of the ACM, 50, 506–519. Blumensath, T. and Davies, M. E. (2009) Iterative hard thresholding for compressed sensing. Applied and Computational Harmonic Analysis, 27, 265–274. Bourgain, J., Dilworth, S., Ford, K. and Konyagin, S. (2011) Explicit constructions of RIP matrices and related problems. Duke Math. J., 159, 145–185. Candès, E. J. (2008) The restricted isometry property and its implications for compressed sensing. Comptes Rendus Mathematique, 346, 589–592. Candès, E. J., Romberg, J. and Tao, T. (2006) Robust uncertainty principles: Exact signal reconstruction from highly incomplete frequency information. IEEE Trans. Inform. Theory, 52, 489–509. Candès, E. J., Romberg, J. K. and Tao, T. (2006) Stable signal recovery from incomplete and inaccurate measurements. Communications on pure and applied mathematics, 59, 2006. Candès E. J. and Tao, T. (2005) Decoding by Linear Programming. IEEE Trans. Inform. Theory, 51, 4203–4215. Chen, Y. and Xu, J. (2014) Statistical-computational tradeoffs in planted problems and submatrix localization with a growing number of clusters and submatrices. preprint, arXiv:1402.1267. d’Aspremont, A., Bach, F. and El Ghaoui, L. (2008) Optimal solutions for sparse principal component analysis. J. Mach. Learn. Res., 9, 1269–1294. d’Aspremont, A. and El Ghaoui, L. (2011) Testing the nullspace property using semidefinite programming. Mathematical programming, 127, 123–144. 8 Dai, W. and Milenkovic, O. (2009) Subspace pursuit for compressive sensing signal reconstruction. IEEE Trans. Inform. Theory, 55, 2230–2249. Donoho, D. L. (2006) Compressed sensing. IEEE Trans. Inform. Theory, 52, 1289–1306. Donoho, D. L., and Elad, M. (2003) mally sparse representation in general (nonorthogonal) dictionaries via ℓ1 minimization. Proceedings of the National Academy of Sciences, 100, 2197–2202. Donoho, D. L., Elad, M. and Temlyakov, V. N. (2006) Stable recovery of sparse overcomplete representations in the presence of noise. IEEE Trans. Inform. Theory, 52, 6–18. Eldar, Y. C. and Kutyniok, G. (2012) Compressed Sensing: Theory and Applications. Cambridge University Press, Cambridge. Feige, U. Relations between average case complexity and approximation complexity. Proceedings of the Thirty-Fourth Annual ACM Symposium on Theory of Computing, 534–543. Feige, U. and Krauthgamer, R. (2003) The probable value of the Lovàsz–Schrijver relaxations for a maximum independent set. SIAM J. Comput., 32, 345–370. Feldman, V., Grigorescu, E., Reyzin, L., Vempala, S. S. and Xiao, Y. (2013) Statistical Algorithms and a Lower Bound for Detecting Planted Cliques. Proceedings of the Forty-fifth Annual ACM Symposium on Theory of Computing. 655–664. Gao, C., Ma, Z. and Zhou, H. H. (2014) Sparse CCA: adaptive estimation and computational barriers. preprint, arXiv:1409.8565. Hajek, B., Wu, Y. and Xu, J.(2015) Computational Lower Bounds for Community Detection on Random Graphs, Proceedings of The 28th Conference on Learning Theory, 899–928. Hazan, E. and Krauthgamer, R. (2011) How hard is it to approximate the best nash equilibrium? SIAM J. Comput., 40, 79–91. Jerrum, M. (1992) Large cliques elude the Metropolis process. Random Struct. Algor., 3, 347–359. Juditsky, A. and Nemirovski, A. (2011) On verifiable sufficient conditions for sparse signal recovery via ℓ1 minimization. Mathematical programming, 127, 57–88. Juels, A. and Peinado, M. (2000) Hiding cliques for cryptographic security. Des. Codes Cryptography. 20, 269-280. Koiran, P. and Zouzias, A. (2012) Hidden cliques and the certification of the restricted isometry property. preprint, arXiv:1211.0665. Lee, K. and Bresler, Y. (2008) Computing performance guarantees for compressed sensing. IEEE International Conference on Acoustics, Speech and Signal Processing, 5129–5132. Ma, Z. and Wu, Y. (2013) Computational barriers in minimax submatrix detection. arXiv preprint. Mallat, S. (1999) A wavelet tour of signal processing. Academic press, Cambridge, MA. Needell, D. and Tropp, J. A. (2009) CoSaMP: Iterative signal recovery from incomplete and inaccurate samples. Applied and Computational Harmonic Analysis, 26, 301–321. Rauhut, H. and Foucart, S. (2013) A Mathematical Introduction to Compressive Sensing. Birkhäuser. Tillmann, A. N. and Pfetsch M. E. (2014) The computational complexity of the restricted isometry property, the nullspace property, and related concepts in compressed sensing. IEEE Trans. Inform. Theory, 60, 1248–1259. van de Geer, S. and Buhlmann, P. (2009) On the conditions used to prove oracle results for the lasso. Electron. J. Stat., 3, 1360–1392 Wang, T., Berthet, Q. and Samworth, R. J. (2016) Statistical and computational trade-offs in Estimation of Sparse Pincipal Components. Ann. Statist., 45, 1896–1930 Zhang, Y., Wainwright, M. J. and Jordan, M. I. (2014) Lower bounds on the performance of polynomial-time algorithms for sparse linear regression. JMLR: Workshop and Conference Proceedings (COLT), 35, 921–948. 9 | 2016 | 480 |
6,417 | Efficient High-Order Interaction-Aware Feature Selection Based on Conditional Mutual Information Alexander Shishkin, Anastasia Bezzubtseva, Alexey Drutsa, Ilia Shishkov, Ekaterina Gladkikh, Gleb Gusev, Pavel Serdyukov Yandex; 16 Leo Tolstoy St., Moscow 119021, Russia {sisoid,nstbezz,adrutsa,ishfb,kglad,gleb57,pavser}@yandex-team.ru Abstract This study introduces a novel feature selection approach CMICOT, which is a further evolution of filter methods with sequential forward selection (SFS) whose scoring functions are based on conditional mutual information (MI). We state and study a novel saddle point (max-min) optimization problem to build a scoring function that is able to identify joint interactions between several features. This method fills the gap of MI-based SFS techniques with high-order dependencies. In this high-dimensional case, the estimation of MI has prohibitively high sample complexity. We mitigate this cost using a greedy approximation and binary representatives what makes our technique able to be effectively used. The superiority of our approach is demonstrated by comparison with recently proposed interactionaware filters and several interaction-agnostic state-of-the-art ones on ten publicly available benchmark datasets. 1 Introduction Methods of feature selection is an important topic of machine learning [8, 2, 17], since they improve performance of learning systems while reducing their computational costs. Feature selection methods are usually grouped into three main categories: wrapper, embedded, and filter methods [8]. Filters are computationally cheap and are independent of a particular learning model that make them popular and broadly applicable. In this paper, we focus on most popular filters, which are based on mutual information (MI) and apply the sequential forward selection (SFS) strategy to obtain an optimal subset of features [17]. In such applications as web search, features may be highly relevant only jointly (having a low relevance separately). A challenging task is to account for such interactions [17]. Existing SFS-based filters [18, 3, 24] are able to account for interactions of only up to 3 features. In this study, we fill the gap in the absence of effective SFS-based filters accounting for feature dependences of higher orders. A search of t-way interacting features is turned into a novel saddle point (max-min) optimization problem for MI of the target variable and the candidate feature with its complementary team conditioned on its opposing team of previously selected features. We show that, on the one hand, the saddle value of this conditional MI is a low-dimensional approximation of the CMI score1 and, on the other hand, solving that problem represents two practical challenges: (a) prohibitively high computational complexity and (b) sample complexity, a larger number of instances required to accurately estimate the MI. These issues are addressed by two novel techniques: (a) a two stage greedy search for the approximate solution of the above-mentioned problem whose computational complexity is O(i) at each i-th SFS iteration; and (b) binary representation of features that reduces the dimension of the space of joint distributions by a factor of (q/2)2t for q-value features. Being reasonable and intuitive, these techniques together constitute the main contribution of our study: a novel SFS method CMICOT that is able to identify joint interactions between multiple 1The CMI filter is believed to be a “north star" for vast majority of the state-of-the-art filters [2]. 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. features. We also empirically validate our approach with 3 state-of-the-art classification models on 10 publicly available benchmark datasets and compare it with known interaction-aware SFS-based filters and several state-of-the-art ones. 2 Preliminaries and related work Information-theoretic measures. The mutual information (MI) of two random variables f and g is defined as I(f; g) = H(f) + H(g) −H(f, g), where H(f) = −E [log P(f)] is Shannon’s entropy [4]2. The conditional mutual information of two random variables f and g given the variable h is I(f; g | h) = I(f; g, h) −I(f; h). The conditional MI measures the amount of additional information about the variable f carried by g compared to the variable h. Given sample data, entropy (and, hence, MI and conditional MI) of discrete variables could be simply estimated using the empirical frequencies (the point estimations) [15] or in a more sophisticated way (e.g., by means of the Bayesian framework [10]). More details on different entropy estimators can be found in [15]. Background of the feature selection based on MI. Let F be a set of features that could be used by a classifier to predict a variable c representing a class label. The objective of a feature selection (FS) procedure is to find a feature subset So ⊆F of a given size k ∈N that maximizes its joint MI with the class label c, i.e., So = argmax{S:S⊆F,|S|≤k} I(c; S). In our paper, we focus on this simple but commonly studied FS objective in the context of MI-based filters [2], though there is a wide variety of other definitions of optimal subset of features [17] (e.g., the all-relevant problem [13]). In order to avoid an exhaustive search of an optimal subset S , most filters are based on sub-optimal search strategies. The most popular one is the sequential forward selection (SFS) [20, 23, 17], which starts with an empty set (S0 := ∅) and iteratively increases it by adding one currently unselected feature on each step (Si := Si−1 ∪{fi}, i = 1, . . . , k, and So := Sk). The feature fi is usually selected by maximizing a certain scoring function (also called score) Ji(f) that is calculated with respect to currently selected features Si−1, i.e., fi := argmaxf∈F \Si−1 Ji(f). A trivial feature selection approach is to select top-k features in terms of their MI with the class label c [12]. This technique is referred to as MIM [2] and is a particular case of the SFS strategy based on score JMIM i (f) := I(c; f). Note that the resulting set may contain a lot of redundant features, since the scoring function JMIM i (·) is independent from already selected features Si−1. Among methods that take into account the redundancy between features [2, 17], the most popular and widely applicable ones are MIFS [1], JMI [21, 14], CMIM [6, 19], and mRMR [16]. Brown et al. [2] unified these techniques under one framework, where they are different low-order approximations of CMI feature selection approach. This method is based on the score equal to MI of the label with the evaluated feature conditioned on already selected features: JCMI i (f) := I(c; f | Si−1). (1) The main drawback of CMI is the sample complexity, namely, the exponential growth of the dimension of the distribution of the tuple (c, f, Si−1) with respect to i. The larger the dimension is, the larger number of instances is required to accurately estimate the conditional MI in Eq. (1). Therefore, this technique is not usable in the case of small samples and in the cases, when a large number of features should be selected [2]. This is also observed in our experiment in Appendix.F2, where empirical score estimated over high dimensions results in drastically low performance of CMI. Thus, low-dimensional approximations of Eq. (1) are more preferable in practice. For instance, the CMIM approach approximates Eq. (1) by JCMIM i (f) := min g∈Si−1 I(c; f | g), (2) i.e., one replaces the redundancy of f with respect to the whole subset Si−1 by the worst redundancy with respect to one feature from this subset. The other popular methods (mentioned above) are particular cases of the following approximation of the I(c; f | Si−1): Jβ,γ i (f) := I(c; f) − X g∈Si−1 βI(g; f) −γI(g; f | c) , (3) 2From here on in the paper, variables separated by commas or a set of variables in MI expressions are treated as one random vector variable, e.g., I(f; g, h) := I f; (g, h) and, for F = ∪n i=1{fi}, I(f; F) := I(f; f1, .., fn). 2 e.g., MIFS (β ∈[0, 1], γ = 0), mRMR (β = |Si−1|−1, γ = 0), and JMI (β = γ = |Si−1|−1). An important but usually neglected aspect in FS methods is feature complementariness [8, 3] (also known as synergy [24] and interaction [11]). In general, complementary features are those that appear to have low relevance to the target class c individually, but whose combination is highly relevant [25, 24]. In the next subsection, we provide a brief overview of existing studies on filters that take into account feature interaction. A reader interested in a formalized concept of feature relevance, redundancy, and interaction is referred to [11] and [24]. Related work on interaction-aware filters. To the best of our knowledge, existing interaction-aware filters that utilize the pure SFS strategy with a MI-based scoring function are the following ones. RelaxMRMR [18] is a modification of the mRMR method, whose scoring function in Eq. (3) was refined by adding the three-way feature interaction terms P h,g∈Si−1,h̸=g I(f; h | g). The method RCDFS [3] is a special case of Eq. (3), where β = γ are equal to a transformation of the standard deviation of the set {I(f; h)}h∈Si−1. The approach IWFS [24] is based on the following idea: at each step i, for each unselected feature f ∈F \ Si, one calculates the next step score Ji+1(f) as the current score Ji(f) multiplied by a certain measure of interaction between this feature f and the feature fi selected at the current step. Both RCDFS and IWFS can catch dependences between no more than 2 features, while RelaxMRMR is able to identify an interaction of up to 3 features, but its score’s computational complexity is O(i2) what makes it unusable in real applications. All these methods could not be straightforwardly improved to incorporate interactions of a higher order. In our study, we propose a general methodology that fills the gap between the ideal (“oracle") but infeasible CMI method, which takes all interactions into account, and the above-described methods that account for up to 3 interacting features. Our method can be effectively used in practice with its score’s computational complexity of a linear growth O(i) (as in most state-of-the-art SFS-filters). 3 Proposed feature selection In this section, we introduce a novel feature selection approach based on the SFS strategy whose score is built by solving from a novel optimization problem and comprises two novel techniques that makes the approach efficient and effective in practice. 3.1 Score with t-way interacted complementary and opposing teams Our FS method has a parameter t ∈N that is responsible for the desirable number of features whose mutual interaction (referred to as a t-way feature interaction) should be taken into account by the scoring function Ji(·). We build the scoring function according to the following intuitions. First, the amount of relevant information carried by a t-way interaction of a candidate feature f has the form I(c; f, H) for some set of features H of size |H| ≤t−1. Second, we remove the redundant part of this information w.r.t. the already selected features Si−1 and obtain the non-redundant information part I(c; f, H | Si−1). Following the heuristic of the CMIM method, this could be approximated by use of a small subset G ⊆Si−1, |G| ≤s ∈N, i.e., by the low-dimensional approximation min{G⊆Si−1,|G|≤s} I(c; f, H | G) (assuming s ≪i). Third, since in the SFS strategy one has to select only one feature at an iteration i, this approximated additional information of the candidate f with H w.r.t. Si−1 will be gained by with the feature f at this SFS iteration only if all complementary features H have been already selected (i.e., H ⊆Si−1). In this way, the score of the candidate f should be equal to the maximal additional information estimated using above reasoning, i.e., we come to the score which is a solution of the following saddle point (max-min) optimization problem ◦J(t,s) i (f) := max H⊆Si−1, |H|≤t−1 min G⊆Si−1, |G|≤s I(c; f, H | G). (4) We refer to the set {f} ∪Ho f, where Ho f is an optimal set H in Eq. (4), as an optimal complementary team of the feature f ∈F \ Si−1, while an optimal set G in Eq. (4) is referred to as an optimal opposing team to this feature f (and, thus, to its complementary team as well) and is denoted by Go f. The described approach is inspired by methods of greedy learning of ensembles of decision trees [7], where an ensemble of trees is built by sequentially adding a decision tree that maximizes the gain in learning quality. In this way, our complementary team corresponds to the features used in a candidate 3 decision tree, while our opposing team corresponds to the features used to build previous trees in the ensemble. Since they are already selected by SFS, they are expectedly stronger than f and we can assume that, at the early iterations, a greedy machine learning algorithm would more likely use these features rather than the new feature f once we add it into the feature set. So, Eq. (4) tries to mimic the maximal amount of information that feature f can provide additionally to the worst-case baseline built on Si−1. Statement 1. For t, s + 1 ≥i, the score ◦J(t,s) i from Eq. (4) is equal to the score JCMI i from Eq. (1). The proof’s sketch is: (a) justify the identity ◦J(t,s) i (f) = maxH⊆Si−1 minG⊆Si−1\H I(c; f | H, G) for t, s + 1 ≥i; (b) get a contradiction to the assumption that there are no optimal subsets H and G such that Si−1 = H ∪G. Detailed proof of Statement 1 is given in Appendix A. Thus, we argue that the score ◦J(t,s) i from Eq. (4) is a low-dimensional approximation of the CMI score JCMI i .3. The score from Eq. (4) is of a general nature and reasonable, but, to the best of our knowledge, was never considered in existing studies. However, this score is not suitable for effective application, since it suffers from two practical issues: (PI.a) computational complexity: efficient search of optimal sets Ho f and Go f in Eq. (4); (PI.b) sample complexity: accurate estimation of the MI over features with a large dimension of its joint distribution. We address these research problems and propose the following solutions to them: in Sec. 3.2, the issue (PI.a) is overcome in a greedy fashion, while, in Sec. 3.3,the issue (PI.b) is mitigated by means of binary representatives. 3.2 Greedy approximation of the score Note that an exhaustive search of a saddle point in Eq. (4) requires i−1 t−1 i−1 s MI calculations that can make calculation of the scoring function ◦J(t,s) i infeasible at a large iteration i even for low team sizes t, s > 1. In order to overcome this issue, we propose the following greedy search for sub-optimal complementary and opposing teams. At the first stage, we start from a greedy search of a sub-optimal set H that cannot be done straightforwardly, since Eq. (4) comprises both max and min operators. The latter one requires a search of an optimal G that we want do at the second stage (after H). Hence, the double optimization problem needs to be replaced by a simpler one which does not utilize a search of G. Proposition 1. (1) For any H ⊆Si−1 such that |H| ≤s, the following holds min G⊆Si−1,|G|≤s I(c; f, H | G) ≤I(c; f | H). (5) (2) If s ≥t −1, then the score given by the following optimization problem max H⊆Si−1,|H|≤t−1 I(c; f | H), (6) is an upper bound for the score ◦J(t,s) i from Eq. (4). The optimization problem Eq. (6) seems reasonable due to the following properties: (a) in fact, the search of H in Eq. (6) is maximization of the additional information carried out by the candidate f w.r.t. no more than t −1 already selected features from Si−1; (b) if a candidate f is a combination of features from H, then the right hand side in Eq. (5) is 0 and the inequality becomes an equality. So, we greedily search the maximum in Eq. (6), obtaining the (greedy) complementary team {f}∪Hf, where Hf := {h1, . . . , ht−1} is defined by4 hj := argmax h∈Si−1 I(c; f | h1, . . . , hj−1, h), j = 1, . . . , t −1. (7) 3Moreover, the CMIM score from Eq. (2) is a special case of Eq. (4) with s = t = 1 and restriction G ̸= ∅. 4If several elements provide an optimum (the case of ties), then we randomly select one of them. 4 At the second stage, given the complementary team {f} ∪Hf, we greedily search the (greedy) opposing team Gf := {g1, . . . , gs} in the following way: gj := argmin g∈Si−1 I(c; f, h1, . . . , hmin{j,t}−1 | g1, . . . , gj−1, g), j = 1, . . . , s. (8) Finally, given the teams {f} ∪Hf and Gf, we get the following greedy approximation of ◦J(t,s) i (f): J(t,s) i (f) := I(c; f, Hf | Gf). (9) This score requires (t + s −1)i MI calculations (see Eq. (7)–(9)), which is a linear dependence on an iteration i as in the most state-of-the-art SFS-based filters [2]. Thus, we built an efficient approximation of the score ◦J(t,s) i and resolve the issue (PI.a). Note that we have two options on the minimization stage: either to search among all members of the set Hf at each step (as in Eq. (A.7) in Appendix A.3), or (what we actually do in Eq. (8)) to use only a few first members of Hf. The latter option demonstrates noticeably better MAUC performance and also results in 0 score for a feature that is a copy of an already selected one (Proposition 2), while the former does not (Remark A.2 in Appendix A.3). That is why we chose this option. Proposition 2. Let s ≥t and a candidate feature f ∈F \ Si−1 be such that its copy ˜f ≡f is already selected ˜f ∈Si−1, then, in the absence of ties in Eq. (8) for j ≤t, the score J(t,s) i (f) = 0. Proposition 2 shows that the FS approach based on the greedy score J(t,s) i (f) remains conservative, i.e., a copy of an already selected feature will not be selected, despite that it exploits sub-optimal teams in contrast to the FS approach based on the optimal score ◦J(t,s) i (f). 3.3 Binary representatives of features As it is mentioned in Sec. 2, a FS method that is based on calculation of MI over more than three features is usually not popular in practice, since a large number of features implies a large dimension of their joint distribution that leads to a large number of instances required to accurately estimate the MI [2]. Both our optimal score ◦J(t,s) i and our greedy one J(t,s) i suffer from the same issue (PI.b) as well, since they exploit high-dimensional MI in Eq.(4) and Eq. (7)–(9). For instance, if we deal with binary classification and each feature in F has q unique values (e.g., continuous features are usually preprocessed into discrete variables with q ≥5 [18]), then the dimension of the joint distribution of features in Eq. (9) is equal to 2 · qt+s (e.g., ≈4.9 · 108 for t = s = 6, q = 5). In our method, we cannot reduce the number of features used in MIs (since t-way interaction constitutes the key basis of our approach), but we can mitigate the effect of the sample complexity by the following novel technique, which we demonstrate on our greedy score J(t,s) i . Let F consists of discrete features5. Definition 1. For each discrete feature f ∈F, we denote by B[f] the binary transformation of f, i.e., the set of binary variables (referred to as the binary representatives (BR) of f) that constitute all together a vector containing the same information as f 6. For any subset F ′ ⊆F, the set of binary representatives of all features from F ′ is denoted by B[F ′] = S f∈F ′ B[f]. Then, we replace all features by their binary representatives at each stage of our score calculation. Namely, in Eq. (7) and Eq. (8), (a) the searches are performed for each binary representative b ∈B[f] instead of f; (b) the set Hbin b of the complementary team is found among B[Si−1] ∪B[f]; while (c) the opposing team Gbin b is found among B[Si−1] (exact formulas could be found in Algorithm 1, lines 12 and 15). Finally, the score of a feature f in this FS approach based on binary representatives is defined as the best score among the binary representatives B[f] of the candidate f: J(t,s),bin i (f) := max b∈B[f] I(c; b, Hbin b | Gbin b ). (10) Note that, in the previous example with a binary target variable c and q-value features, the dimension of the joint distribution of binary representatives used to calculate MI in J(t,s),bin i is equal to 21+t+s, 5If there is a non-discrete feature, then we apply a discretization (e.g., by equal-width, equal-frequency binnings [5], MDL [22, 3], etc.), which is the state-of-the-art preprocessing of continuous features in filters. 6For instance, for f with values in {xl}q l=1, one could take B[f] = {I{f=xl}}q−1 l=1 , where IX is X’s indicator, or take bits of a binary encoding of {xl}q l=1 that is a smallest set (i.e., |B[f]| = ⌈log2 q⌉) among possible B[f]. 5 Algorithm 1 Pseudo-code of the CMICOT feature selection method (an implementation of this algorithm is available at https://github.com/yandex/CMICOT). 1: Input: F — the set of all features; B[f], f ∈F, — set of binary representatives built on f; 2: c — the target variable; k ∈N — the number of features to be selected; 3: t ∈N, s ∈Z+ — the team sizes (parameters of the algorithm); 4: Output: S — the set of selected features; 5: Initialize: 6: fbest := argmaxf∈F maxb∈B[f] I(c; b); // Select the first feature 7: S := {fbest}; Sbin := B[fbest]; 8: while |S| < k and |F \ S| > 0 do 9: for f ∈F \ S do 10: for b ∈B[f] do 11: for j := 1 to t −1 do 12: hj := argmaxh∈Sbin∪B[f] I(c; b | h1, .., hj−1, h); // Search for complementary feat. 13: end for 14: for j := 1 to s do 15: gj := argming∈Sbin I(c; b, h1, .., hmin{j,t}−1 | g1, .., gj−1, g); // Search for opp. feat. 16: end for 17: Ji[b] := I(c; b, h1, .., ht−1 | g1, .., gs); // Calculate the score of the binary rep. b 18: end for 19: Ji[f] := maxb∈B[f] Ji[b]; // Calculate the score of the feature f 20: end for 21: fbest := argmaxf∈F \S Ji[f]; // Select the best candidate feature at the current step 22: S := S ∪{fbest}; Sbin := Sbin ∪B[fbest]; 23: end while which is (q/2)t+s times smaller (the dimension reduction rate) than for the MI in J(t,s) i . For instance, for t = s = 6, q = 5, the MI from Eq. (10) deals with ≈8.2 · 103 dimensions, which is ≈6 · 104 times lower than≈4.9·108 ones for the MI from Eq. (9). The described technique has been inspired by the intuition that probably two binary representatives of two different features interact on average better than two binary representatives of one feature (see App. A.5.1). Therefore, we believe that the BR modification retains the score’s awareness to the most interactions between features. Surely, on the one hand, the BR technique can also be applied to any state-of-the-art SFS-filter [2] or any existing interaction-aware one (RelaxMRMR [18], RCDSFS [3], and IWFS [24]), but the effect on them will not be striking breakthrough, since these filters exploit no more than 3 features in one MI, and the dimension reduction rate will thus be not more than (q/2)3 (e.g., ≈15.6 for q = 5). On the other hand, this technique is of a general nature and represents a self-contained contribution to ML community, since it may be applied with noticeable profit to SFS-based filters with MIs of higher orders (possibly not yet invented). 3.4 CMICOT feature selection method We summarize Sec. 3.1–Sec. 3.3 in our novel feature selection method that is based on sequential forward selection strategy with the scoring function from Eq. (10). We refer to this FS method as CMICOT (Conditional Mutual Information with Complementary and Opposing Teams) and present its pseudo-code in Algorithm 1, which has a form of a SFS strategy with a specific algorithm to calculate the score (lines 10–19). In order to benefit from Prop. 1 and 2, one has to select s ≥t, and, for simplicity, from here on in this paper we consider only equally limited teams, i.e., t = s. Proposition 3. Let |B[f]| ≤ν, ∀f ∈F, |F| ≤M, and entropies in MIs are calculated over N instances, then O(iν2t2N) simple operations are needed to calculate the score J(t,t),bin i and O(k2ν2t2MN) simple operations are needed to select top-k features by CMICOT from Alg. 1. Let us remind how each of our techniques contributes to the presented above computational complexity of the score. First, the factor t2 is an expected payment for the ability to be aware of t-way interactions (Sec. 3.1). Second, the two stage greedy technique from Sec. 3.2 makes the score’ computational complexity linearly depend on a SFS iteration i. Third, utilization of the BR technique from Sec. 3.3, on the one hand, seems to increase the computational complexity by the factor ν2, but, on the other 6 hand, we know that it drastically reduces the sample complexity (i.e., the number of instances required to accurately estimate the used MIs). For simplicity, let us assume that each feature has 2ν values and is transformed to ν binary ones. If we do not use the BR technique, the complexity will be lower by the factor ν2 for the same number of instances N, but estimation of the MIs will require (2ν/2)2t times more instances to achieve the same level of accuracy as with the BRs. Hence, the BR technique actually reduces the computational complexity by the factor 22t(ν−1)/ν2. Note that the team size t can be used to trade off between the number of instances available in the sample dataset and the maximal number of features whose joint interaction could be taken into account in a SFS manner. Finally, for a given dataset and a given team size t, the score’s computational complexity linearly depends on the i-th SFS iteration, on the one hand, as in most state-of-the-art SFS-filters [2] like CMIM, MIFS, mRMR, JMI, etc. (see Eq. (2)–(3)). On the other hand, scores of existing interactionaware ones have either the same (O(i) for RCDFS [3]), or higher (O(M −i) for IWFS [24] and O(i2) for RelaxMRMR [18]) order of complexity w.r.t. i. Thus, we conclude that our FS method is not inferior in efficiency to all baseline filters, but is able to identify feature dependences of higher orders than these baselines. 4 Experimental evaluation We compare our CMICOT approach with (a) all known interaction-aware SFS-based filters (RelaxMRMR [18], IWFS [24], and RCDFS [3]); (b) the state-of-the-art filters [2] (MIFS, mRMR, CMIM, JMI, DISR, and FCBF (CBFS)); (c) and the idealistic but practically infeasible CMI method (see Sec. 2 and [2]). In our experiments, we consider t = 1, . . . , 10 to validate that CMICOT is able to detect interactions of a considerably higher order than its competitors. Evaluation on synthetic data. First, we study the ability to detect high-order feature dependencies using synthetic datasets where relevant and interacting features are a priory known. A synthetic dataset has feature set F, which contains a group of jointly interacting relevant features Fint, and a its target c is a deterministic function of Fint for half of examples (|F \Fint| = 15 and |Fint| = 2, . . . , 11 in our experiments). The smaller k0 = min{k | Fint ⊆Sk}, the more effective the considered FS method, since it builds the smaller set of features needed to construct the best possible classifier. We conduct an experiment where, first, we randomly sample 100 datasets from the predefined joint distribution (more details in Appendix C). Second, we calculate k0 for each of studied FS methods on these datasets. Finally, we average k0 over the datasets and present the results in Figure 1 (a). We see, first, that CMICOT with t ≥|Fint| significantly outperforms all baselines, except the idealistic CMI method whose results are similar to CMICOT. This is expected, since CMI is infeasible only for large k, and, in App. F.2, we show that CMICOT is the closest approximation of true CMI among all baselines. Second, the team size t definitely responds to the number of interacted features, that provides an experimental evidence for ability of CMICOT to identify high-order feature interactions. Evaluation on benchmark real data. Following the state-of-the-art practice [6, 22, 2, 18, 24, 3], we conduct an extensive empirical evaluation of the effectiveness of our CMICOT approach on 10 large public datasets from the UCI ML Repo (that include the NIPS’2003 FS competition) and one private dataset from one of the most popular search engines7. We employ three state-of-theart classifiers: Naive Bayes Classifier (NBC), k-Nearest Neighbor (kNN), and AdaBoost [6] (see App. B). Their performance on a set of features is measured by means of AUC [2] (MAUC [9]) for a binary (multi-class) target variable. First, we apply each of the FS methods to select top-k features Sk for each dataset and for k = 1, .., 50 [2, 24, 3]. Given k ∈{1, .., 50}, a dataset, and a certain classifier, we measure the performance of a FS method (1) in terms of the (M)AUC of the classifier built on the selected features Sk (2) and in terms of the rank of the FS method among the other FS methods w.r.t. (M)AUC. The resulting (M)AUC and rank averaged over all datasets are shown in Fig. 1(b,c) for kNN and AdaBoost. From these figures we see that our CMICOT for t = 68 method noticeably outperforms all baselines for the classification models kNN and AdaBoost9 starting from approximately k = 10. We reason this frontier by the size of the teams in CMICOT 7The number of features, instances, and target classes varies from 85 to 5000, from 452 to 105, and from 2 to 26 respectively. More datasets’ characteristics and preprocessing can be found in Appendix D. 8Our experimentation on CMICOT with different t = 1, . . . , 10 on our datasets showed that t = 5 and 6 are the most reasonable in terms of classifier performance (see Appendix E.1.1). 9The results of CMICOT on NBC classifier are similar to the ones of other baselines. This is expected since NBC does not exploit high-order feature dependences, which is the key advantage of CMICOT. Note that 7 Figure 1: (a) Comparison of the performance of SFS-based filters in terms of average k0 on synthetic datasets. (b) Average values of (M)AUC for compared FS methods and (c) their ranks w.r.t. (M)AUC k = 1, .., 50 and for the kNN and AdaBoost classification models over all datasets (see also App. C,E). method, which should select different teams more likely when |Si−1| > 2t (= 12 for t = 6). The curves on Fig. 1 (b,c) are obtained over a test set, while a 10-fold cross-validation [2, 18] is also applied for several key points (e.g. k = 10, 20, 50) to estimate the significance of differences in classification quality. The detailed results of this CV for k = 50 on representative datasets are given in Appendix E.2. A more comprehensive details on these and other experiments are in App. E and F. We find that our approach either significantly outperforms baselines (most one for kNN and AdaBoost), or have non-significantly different difference with the other (most one for NBC). Note that the interaction awareness of RelaxMRMR, RCDFS and IWFS is apparently not enough to outperform CMIM, our strongest competitor. In fact, there is no comparison of RelaxMRMR and IWFS with CMIM in [3, 24], while RCDFS is outperformed by CMIM on some datasets including the only one utilized in both [18] and our work. One compares CMICOT with and without BR technique: on the one hand, we observed that CMICOT without BRs loses in performance to the one with BRs on the datasets with non-binary features, that emphasizes importance of the problem (PI.b); on the other hand, results on binary datasets (poker, ranking, and semeion; see App. E), where the CMICOT variants are the same, the effectiveness of our approach separately to the BR technique is established. 5 Conclusions We proposed a novel feature selection method CMICOT that is based on sequential forward selection and is able to identify high-order feature interactions. The technique based on a two stage greedy search and binary representatives of features makes our approach able to be effectively used on datasets of different sizes for restricted team sized t. We also empirically validated our approach for t up to 10 by means of 3 state-of-the-art classification models (NBC, kNN, and AdaBoost) on 10 publicly available benchmark datasets and compared it with known interaction-aware SFS-based filters (RelaxMRMR, IWFS, and RCDFS) and several state-of-the-art ones (CMIM, JMI, CBFS, and others). We conclude that our FS algorithm, unlike all competitor methods, is capable to detect interactions between up to t features. The overall performance of our algorithm is the best among the state-of-the-art competitors. Acknowledgments We are grateful to Mikhail Parakhin for important remarks which resulted in significant improvement of the paper presentation. RelaxMRMR also showed its poorest performance on NBC in [18], while IWFS and RCDFS in [3, 24] didn’t consider NBC at all. 8 References [1] R. Battiti. Using mutual information for selecting features in supervised neural net learning. Neural Networks, IEEE Transactions on, 5(4):537–550, 1994. [2] G. Brown, A. Pocock, M.-J. Zhao, and M. Luján. Conditional likelihood maximisation: a unifying framework for information theoretic feature selection. JMLR, 13(1):27–66, 2012. [3] Z. Chen, C. Wu, Y. Zhang, Z. Huang, B. Ran, M. Zhong, and N. Lyu. Feature selection with redundancycomplementariness dispersion. arXiv preprint arXiv:1502.00231, 2015. [4] T. M. Cover and J. A. Thomas. Elements of information theory. John Wiley & Sons, 2012. [5] J. Dougherty, R. Kohavi, M. Sahami, et al. Supervised and unsupervised discretization of continuous features. In ICML, volume 12, pages 194–202, 1995. [6] F. Fleuret. Fast binary feature selection with conditional mutual information. JMLR, 5:1531–1555, 2004. [7] J. H. Friedman. Greedy function approximation: a gradient boosting machine. Annals of Statistics, 2001. [8] I. Guyon and A. Elisseeff. An introduction to variable and feature selection. JMLR, 3:1157–1182, 2003. [9] D. J. Hand and R. J. Till. A simple generalisation of the area under the roc curve for multiple class classification problems. Machine Learning, 2001. [10] M. Hutter. Distribution of mutual information. NIPS, 1:399–406, 2002. [11] A. Jakulin and I. Bratko. Analyzing attribute dependencies. Springer, 2003. [12] D. D. Lewis. Feature selection and feature extraction for text categorization. In Proceedings of the workshop on Speech and Natural Language, pages 212–217. ACL, 1992. [13] J. Liu, C. Zhang, C. A. McCarty, P. L. Peissig, E. S. Burnside, and D. Page. High-dimensional structured feature screening using binary markov random fields. In AISTATS, pages 712–721, 2012. [14] P. E. Meyer, C. Schretter, and G. Bontempi. Information-theoretic feature selection in microarray data using variable complementarity. IEEE Journal of STSP, 2(3):261–274, 2008. [15] L. Paninski. Estimation of entropy and mutual information. Neural comput., 15(6):1191–1253, 2003. [16] H. Peng, F. Long, and C. Ding. Feature selection based on mutual information criteria of max-dependency, max-relevance, and min-redundancy. PAMI, 27(8):1226–1238, 2005. [17] J. R. Vergara and P. A. Estévez. A review of feature selection methods based on mutual information. Neural Computing and Applications, 24(1):175–186, 2014. [18] N. X. Vinh, S. Zhou, J. Chan, and J. Bailey. Can high-order dependencies improve mutual information based feature selection? Pattern Recognition, 2015. [19] G. Wang and F. H. Lochovsky. Feature selection with conditional mutual information maximin in text categorization. In ACM CIKM, pages 342–349. ACM, 2004. [20] A. W. Whitney. A direct method of nonparametric measurement selection. Computers, IEEE Transactions on, 100(9):1100–1103, 1971. [21] H. Yang and J. Moody. Feature selection based on joint mutual information. In Proceedings of international ICSC symposium on advances in intelligent data analysis, pages 22–25. Citeseer, 1999. [22] L. Yu and H. Liu. Efficient feature selection via analysis of relevance and redundancy. JMLR, 5:1205–1224, 2004. [23] M. Zaffalon and M. Hutter. Robust feature selection by mutual information distributions. In UAI, pages 577–584. Morgan Kaufmann Publishers Inc., 2002. [24] Z. Zeng, H. Zhang, R. Zhang, and C. Yin. A novel feature selection method considering feature interaction. Pattern Recognition, 48(8):2656–2666, 2015. [25] Z. Zhao and H. Liu. Searching for interacting features in subset selection. Intelligent Data Analysis, 13(2):207–228, 2009. 9 | 2016 | 481 |
6,418 | Fast and Provably Good Seedings for k-Means Olivier Bachem Department of Computer Science ETH Zurich olivier.bachem@inf.ethz.ch Mario Lucic Department of Computer Science ETH Zurich lucic@inf.ethz.ch S. Hamed Hassani Department of Computer Science ETH Zurich hamed@inf.ethz.ch Andreas Krause Department of Computer Science ETH Zurich krausea@ethz.ch Abstract Seeding – the task of finding initial cluster centers – is critical in obtaining highquality clusterings for k-Means. However, k-means++ seeding, the state of the art algorithm, does not scale well to massive datasets as it is inherently sequential and requires k full passes through the data. It was recently shown that Markov chain Monte Carlo sampling can be used to efficiently approximate the seeding step of k-means++. However, this result requires assumptions on the data generating distribution. We propose a simple yet fast seeding algorithm that produces provably good clusterings even without assumptions on the data. Our analysis shows that the algorithm allows for a favourable trade-off between solution quality and computational cost, speeding up k-means++ seeding by up to several orders of magnitude. We validate our theoretical results in extensive experiments on a variety of real-world data sets. 1 Introduction k-means++ (Arthur & Vassilvitskii, 2007) is one of the most widely used methods to solve k-Means clustering. The algorithm is simple and consists of two steps: In the seeding step, initial cluster centers are found using an adaptive sampling scheme called D2-sampling. In the second step, this solution is refined using Lloyd’s algorithm (Lloyd, 1982), the classic iterative algorithm for k-Means. The key advantages of k-means++ are its strong empirical performance, theoretical guarantees on the solution quality, and ease of use. Arthur & Vassilvitskii (2007) show that k-means++ produces clusterings that are in expectation O(log k)-competitive with the optimal solution without any assumptions on the data. Furthermore, this theoretical guarantee already holds after the seeding step. The subsequent use of Lloyd’s algorithm to refine the solution only guarantees that the solution quality does not deteriorate and that it converges to a locally optimal solution in finite time. In contrast, using naive seeding such as selecting data points uniformly at random followed by Lloyd’s algorithm can produce solutions that are arbitrarily bad compared to the optimal solution. The drawback of k-means++ is that it does not scale easily to massive data sets since both its seeding step and every iteration of Lloyd’s algorithm require the computation of all pairwise distances between cluster centers and data points. Lloyd’s algorithm can be parallelized in the MapReduce framework (Zhao et al., 2009) or even replaced by fast stochastic optimization techniques such as online or mini-batch k-Means (Bottou & Bengio, 1994; Sculley, 2010). However, the seeding step requires k inherently sequential passes through the data, making it impractical even for moderate k. 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. This highlights the need for a fast and scalable seeding algorithm. Ideally, it should also retain the theoretical guarantees of k-means++ and provide equally competitive clusterings in practice. Such an approach was presented by Bachem et al. (2016) who propose to approximate k-means++ using a Markov chain Monte Carlo (MCMC) approach and provide a fast seeding algorithm. Under natural assumptions on the data generating distribution, the authors show that the computational complexity of k-means++ can be greatly decreased while retaining the same O(log k) guarantee on the solution quality. The drawback of this approach is that these assumptions may not hold and that checking their validity is expensive (see detailed discussion in Section 3). Our contributions. The goal of this paper is to provide fast and competitive seedings for k-Means clustering without prior assumptions on the data. As our key contributions, we (1) propose a simple yet fast seeding algorithm for k-Means, (2) show that it produces provably good clusterings without assumptions on the data, (3) provide stronger theoretical guarantees under assumptions on the data generating distribution, (4) extend the algorithm to arbitrary distance metrics and various divergence measures, (5) compare the algorithm to previous results, both theoretically and empirically, and (6) demonstrate its effectiveness on several real-world data sets. 2 Background and related work We will start by formalizing the problem and reviewing several recent results. Let X denote a set of n points in Rd. For any finite set C ⇢Rd and x 2 X, we define d(x, C)2 = min c2Ckx −ck2 2. The objective of k-Means clustering is to find a set C of k cluster centers in Rd such that the quantization error φC(X) is minimized, where φC(X) = X x2X d(x, C)2. We denote the optimal quantization error with k centers by φk OP T (X), the mean of X by µ(X), and the variance of X by Var(X) = P x2X d(x, µ(X))2. We note that φ1 OP T (X) = Var(X). D2-sampling. Given a set of centers C, the D2-sampling strategy, as the name suggests, is to sample each point x 2 X with probability proportional to the squared distance to the selected centers, p(x | C) = d(x, C)2 P x02X d(x0, C)2 . (1) The seeding step of k-means++ builds upon D2-sampling: It first samples an initial center uniformly at random. Then, k −1 additional centers are sequentially added to the previously sampled centers using D2-sampling. The resulting computational complexity is ⇥(nkd), as for each x 2 X the distance d(x, C)2 in (1) needs to be updated whenever a center is added to C. Metropolis-Hastings. The Metropolis-Hastings algorithm (Hastings, 1970) is a MCMC method for sampling from a probability distribution p(x) whose density is known only up to constants. Consider the following variant that uses an independent proposal distribution q(x) to build a Markov chain: Start with an arbitrary initial state x1 and in each iteration j 2 [2, . . . , m] sample a candidate yj using q(x). Then, either accept this candidate (i.e., xj = yj) with probability ⇡(xj−1, yj) = min ✓p(yj) p(xj−1) q(xj−1) q(yj) , 1 ◆ (2) or reject it otherwise (i.e., xj = xj−1). The stationary distribution of this Markov chain is p(x). Hence, for m sufficiently large, the distribution of xm is approximately p(x). Approximation using MCMC (K-MC2). Bachem et al. (2016) propose to speed up k-means++ by replacing the exact D2-sampling in (1) with a fast approximation based on MCMC sampling. In each iteration j 2 [2, 3, . . . , k], one constructs a Markov chain of length m using the Metropolis-Hasting 2 algorithm with an independent and uniform proposal distribution q(x) = 1/n. The key advantage is that the acceptance probability in (2) only depends on d(yj, C)2 and d(xj−1, C)2 since min ✓p(yj) p(xj−1) q(xj−1) q(yj) , 1 ◆ = min ✓d(yj, C)2 d(xj−1, C)2 , 1 ◆ . Critically, in each of the k −1 iterations, the algorithm does not require a full pass through the data, but only needs to compute the distances between m points and up to k −1 centers. As a consequence, the complexity of K-MC2 is O % mk2d & compared to O(nkd) for k-means++ seeding. To bound the quality of the solutions produced by K-MC2, Bachem et al. (2016) analyze the mixing time of the described Markov chains. To this end, the authors define the two data-dependent quantities: ↵(X) = max x2X d(x, µ(X))2 P x02X d(x0, µ(X))2 , and β(X) = φ1 OP T (X) φk OP T (X). (3) In order to bound each term, the authors assume that the data is generated i.i.d. from a distribution F and impose two conditions on F. First, they assume that F exhibits exponential tails and prove that in this case ↵(X) 2 O % log2 n & with high probability. Second, they assume that “F is approximately uniform on a hypersphere”. This in turn implies that β(X) 2 O(k) with high probability. Under these assumptions, the authors prove that the solution generated by K-MC2 is in expectation O(log k)competitive with the optimal solution if m 2 ⇥ % k log2 n log k & . In this case, the total computational complexity of K-MC2 is O % k3d log2 n log k & which is sublinear in the number of data points. Other related work. A survey on seeding methods for k-Means was provided by Celebi et al. (2013). D2-sampling and k-means++ have been extensively studied in the literature. Previous work was primarily focused on related algorithms (Arthur & Vassilvitskii, 2007; Ostrovsky et al., 2006; Jaiswal et al., 2014, 2015), its theoretical properties (Ailon et al., 2009; Aggarwal et al., 2009) and bad instances (Arthur & Vassilvitskii, 2007; Brunsch & Röglin, 2011). As such, these results are complementary to the ones presented in this paper. An alternative approach to scalable seeding was investigated by Bahmani et al. (2012). The authors propose the k-meansk algorithm that retains the same O(log k) guarantee in expectation as k-means++. k-meansk reduces the number of sequential passes through the data to O(log n) by oversampling cluster centers in each of the rounds. While this allows one to parallelize each of the O(log n) rounds, it also increases the total computational complexity from O(nkd) to O(nkd log n). This method is feasible if substantial computational resources are available in the form of a cluster. Our approach, on the other hand, has an orthogonal use case: It aims to efficiently approximate k-means++ seeding with a substantially lower complexity. 3 Assumption-free K-MC2 Building on the MCMC strategy introduced by Bachem et al. (2016), we propose an algorithm which addresses the drawbacks of the K-MC2 algorithm, namely: (1) The theoretical results of K-MC2 hold only if the data is drawn independently from a distribution satisfying the assumptions stated in Section 2. For example, the results do not extend to heavytailed distributions which are often observed in real world data. (2) Verifying the assumptions, which in turn imply the required chain length, is computationally hard and potentially more expensive than running the algorithm. In fact, calculating ↵(X) already requires two full passes through the data, while computing β(X) is NP-hard. (3) Theorem 2 of Bachem et al. (2016) does not characterize the tradeoff between m and the expected solution quality: It is only valid for the specific choice of chain length m = ⇥ % k log2 n log k & . As a consequence, if the assumptions do not hold, we obtain no theoretical guarantee with regards to the solution quality. Furthermore, the constants in Theorem 2 are not known and may be large. Our approach addresses these shortcomings using three key elements. Firstly, we provide a proposal distribution that renders the assumption on ↵(X) obsolete. Secondly, a novel theoretic analysis allows us to obtain theoretical guarantees on the solution quality even without assumptions on β(X). Finally, our results characterize the tradeoff between increasing the chain length m and improving the expected solution quality. 3 Algorithm 1 ASSUMPTION-FREE K-MC2(AFK-MC2) Require: Data set X, # of centers k, chain length m // Preprocessing step 1: c1 Point uniformly sampled from X 2: for all x 2 X do 3: q(x) 1 2 d(x, c1)2/ P x02X d(x0, c1)2 + 1 2n // Main loop 4: C1 {c1} 5: for i = 2, 3, . . . , k do 6: x Point sampled from X using q(x) 7: dx d(x, Ci−1)2 8: for j = 2, 3, . . . , m do 9: y Point sampled from X using q(y) 10: dy d(y, Ci−1)2 11: if dyq(x) dxq(y) > Unif(0, 1) then x y, dx dy 12: Ci Ci−1 [ {x} 13: return Ck Proposal distribution. We argue that the choice of the proposal distribution is critical. Intuitively, the uniform distribution can be a very bad choice if, in any iteration, the true D2-sampling distribution is “highly” nonuniform. We suggest the following proposal distribution: We first sample a center c1 2 X uniformly at random and define for all x 2 X the nonuniform proposal q(x | c1) = 1 2 d(x, c1)2 P x02X d(x0, c1)2 | {z } (A) +1 2 1 |X| |{z} (B) . (4) The term (A) is the true D2-sampling distribution with regards to the first center c1. For any data set, it ensures that we start with the best possible proposal distribution in the second iteration. We will show that this proposal is sufficient even for later iterations, rendering any assumptions on ↵ obsolete. The term (B) regularizes the proposal distribution and ensures that the mixing time of K-MC2 is always matched up to a factor of two. Algorithm. Algorithm 1 details the proposed fast seeding algorithm ASSUMPTION-FREE K-MC2. In the preprocessing step, it first samples an initial center c1 uniformly at random and then computes the proposal distribution q(· | c1). In the main loop, it then uses independent Markov chains of length m to sample centers in each of the k −1 iterations. The complexity of the main loop is O % mk2d & . The preprocessing step of ASSUMPTION-FREE K-MC2 requires a single pass through the data to compute the proposal q(· | c1). There are several reasons why this additional complexity of O(nd) is not an issue in practice: (1) The preprocessing step only requires a single pass through the data compared to k passes for the seeding of k-means++. (2) It is easily parallelized. (3) Given random access to the data, the proposal distribution can be calculated online when saving or copying the data. (4) As we will see in Section 4, the effort spent in the preprocessing step pays off: It often allows for shorter Markov chains in the main loop. (5) Computing ↵(X) to verify the first assumption of K-MC2 is already more expensive than the preprocessing step of ASSUMPTION-FREE K-MC2. Theorem 1. Let ✏2 (0, 1) and k 2 N. Let X be any set of n points in Rd and C be the output of Algorithm 1 with m = 1 + 8 ✏log 4k ✏. Then, it holds that E [φC(X)] 8(log2 k + 2)φk OP T (X) + ✏Var(X). The computational complexity of the preprocessing step is O(nd) and the computational complexity of the main loop is O % 1 ✏k2d log k ✏ & . This result shows that ASSUMPTION-FREE K-MC2 produces provably good clusterings for arbitrary data sets without assumptions. The guarantee consists of two terms: The first term, i.e., 8(log2 k + 2)φk OP T (X), is the theoretical guarantee of k-means++. The second term, ✏Var(X), quantifies the potential additional error due to the approximation. The variance is a natural notion as the mean is the optimal quantizer for k = 1. Intuitively, the second term may be interpreted as a scale-invariant and additive approximation error. 4 Theorem 1 directly characterizes the tradeoff between improving the solution quality and the resulting increase in computational complexity. As m is increased, the solution quality converges to the theoretical guarantee of k-means++. At the same time, even for smaller chain lengths m, we obtain a provable bound on the solution quality. In contrast, the guarantee of K-MC2 on the solution quality only holds for a specific choice of m. For completeness, ASSUMPTION-FREE K-MC2 may also be analyzed under the assumptions made in Bachem et al. (2016). While for K-MC2 the required chain length m is linear in ↵(X), ASSUMPTION-FREE K-MC2 does not require this assumption. In fact, we will see in Section 4 that this lack of dependence of ↵(X) leads to a better empirical performance. If we assume β(X) 2 O(k), we obtain the following result similar to the one of K-MC2 (albeit with a shorter chain length m). Corollary 1. Let k 2 N and X be a set of n points in Rd satisfying β(X) 2 O(k). Let C be the output of Algorithm 1 with m = ⇥(k log k). Then it holds that E [φC(X)] 8(log2 k + 3)φk OP T (X). The computational complexity of the preprocessing is O(nd) and the computational complexity of the main loop is O % k3d log k & . 3.1 Proof sketch for Theorem 1 In this subsection, we provide a sketch of the proof of Theorem 1 and defer the full proof to Section A of the supplementary materials. Intuitively, we first bound how well a single Markov chain approximates one iteration of exact D2-sampling. Then, we analyze how the approximation error accumulates across iterations and provide a bound on the expected solution quality. For the first step, consider any set C ✓X of previously sampled centers. Let c1 2 C denote the first sampled center that was used to construct the proposal distribution q(x | c1) in (4). In a single iteration, we would ideally sample a new center x 2 X using D2-sampling, i.e., from p(x | C) as defined in (1). Instead, Algorithm 1 constructs a Markov chain to sample a new center x 2 X as the next cluster center. We denote by ˜pc1 m(x | C) the implied probability of sampling a point x 2 X using this Markov chain of length m. The following result shows that in any iteration either C is ✏1-competitive compared to c1 or the Markov chain approximates D2-sampling well in terms of total variation distance1. Lemma 1. Let ✏1, ✏2 2 (0, 1) and c1 2 X. Consider any set C ✓X with c1 2 C. For m ≥ 1 + 2 ✏1 log 1 ✏2 , at least one of the following holds: (i) φC(X) < ✏1φc1(X), or (ii) kp(· | C) −˜pc1 m(· | C)kTV ✏2. In the second step, we bound the expected solution quality of Algorithm 1 based on Lemma 1. While the full proof requires careful propagation of errors across iterations and a corresponding inductive argument, the intuition is based on distinguishing between two possible cases of sampled solutions. First, consider the realizations of the solution C that are ✏1-competitive compared to c1. By definition, φC(X) < ✏1φc1(X). Furthermore, the expected solution quality of these realizations can be bounded by 2✏1 Var(X) since c1 is chosen uniformly at random and hence in expectation φc1(X) 2 Var(X). Second, consider the realizations that are not ✏1-competitive compared to c1. Since the quantization error is non-increasing in sampled centers, Lemma 1 implies that all k −1 Markov chains result in a good approximation of the corresponding D2-sampling. Intuitively, this implies that the approximation error in terms of total variation distance across all k−1 iterations is at most ✏2(k−1). Informally, the expected solution quality is thus bounded with probability 1 −✏2(k −1) by the expected quality of k-means++ and with probability ✏2(k −1) by φc1(X). Theorem 1 can then be proven by setting ✏1 = ✏/4 and ✏2 = ✏/4k and choosing m sufficiently large. 1Let ⌦be a finite sample space on which two probability distributions p and q are defined. The total variation distance kp −qkTV between p and q is given by 1 2 P x2⌦|p(x) −q(x)|. 5 Table 1: Data sets used in experimental evaluation DATA SET N D K EVAL ↵(X) CSN (EARTHQUAKES) 80,000 17 200 T 546 KDD (PROTEIN HOMOLOGY) 145,751 74 200 T 1,268 RNA (RNA SEQUENCES) 488,565 8 200 T 69 SONG (MUSIC SONGS) 515,345 90 2,000 H 526 SUSY (SUPERSYM. PARTICLES) 5,000,000 18 2,000 H 201 WEB (WEB USERS) 45,811,883 5 2,000 H 2 Table 2: Relative error of ASSUMPTION-FREE K-MC2 and K-MC2 in relation to k-means++. CSN KDD RNA SONG SUSY WEB K-MEANS++ 0.00% 0.00% 0.00% 0.00% 0.00% 0.00% RANDOM 399.54% 314.78% 915.46% 9.67% 4.30% 107.57% K-MC2 (m = 20) 65.34% 31.91% 32.51% 0.41% -0.03% 0.86% K-MC2 (m = 100) 14.81% 3.39% 9.84% 0.04% -0.08% -0.01% K-MC2 (m = 200) 5.97% 0.65% 5.48% 0.02% -0.04% 0.09% AFK-MC2 (m = 20) 1.45% -0.12% 8.31% 0.01% 0.00% 1.32% AFK-MC2 (m = 100) 0.25% -0.11% 0.81% -0.02% -0.06% 0.06% AFK-MC2 (m = 200) 0.24% -0.03% -0.29% 0.04% -0.05% -0.16% 3.2 Extension to other clustering problems While we only consider k-Means clustering and the Euclidean distance in this paper, the results are more general. They can be directly applied, by transforming the data, to any metric space for which there exists a global isometry on Euclidean spaces. Examples would be the Mahalanobis distance and Generalized Symmetrized Bregman divergences (Acharyya et al., 2013). The results also apply to arbitrary distance measures (albeit with different constants) as D2-sampling can be generalized to arbitrary distance measures (Arthur & Vassilvitskii, 2007). However, Var(X) needs to be replaced by φ1 OP T (X) in Theorem 1 since the mean may not be the optimal quantizer (for k = 1) for a different distance metric. The proposed algorithm can further be extended to different potential functions of the form k · kl and used to approximate the corresponding Dl-sampling (Arthur & Vassilvitskii, 2007), again with different constants. Similarly, the results also apply to bregman++ (Ackermann & Blömer, 2010) which provides provably competitive solutions for clustering with a broad class of Bregman divergences (including the KL-divergence and Itakura-Saito distance). 4 Experimental results In this section2, we empirically validate our theoretical results and compare the proposed algorithm ASSUMPTION-FREE K-MC2 (AFK-MC2) to three alternative seeding strategies: (1) RANDOM, a “naive” baseline that samples k centers from X uniformly at random, (2) the full seeding step of k-means++, and (3) K-MC2. For both ASSUMPTION-FREE K-MC2 and K-MC2, we consider the different chain lengths m 2 {1, 2, 5, 10, 20, 50, 100, 150, 200}. Table 1 shows the six data sets used in the experiments with their corresponding values for k. We choose an experimental setup similar to Bachem et al. (2016): For half of the data sets, we both train the algorithm and evaluate the corresponding solution on the full data set (denoted by T in the EVAL column of Table 1). This corresponds to the classical k-Means setting. In practice, however, one is often also interested in the generalization error. For the other half of the data sets, we retain 250,000 data points as the holdout set for the evaluation (denoted by H in the EVAL column of Table 1). For all methods, we record the solution quality (either on the full data set or the holdout set) and measure the number of distance evaluations needed to run the algorithm. For ASSUMPTION-FREE K-MC2 this includes both the preprocessing and the main loop. We run every algorithm 200 times with different random seeds and average the results. We further compute and display 95% confidence intervals for the solution quality. 2An implementation of ASSUMPTION-FREE K-MC2 has been released at http://olivierbachem.ch. 6 100 101 102 103 Chain length m 0.5 1.0 1.5 2.0 2.5 3.0 3.5 4.0 4.5 5.0 Training error ×105 CSN afk-mc2 k-mc2 k-means++ random 100 101 102 103 Chain length m 1 2 3 4 5 6 7 8 9 ×1011 KDD afk-mc2 k-mc2 k-means++ random 100 101 102 103 Chain length m 0 1 2 3 4 5 6 7 8 9 ×107 RNA afk-mc2 k-mc2 k-means++ random 100 101 102 103 Chain length m 6.5 6.6 6.7 6.8 6.9 7.0 7.1 7.2 7.3 Holdout error ×1011 SONG afk-mc2 k-mc2 k-means++ random 100 101 102 103 Chain length m 5.00 5.05 5.10 5.15 5.20 5.25 5.30 ×105 SUSY afk-mc2 k-mc2 k-means++ random 100 101 102 103 Chain length m 0.8 1.0 1.2 1.4 1.6 1.8 2.0 2.2 2.4 ×102 WEB afk-mc2 k-mc2 k-means++ random Figure 1: Quantization error in relation to the chain length m for ASSUMPTION-FREE K-MC2 and K-MC2 as well as the quantization error for k-means++ and RANDOM (with no dependence on m). ASSUMPTION-FREE K-MC2 substantially outperforms K-MC2 except on WEB. Results are averaged across 200 iterations and shaded areas denote 95% confidence intervals. 104 105 106 107 108 Distance evaluations 0.5 1.0 1.5 2.0 2.5 3.0 3.5 4.0 4.5 5.0 Training error ×105 CSN k-means++ afk-mc2 k-mc2 104 105 106 107 108 Distance evaluations 1 2 3 4 5 6 7 8 9 ×1011 KDD k-means++ afk-mc2 k-mc2 104 105 106 107 108 Distance evaluations 0 1 2 3 4 5 6 7 8 ×107 RNA k-means++ afk-mc2 k-mc2 106 107 108 109 Distance evaluations 6.5 6.6 6.7 6.8 6.9 7.0 7.1 7.2 7.3 Holdout error ×1011 SONG k-means++ afk-mc2 k-mc2 106 107 108 109 1010 Distance evaluations 5.00 5.05 5.10 5.15 5.20 5.25 5.30 ×105 SUSY k-means++ afk-mc2 k-mc2 106 107 108 109 1010 1011 Distance evaluations 0.8 1.0 1.2 1.4 1.6 1.8 2.0 2.2 2.4 ×102 WEB k-means++ afk-mc2 k-mc2 Figure 2: Quantization error in relation to the number of distance evaluations for ASSUMPTION-FREE K-MC2, K-MC2 and k-means++. ASSUMPTION-FREE K-MC2 provides a speedup of up to several orders of magnitude compared to k-means++. Results are averaged across 200 iterations and shaded areas denote 95% confidence intervals. 7 Table 3: Relative speedup (in terms of distance evaluations) in relation to k-means++. CSN KDD RNA SONG SUSY WEB K-MEANS++ 1.0⇥ 1.0⇥ 1.0⇥ 1.0⇥ 1.0⇥ 1.0⇥ K-MC2 (m = 20) 40.0⇥ 72.9⇥ 244.3⇥ 13.3⇥ 237.5⇥ 2278.1⇥ K-MC2 (m = 100) 8.0⇥ 14.6⇥ 48.9⇥ 2.7⇥ 47.5⇥ 455.6⇥ K-MC2 (m = 200) 4.0⇥ 7.3⇥ 24.4⇥ 1.3⇥ 23.8⇥ 227.8⇥ AFK-MC2 (m = 20) 33.3⇥ 53.3⇥ 109.7⇥ 13.2⇥ 212.3⇥ 1064.7⇥ AFK-MC2 (m = 100) 7.7⇥ 13.6⇥ 39.2⇥ 2.6⇥ 46.4⇥ 371.0⇥ AFK-MC2 (m = 200) 3.9⇥ 7.0⇥ 21.8⇥ 1.3⇥ 23.5⇥ 204.5⇥ Discussion. Figure 1 shows the expected quantization error for the two baselines, RANDOM and k-means++, and for the MCMC methods with different chain lengths m. As expected, the seeding step of k-means++ strongly outperforms RANDOM on all data sets. As the chain length m increases, the quality of solutions produced by both ASSUMPTION-FREE K-MC2 and K-MC2 quickly converges to that of k-means++ seeding. On all data sets except WEB, ASSUMPTION-FREE K-MC2 starts with a lower initial error due to the improved proposal distribution and outperforms K-MC2 for any given chain length m. For WEB, both algorithms exhibit approximately the same performance. This is expected as ↵(X) of WEB is very low (see Table 1). Hence, there is only a minor difference between the nonuniform proposal of ASSUMPTION-FREE K-MC2 and the uniform proposal of K-MC2. In fact, one of the key advantages of ASSUMPTION-FREE K-MC2 is that its proposal adapts to the data set at hand. As discussed in Section 3, ASSUMPTION-FREE K-MC2 requires an additional preprocessing step to compute the nonuniform proposal. Figure 2 shows the expected solution quality in relation to the total computational complexity in terms of number of distance evaluations. Both K-MC2 and ASSUMPTION-FREE K-MC2 generate solutions that are competitive with those produced by the seeding step of k-means++. At the same time, they do this at a fraction of the computational cost. Despite the preprocessing, ASSUMPTION-FREE K-MC2 clearly outperforms K-MC2 on the data sets with large values for ↵(X) (CSN, KDD and SONG). The additional effort of computing the nonuniform proposal is compensated by a substantially lower expected quantization error for a given chain size. For the other data sets, ASSUMPTION-FREE K-MC2 is initially disadvantaged by the cost of computing the proposal distribution. However, as m increases and more time is spent computing the Markov chains, it either outperforms K-MC2 (RNA and SUSY) or matches its performance (WEB). Table 3 details the practical significance of the proposed algorithm. The results indicate that in practice it is sufficient to run ASSUMPTION-FREE K-MC2 with a chain length independent of n. Even with a small chain length, ASSUMPTION-FREE K-MC2 produces competitive clusterings at a fraction of the computational cost of the seeding step of k-means++. For example on CSN, ASSUMPTION-FREE K-MC2 with m = 20 achieves a relative error of 1.45% and a speedup of 33.3⇥. At the same time, K-MC2 would have exhibited a substantial relative error of 65.34% while only obtaining a slightly better speedup of 40.0⇥. 5 Conclusion In this paper, we propose ASSUMPTION-FREE K-MC2, a simple and fast seeding algorithm for k-Means. In contrast to the previously introduced algorithm K-MC2, it produces provably good clusterings even without assumptions on the data. As a key advantage, ASSUMPTION-FREE K-MC2 allows to provably trade off solution quality for a decreased computational effort. Extensive experiments illustrate the practical significance of the proposed algorithm: It obtains competitive clusterings at a fraction of the cost of k-means++ seeding and it outperforms or matches its main competitor K-MC2 on all considered data sets. Acknowledgments This research was partially supported by ERC StG 307036, a Google Ph.D. Fellowship and an IBM Ph.D. Fellowship. 8 References Acharyya, Sreangsu, Banerjee, Arindam, and Boley, Daniel. Bregman divergences and triangle inequality. In SIAM International Conference on Data Mining (SDM), pp. 476–484, 2013. Ackermann, Marcel R and Blömer, Johannes. Bregman clustering for separable instances. In SWAT, pp. 212–223. Springer, 2010. Aggarwal, Ankit, Deshpande, Amit, and Kannan, Ravi. Adaptive sampling for k-means clustering. In Approximation, Randomization, and Combinatorial Optimization. Algorithms and Techniques, pp. 15–28. Springer, 2009. Ailon, Nir, Jaiswal, Ragesh, and Monteleoni, Claire. Streaming k-means approximation. In Neural Information Processing Systems (NIPS), pp. 10–18, 2009. Arthur, David and Vassilvitskii, Sergei. k-means++: The advantages of careful seeding. In Symposium on Discrete Algorithms (SODA), pp. 1027–1035. Society for Industrial and Applied Mathematics, 2007. Bachem, Olivier, Lucic, Mario, Hassani, S. Hamed, and Krause, Andreas. Approximate k-means++ in sublinear time. In Conference on Artificial Intelligence (AAAI), February 2016. Bahmani, Bahman, Moseley, Benjamin, Vattani, Andrea, Kumar, Ravi, and Vassilvitskii, Sergei. Scalable k-means++. Very Large Data Bases (VLDB), 5(7):622–633, 2012. Bottou, Leon and Bengio, Yoshua. Convergence properties of the k-means algorithms. In Neural Information Processing Systems (NIPS), pp. 585–592, 1994. Brunsch, Tobias and Röglin, Heiko. A bad instance for k-means++. In Theory and Applications of Models of Computation, pp. 344–352. Springer, 2011. Cai, Haiyan. Exact bound for the convergence of Metropolis chains. Stochastic Analysis and Applications, 18(1):63–71, 2000. Celebi, M Emre, Kingravi, Hassan A, and Vela, Patricio A. A comparative study of efficient initialization methods for the k-means clustering algorithm. Expert Systems with Applications, 40 (1):200–210, 2013. Hastings, W Keith. Monte Carlo sampling methods using Markov chains and their applications. Biometrika, 57(1):97–109, 1970. Jaiswal, Ragesh, Kumar, Amit, and Sen, Sandeep. A simple D2-sampling based PTAS for k-means and other clustering problems. Algorithmica, 70(1):22–46, 2014. Jaiswal, Ragesh, Kumar, Mehul, and Yadav, Pulkit. Improved analysis of D2-sampling based PTAS for k-means and other clustering problems. Information Processing Letters, 115(2):100–103, 2015. Lloyd, Stuart. Least squares quantization in PCM. IEEE Transactions on Information Theory, 28(2): 129–137, 1982. Ostrovsky, Rafail, Rabani, Yuval, Schulman, Leonard J, and Swamy, Chaitanya. The effectiveness of Lloyd-type methods for the k-means problem. In Foundations of Computer Science (FOCS), pp. 165–176. IEEE, 2006. Sculley, D. Web-scale k-means clustering. In World Wide Web (WWW), pp. 1177–1178. ACM, 2010. Zhao, Weizhong, Ma, Huifang, and He, Qing. Parallel k-means clustering based on MapReduce. In Cloud Computing, pp. 674–679. Springer, 2009. 9 | 2016 | 482 |
6,419 | Anchor-Free Correlated Topic Modeling: Identifiability and Algorithm Kejun Huang∗ Xiao Fu∗ Nicholas D. Sidiropoulos Department of Electrical and Computer Engineering University of Minnesota Minneapolis, MN 55455, USA huang663@umn.edu xfu@umn.edu nikos@ece.umn.edu Abstract In topic modeling, many algorithms that guarantee identifiability of the topics have been developed under the premise that there exist anchor words – i.e., words that only appear (with positive probability) in one topic. Follow-up work has resorted to three or higher-order statistics of the data corpus to relax the anchor word assumption. Reliable estimates of higher-order statistics are hard to obtain, however, and the identification of topics under those models hinges on uncorrelatedness of the topics, which can be unrealistic. This paper revisits topic modeling based on second-order moments, and proposes an anchor-free topic mining framework. The proposed approach guarantees the identification of the topics under a much milder condition compared to the anchor-word assumption, thereby exhibiting much better robustness in practice. The associated algorithm only involves one eigendecomposition and a few small linear programs. This makes it easy to implement and scale up to very large problem instances. Experiments using the TDT2 and Reuters-21578 corpus demonstrate that the proposed anchor-free approach exhibits very favorable performance (measured using coherence, similarity count, and clustering accuracy metrics) compared to the prior art. 1 Introduction Given a large collection of text data, e.g., documents, tweets, or Facebook posts, a natural question is what are the prominent topics in these data. Mining topics from a text corpus is motivated by a number of applications, from commercial design, news recommendation, document classification, content summarization, and information retrieval, to national security. Topic mining, or topic modeling, has attracted significant attention in the broader machine learning and data mining community [1]. In 2003, Blei et al. proposed a Latent Dirichlet Allocation (LDA) model for topic mining [2], where the topics are modeled as probability mass functions (PMFs) over a vocabulary and each document is a mixture of the PMFs. Therefore, a word-document text data corpus can be viewed as a matrix factorization model. Under this model, posterior inference-based methods and approximations were proposed [2, 3], but identifiability issues – i.e., whether the matrix factors are unique – were not considered. Identifiability, however, is essential for topic modeling since it prevents the mixing of topics that confounds interpretation. In recent years, considerable effort has been invested in designing identifiable models and estimation criteria as well as polynomial time solvable algorithms for topic modeling [4, 5, 6, 7, 8, 9, 10, 11]. Essentially, these algorithms are based on the so-called separable nonnegative matrix factorization (NMF) model [12]. The key assumption is that every topic has an ‘anchor word’ that only appears in that particular topic. Based on this assumption, two classes of algorithms are usually employed, namely linear programming based methods [5, 7] and greedy pursuit approaches [11, 6, 8, 10]. The ∗These authors contributed equally. 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. former class has a serious complexity issue, as it lifts the number of variables to the square of the size of vocabulary (or documents); the latter, although computationally very efficient, usually suffers from error propagation, if at some point one anchor word is incorrectly identified. Furthermore, since all the anchor word-based approaches essentially convert topic identification to the problem of seeking the vertices of a simplex, most of the above algorithms require normalizing each data column (or row) by its ℓ1 norm. However, normalization at the factorization stage is usually not desired, since it may destroy the good conditioning of the data matrix brought by pre-processing and amplify noise [8]. Unlike many NMF-based methods that work directly with the word-document data, the approach proposed by Arora et al. [9, 10] works with the pairwise word-word correlation matrix, which has the advantage of suppressing sampling noise and also features better scalability. However, [9, 10] did not relax the anchor-word assumption or the need for normalization, and did not explore the symmetric structure of the co-occurrence matrix – i.e., the algorithms in [9, 10] are essentially the same asymmetric separable NMF algorithms as in [4, 6, 8]. The anchor-word assumption is reasonable in some cases, but using models without it is more appealing in more critical scenarios, e.g., when some topics are closely related and many key words overlap. Identifiable models without anchor words have been considered in the literature; e.g., [13, 14, 15] make use of third or higher-order statistics of the data corpus to formulate the topic modeling problem as a tensor factorization problem. There are two major drawbacks with this approach: i) third- or higher-order statistics require a lot more samples for reliable estimation relative to their lower-order counterparts (e.g., second-order word correlation statistics); and ii) identifiability is guaranteed only when the topics are uncorrelated – where a super-symmetric parallel factor analysis (PARAFAC) model can be obtained [13, 14]. Uncorrelatedness is a restrictive assumption [10]. When the topics are correlated, the model becomes a Tucker model which is not identifiable in general; identifiability needs more assumptions, e.g., sparsity of topic PMFs [15]. Contributions. In this work, our interest lies in topic mining using word-word correlation matrices like in [9, 10], because of its potential scalability and noise robustness. We propose an anchor-free identifiable model and a practically implementable companion algorithm. Our contributions are twofold: First, we propose an anchor-free topic identification criterion. The criterion aims at factoring the word-word correlation matrix using a word-topic PMF matrix and a topic-topic correlation matrix via minimizing the determinant of the topic-topic correlation matrix. We show that under a so-called sufficiently scattered condition, which is much milder than the anchor-word assumption, the two matrices can be uniquely identified by the proposed criterion. We emphasize that the proposed approach does not need to resort to higher-order statistics tensors to ensure topic identifiability, and it can naturally deal with correlated topics, unlike what was previously available in topic modeling, to the best of our knowledge. Second, we propose a simple procedure for handling the proposed criterion that only involves eigen-decomposition of a large but sparse matrix, plus a few small linear programs – therefore highly scalable and well-suited for topic mining. Unlike greedy pursuit-based algorithms, the proposed algorithm does not involve deflation and is thus free from error propagation; it also does not require normalization of the data columns / rows. Carefully designed experiments using the TDT2 and Reuters text corpora showcase the effectiveness of the proposed approach. 2 Background Consider a document corpus D ∈RV ×D, where each column of D corresponds to a document and D(v, d) denotes a certain measurement of word v in document d, e.g., the word-frequency of term v in document d or the term frequency–inverse document frequency (tf-idf) measurement that is often used in topic mining. A commonly used model is D ≈CW , (1) where C ∈RV ×F is the word-topic matrix, whose f-th column C(:, f) represents the probability mass function (PMF) of topic f over a vocabulary of words, and W (f, d) denotes the weight of topic f in document d [2, 13, 10]. Since matrix C and W are both nonnegative, (1) becomes a nonnegative matrix factorization (NMF) model – and many early works tried to use NMF and variants to deal with this problem [16]. However, NMF does not admit a unique solution in general, unless both C and W satisfy some sparsity-related conditions [17]. In recent years, much effort has been put in devising polynomial time solvable algorithms for NMF models that admit unique factorization. Such models and algorithms usually rely on an assumption called “separability” in the NMF literature [12]: Assumption 1 (Separability / Anchor-Word Assumption) There exists a set of indices Λ = {v1, . . . , vF } such that C(Λ, :) = Diag(c), where c ∈RF . 2 In topic modeling, it turns out that the separability condition has a nice physical interpretation, i.e., every topic f for f = 1, . . . , F has a ‘special’ word that has nonzero probability of appearing in topic f and zero probability of appearing in other topics. These words are called ‘anchor words’ in the topic modeling literature. Under Assumption 1, the task of matrix factorization boils down to finding these anchor words v1, . . . , vF since D(Λ, :) = Diag(c)W — which is already a scaled version of W — and then C can be estimated via (constrained) least squares. Algorithm 1: Successive Projection Algorithm [6] input : D; F . Σ = 1T DT X = DT Σ−1 (normalization); Λ = ∅; for f = 1, . . . , F do ˆvf ←arg maxv∈{1,...,V } ∥X(:, v)∥2; Λ ←[Λ, ˆvf ]; Θ ←arg minΘ ∥X −X(:, Λ)Θ∥2 F ; X ←X −X(:, Λ)Θ; end output:Λ Many algorithms have been proposed to tackle this indexpicking problem in the context of separable NMF, hyperspectral unmixing, and text mining. The arguably simplest algorithm is the so-called successive projection algorithm (SPA) [6] that is presented in Algorithm 1. SPA-like algorithms first define a normalized matrix X = DT Σ−1 where Σ = Diag(1T DT ) [11]. Note that X = GS where G(: , f) = W T(f,:)/∥W (f,:)∥1 and S(f, v) = C(v,f)∥W (f,:)∥1 ∥C(v,:)∥1∥D(v,:)∥1 . Consequently, we have 1T S = 1T if W ≥0, meaning the columns of X all lie on the simplex spanned by the columns of G, and the vertices of the simplex correspond to the anchor words. Also, the columns of S all live in the unit simplex. After normalization, SPA sequentially identifies the vertices of the data simplex, in conjunction with a deflation procedure. The algorithms in [8, 10, 11] can also be considered variants of SPA, with different deflation procedures and pre-/post-processing. In particular, the algorithm in [8] avoids normalization — for real-word data, normalization at the factorization stage may amplify noise and damage the good conditioning of the data matrix brought by pre-processing, e.g., the tf-idf procedure [8]. To pick out vertices, there are also algorithms using linear programming and sparse optimization [7, 5], but these have serious scalability issues and thus are less appealing. In practice D may contain considerable noise, and this has been noted in the literature. In [9, 10, 14, 15], the authors proposed to use second and higher-order statistics for topic mining. Particularly, Arora et al. [9, 10] proposed to work with the following matrix: P = E{DDT } = CECT , (2) where E = E{W W T } can be interpreted as a topic-topic correlation matrix. The matrix P is by definition a word-word correlation matrix, but also has a nice interpretation: if D(v, d) denotes the frequency of word v occurring in document d, P (i, j) is the likelihood that term i and j co-occur in a document [9, 10]. There are two advantages in using P : i) if there is zero-mean white noise, it will be significantly suppressed through the averaging process; and ii) the size of P does not grow with the size of the data if the vocabulary is fixed. The latter is a desired property when the number of documents is very large, and we pick a (possibly limited but) manageable vocabulary to work with. Problems with similar structure to that of P also arise in the context of graph models, where communities and correlations appear as the underlying factors. The algorithm proposed in [10] also makes use of Assumption 1 and is conceptually close to Algorithm 1. The work in [13, 14, 15] relaxed the anchor-word assumption. The methods there make use of three or higher-order statistics, e.g., P ∈RV ×V ×V whose (i, j, k)th entry represents the co-occurrence of three terms. The work in [13, 14] showed that P is a tensor satisfying the parallel factor analysis (PARAFAC) model and thus C is uniquely identifiable, if the topics are uncorrelated, which is a restrictive assumption (a counter example would be politics and economy). When the topics are correlated, additional assumptions like sparsity are needed to restore identifiability [15]. Another important concern is that reliable estimates of higher-order statistics require much larger data sizes, and tensor decomposition is computationally cumbersome as well. Remark 1 Among all the aforementioned methods, the deflation-based methods are seemingly more efficient. However, if the deflation procedure in Algorithm 1 (the update of Θ) has constraints like in [8, 11], there is a serious complexity issue: solving a constrained least squares problem with FV variables is not an easy task. Data sparsity is destroyed after the first deflation step, and thus even first-order methods or coordinate descent as in [8, 11] do not really help. This point will be exemplified in our experiments. 3 Anchor-Free Identifiable Topic Mining In this work, we are primarily interested in mining topics from the matrix P because of its noise robustness and scalability. We will formulate topic modeling as an optimization problem, and show 3 that the word-topic matrix C can be identified under a much more relaxed condition, which includes the relatively strict anchor-word assumption as a special case. 3.1 Problem Formulation Let us begin with the model P = CECT , subject to the constraint that each column of C represents the PMF of words appearing in a specific topic, such that CT 1 = 1, C ≥0. Such a symmetric matrix decomposition is in general not identifiable, as we can always pick a non-singular matrix A ∈RF ×F such that AT 1 = 1, A ≥0, and define ˜C = CA, ˜E = A−1CA−1, and then P = ˜C ˜E ˜C T with ˜C T 1 = 1, ˜C ≥0. We wish to find an identification criterion such that under some mild conditions the corresponding solution can only be the ground-truth E and C up to some trivial ambiguities such as a common column permutation. To this end, we propose the following criterion: minimize E∈RF ×F ,C∈RV ×F | det E|, subject to P = CECT , CT 1 = 1, C ≥0. (3) The first observation is that if the anchor-word assumption is satisfied, the optimal solutions of the above identification criterion are the ground-truth C and E and their column-permuted versions. Formally, we show that: Proposition 1 Let (C⋆, E⋆) be an optimal solution of (3). If the separability / anchor-word assumption (cf. Assumption 1) is satisfied and rank(P ) = F, then C⋆= CΠ and E⋆= ΠT EΠ, where Π is a permutation matrix. The proof of Proposition 1 can be found in the supplementary material. Proposition 1 is merely a ‘sanity check’ of the identification criterion in (3): It shows that the criterion is at least a sound one under the anchor-word assumption. Note that, when the anchor-word assumption is satisfied, SPAtype algorithms are in fact preferable over the identification criterion in (3), due to their simplicity. The point of the non-convex formulation in (3) is that it can guarantee identifiability of C and E even when the anchor-word assumption is grossly violated. To explain, we will need the following. Assumption 2 (sufficiently scattered) Let cone(CT )∗denote the polyhedral cone {x : Cx ≥0}, and K denote the second-order cone {x : ∥x∥2 ≤1T x}. Matrix C is called sufficiently scattered if it satisfies that: (i) cone(CT )∗⊆K, and (ii) cone(CT )∗∩bdK = {λef : λ ≥0, f = 1, . . . , F}, where bdK denotes the boundary of K, i.e., bdK = {x : ∥x∥2 = 1T x}. Our main result is based on this assumption, whose first consequence is as follows: Lemma 1 If C ∈RV ×F is sufficiently scattered, then rank(C) = F. In addition, given rank(P ) = F, any feasible solution ˜E ∈RF ×F of Problem (3) has full rank and thus | det ˜E| > 0. Lemma 1 ensures that any feasible solution pair ( ˜C, ˜E) of Problem (3) has full rank F when the ground-truth C is sufficiently scattered, which is important from the optimization perspective – otherwise | det ˜E| can always be zero which is a trivial optimal solution of (3). Based on Lemma 1, we further show that: Theorem 1 Let (C⋆, E⋆) be an optimal solution of (3). If the ground truth C is sufficiently scattered (cf. Assumption 2) and rank(P ) = F, then C⋆= CΠ and E⋆= ΠT EΠ, where Π is a permutation matrix. The proof of Theorem 1 is relegated to the supplementary material. In words, for a sufficiently scattered C and an arbitrary square matrix E, given P = CECT , C and E can be identified up to permutation via solving (3). To understand the sufficiently scattered condition and Theorem 2, it is better to look at the dual cones. The notation cone(CT )∗= {x : Cx ≥0} comes from the fact that it is the dual cone of the conic hull of the row vectors of C, i.e., cone(CT ) = {CT θ : θ ≥0}. A useful property of dual cone is that for two convex cones, if K1 ⊆K2, then K∗ 2 ⊆K∗ 1, which means the first requirement of Assumption 2 is equivalent to K∗⊆cone(CT ). (4) Note that the dual cone of K is another second-order cone [12], i.e., K∗= {x|xT 1 ≥ √ F −1∥x∥2}, which is tangent to and contained in the nonnegative orthant. Eq. (4) and the definition of K∗in 4 (a) separable / anchor word (b) sufficiently scattered (c) not identifiable Figure 1: A graphical view of rows of C (blue dots) and various cones in R3, sliced at the plane 1T x = 1. The triangle indicates the non-negative orthant, the enclosing circle is K, and the smaller circle is K∗. The shaded region is cone(CT ), and the polygon with dashed sides is cone(CT )∗. The matrix C can be identified up to column permutation in the left two cases, and clearly separability is more restrictive than (and a special case of) sufficiently scattered. fact give a straightforward comparison between the proposed sufficiently scattered condition and the existing anchor-word assumption. An illustration of Assumptions 1 and 2 is shown in Fig. 1 (a)-(b) using an F = 3 case, where one can see that sufficiently scattered is much more relaxed compared to the anchor-word assumption: if the rows of the word-topic matrix C are geometrically scattered enough so that cone(CT ) contains the inner circle (i.e., the second-order cone K∗), then the identifiability of the criterion in (3) is guaranteed. However, the anchor-word assumption requires that cone(CT ) fulfills the entire triangle, i.e., the nonnegative orthant, which is far more restrictive. Fig. 1(c) shows a case where rows of C are not “well scattered” in the non-negative orthant, and indeed such a matrix C cannot be identified via solving (3). Remark 2 A salient feature of the criterion in (3) is that it does not need to normalize the data columns to a simplex — all the arguments in Theorem 1 are cone-based. The upshot is clear: there is no risk of amplifying noise or changing the conditioning of P at the factorization stage. Furthermore, matrix E can be any symmetric matrix; it can contain negative values, which may cover more applications beyond topic modeling where E is always nonnegative and positive semidefinite. This shows the surprising effectiveness of the sufficiently scattered condition. The sufficiently scattered assumption appeared in identifiability proofs of several matrix factorization models [17, 18, 19] with different identification criteria. Huang et al. [17] used this condition to show the identifiability of plain NMF, while Fu et al. [19] related the sufficiently scattered condition to the so-called volume-minimization criterion for blind source separation. Note that volume minimization also minimizes a determinant-related cost function. Like the SPA-type algorithms, volume minimization works with data that live in a simplex, therefore applying it still requires data normalization, which is not desired in practice. Theorem 1 can be considered as a more natural application of the sufficiently scattered condition to co-occurrence/correlation based topic modeling, which explores the symmetry of the model and avoids normalization. 3.2 AnchorFree: A Simple and Scalable Algorithm The identification criterion in (3) imposes an interesting yet challenging optimization problem. One way to tackle it is to consider the following approximation: minimize E,C
P −CECT
2 F + µ| det E|, subject to C ≥0, CT 1 = 1, (5) where µ ≥0 balances the data fidelity and the minimal determinant criterion. The difficulty is that the term CECT makes the problem tri-linear and not easily decoupled. Plus, tuning a good µ may also be difficult. In this work, we propose an easier procedure of handling the determinantminimization problem in (3), which is summarized in Algorithm 2, and referred to as AnchorFree. To explain the procedure, first notice that P is symmetric and positive semidefinite. Therefore, one can apply square root decomposition to P = BBT , where B ∈RV ×F . We can take advantage of well-established tools for eigen-decomposition of sparse matrices, and there is widely available software that can compute this very efficiently. Now, we have B = CE1/2Q,QT Q = QQT = I, and E = E1/2E1/2; i.e., the representing coefficients of CE1/2 in the range space of B must be orthonormal because of the symmetry of P . We also notice that minimize E,C,Q | det E1/2Q|, subject to B = CE1/2Q, CT 1 = 1, C ≥0, QT Q = I, (6) 5 has the same optimal solutions as (3). Since Q is unitary, it does not affect the determinant, so we further let M = QT E−1/2 and obtain the following optimization problem maximize M | det M|, subject to M T BT 1 = 1, BM ≥0. (7) By our reformulation, C has been marginalized and we have only F 2 variables left, which is significantly smaller compared to the variable size of the original problem V F + F 2, where V is the vocabulary size. Problem (7) is still non-convex, but can be handled very efficiently. Here, we propose to employ the solver proposed in [18], where the same subproblem (7) was used to solve a dynamical system identification problem. The idea is to apply the co-factor expansion to deal with the determinant objective function, first proposed in the context of non-negative blind source separation [20]: if we fix all the columns of M except the fth one, det M becomes a linear function with respect to M(:, f), i.e., det M = PF k=1(−1)f+kM(k, f) det ¯ M k,f = aT M(:, f), where a = [a1, . . . , aF ]T , ak = (−1)f+k det ¯ M k,f, ∀k = 1, ..., F, and ¯ M k,f is a matrix obtained by removing the kth row and fth column of M. Maximizing |aT x| subject to linear constraints is still a non-convex problem, but we can solve it via maximizing both aT x and −aT x, followed by picking the solution that gives larger absolute objective. Then, cyclically updating the columns of M results in an alternating optimization (AO) algorithm. The algorithm is computationally lightweight: each linear program only involves F variables, leading to a worst-case complexity of O(F 3.5) flops even when the interior-point method is employed, and empirically it takes 5 or less AO iterations to converge. In the supplementary material, simulations on synthetic data are given, showing that Algorithm 2 can indeed recover the ground truth matrix C and E even when matrix C grossly violates the separability / anchor-word assumption. Algorithm 2: AnchorFree input : D, F. P ←Co-Occurrence(D); P = BBT , M ←I; repeat for f = 1, . . . , F do ak = (−1)f+k det ¯ M k,f, ∀k = 1, ..., F; // remove k-th row and f-th column of M to obtain ¯ M k,f mmax = arg maxx aT x s.t. Bx ≥0, 1T Bx = 1; mmin = arg minx aT x s.t. Bx ≥0, 1T Bx = 1; M(:, f) = arg maxmmax,mmin(|aT mmax|, |aT mmin|); end until convergence; C⋆= BM; E⋆= (CT ⋆C⋆)−1CT ⋆P C⋆(CT ⋆C⋆)−1; output:C⋆, E⋆ 4 Experiments Data In this section, we apply the proposed algorithm and the baselines to two popular text mining datasets, namely, the NIST Topic Detection and Tracking (TDT2) and the Reuters-21578 corpora. We use a subset of the TDT2 corpus consisting of 9,394 documents which are single-category articles belonging to the largest 30 categories. The Reuters-21578 corpus is the ModApte version where 8,293 single-category documents are kept. The original vocabulary sizes of the TDT2 and the Reuters dataset are 36, 771 and 18, 933, respectively, and stop words are removed for each trial of the experiments. We use the standard tf-idf data as the D matrix, and estimate the correlation matrix using the biased estimator suggested in [9]. A standard pre-processing technique, namely, normalized-cut weighted (NCW) [21], is applied to D; NCW is a well-known trick for handling the unbalanced-cluster-size problem. For each trial of our experiment, we randomly draw F categories of documents, form the P matrix, and apply the proposed algorithm and the baselines. Baselines We employ several popular anchor word-based algorithms as baselines. Specifically, the successive projection algorithm (SPA) [6], the successive nonnegative projection algorithm (SNPA) [11], the XRAY algorithm [8], and the fast anchor words (FastAnchor) [10] algorithm. Since we are interested in word-word correlation/co-occurrence based mining, all the algorithms are 6 Table 1: Experiment results on the TDT2 corpus. Coh SimCount ClustAcc F FastAchor SPA SNPA XRAY AnchorFree FastAchor SPA SNPA XRAY AnchorFree FastAchor SPA SNPA XRAY AnchorFree 3 -612.72 -613.43 -613.43 -597.16 -433.87 7.98 7.98 7.98 8.94 1.84 0.71 0.74 0.75 0.73 0.98 4 -648.20 -648.04 -648.04 -657.51 -430.07 10.60 11.18 11.18 13.70 2.88 0.70 0.69 0.69 0.69 0.94 5 -641.79 -643.91 -643.91 -665.20 -405.19 13.06 13.36 13.36 22.56 4.40 0.63 0.63 0.62 0.64 0.92 6 -654.18 -645.68 -645.68 -674.30 -432.96 18.94 18.10 18.10 31.56 7.18 0.65 0.58 0.59 0.60 0.91 7 -668.92 -665.55 -665.55 -664.38 -397.77 20.14 18.84 18.84 39.06 4.48 0.62 0.60 0.59 0.58 0.90 8 -681.35 -674.45 -674.45 -657.78 -450.63 24.82 25.14 25.14 40.30 9.12 0.57 0.56 0.58 0.57 0.87 9 -688.54 -671.81 -671.81 -690.39 -416.44 27.50 29.10 29.10 53.68 9.70 0.61 0.58 0.58 0.53 0.86 10 -732.39 -724.64 -724.64 -698.59 -421.25 31.08 29.86 29.86 53.16 13.02 0.59 0.55 0.54 0.49 0.85 15 -734.13 -730.19 -730.19 -773.17 -445.30 51.62 52.62 52.62 59.96 41.88 0.51 0.50 0.50 0.42 0.80 20 -756.90 -747.99 -747.99 -819.36 -461.64 66.26 65.00 65.00 82.92 79.60 0.47 0.47 0.47 0.38 0.77 25 -792.92 -792.29 -792.29 -876.28 -473.95 69.46 66.00 66.00 101.52 133.42 0.46 0.47 0.47 0.37 0.74 Table 2: Experiment results on the Reuters-21578 corpus. Coh SimCount ClustAc F FastAchor SPA SNPA XRAY AnchorFree FastAchor SPA SNPA XRAY AnchorFree FastAchor SPA SNPA XRAY AnchorFree 3 -652.67 -647.28 -647.28 -574.72 -830.24 10.98 11.02 11.02 3.86 7.36 0.66 0.69 0.69 0.66 0.79 4 -633.69 -637.89 -637.89 -586.41 -741.35 16.74 16.92 16.92 9.92 12.66 0.51 0.61 0.61 0.60 0.73 5 -650.49 -652.53 -652.53 -581.73 -762.64 21.74 21.66 21.66 13.06 15.48 0.51 0.55 0.55 0.52 0.65 6 -654.74 -644.34 -644.34 -586.00 -705.60 39.9 39.54 39.54 27.42 19.98 0.47 0.49 0.50 0.46 0.64 7 -733.73 -732.01 -732.01 -612.97 -692.12 47.02 45.24 45.24 34.64 35.62 0.43 0.57 0.57 0.54 0.65 8 -735.23 -738.54 -738.54 -616.32 -726.37 85.04 83.86 83.86 82.52 62.02 0.40 0.53 0.54 0.47 0.61 9 -761.27 -755.46 -755.46 -640.36 -713.81 117.48 118.98 118.98 119.28 72.38 0.37 0.56 0.56 0.47 0.59 10 -764.18 -759.40 -759.40 -656.71 -709.48 119.54 121.74 121.74 130.82 86.02 0.35 0.52 0.52 0.42 0.59 15 -800.51 -801.17 -801.17 -585.18 -688.39 307.86 309.7 309.7 227.02 124.6 0.33 0.40 0.40 0.42 0.53 20 -859.48 -860.70 -860.70 -615.62 -683.64 539.58 538.54 538.54 502.82 225.6 0.31 0.36 0.36 0.38 0.52 25 -889.55 -890.16 -890.16 -633.75 -672.44 674.78 673 673 650.96 335.24 0.26 0.33 0.32 0.37 0.47 combined with the framework provided in [10] and the efficient RecoverL2 process is employed for estimating the topics after the anchors are identified. Evaluation To evaluate the results, we employ several metrics. First, coherence (Coh) is used to measure the single-topic quality. For a set of words V, the coherence is defined as Coh = P v1,v2∈V log (freq(v1,v2)+ϵ/freq(v2)) , where v1 and v2 denote the indices of two words in the vocabulary, freq(v2) and freq(v1, v2) denote the numbers of documents in which v1 appears and v1 and v2 co-occur, respectively, and ϵ = 0.01 is used to prevent taking log of zero. Coherence is considered well-aligned to human judgment when evaluating a single topic — a higher coherence score means better quality of a mined topic. However, coherence does not evaluate the relationship between different mined topics; e.g., if the mined F topics are identical, the coherence score can still be high but meaningless. To alleviate this, we also use the similarity count (SimCount) that was adopted in [10] — for each topic, the similarity count is obtained simply by adding up the overlapped words of the topics within the leading N words, and a smaller SimCount means the mined topics are more distinguishable. When the topics are very correlated (but different), the leading words of the topics may overlap with each other, and thus using SimCount might still not be enough to evaluate the results. We also include clustering accuracy (ClustAcc), obtained by using the mined C⋆matrix to estimate the weights W of the documents, and applying k-means to W . Since the ground-truth labels of TDT2 and Reuters are known, clustering accuracy can be calculated, and it serves as a good indicator of topic mining results. Table 1 shows the experiment results on the TDT2 corpus. From F = 3 to 25, the proposed algorithm (AnchorFree) gives very promising results: for the three considered metrics, AnchorFree consistently gives better results compared to the baselines. Particularly, the ClustAcc’s obtained by AnchorFree are at least 30% higher compared to the baselines for all cases. In addition, the single-topic quality of the topics mined by AnchorFree is the highest in terms of coherence scores; the overlaps between topics are the smallest except for F = 20 and 25. Table 2 shows the results on the Reuters-21578 corpus. In this experiment, we can see that XRAY is best in terms of single-topic quality, while AnchorFree is second best when F > 6. For SimCount, AnchorFree gives the lowest values when F > 6. In terms of clustering accuracy, the topics obtained by AnchorFree again lead to much higher clustering accuracies in all cases. In terms of the runtime performance, one can see from Fig. 2(a) that FastAnchor, SNPA, XRAY and AnchorFree perform similarly on the TDT2 dataset. SPA is the fastest algorithm since it has a recursive update [6]. The SNPA and XRAY both perform nonnegative least squares-based deflation, which is computationally heavy when the vocabulary size is large, as mentioned in Remark 1. AnchorFree uses AO and small-scale linear programming, which is conceptually more difficult compared to SNPA and XRAY. However, since the linear programs involved only have F variables and the number of AO iterations is usually small (smaller than 5 in practice), the runtime performance is quite satisfactory 7 5 10 15 20 25 F 100 101 102 103 Runtime (sec.) FastAnchor SPA SNPA XRAY AnchorFree (a) TDT2 5 10 15 20 25 F 100 101 102 103 Runtime (sec.) FastAnchor SPA SNPA XRAY AnchorFree (b) Reuters-21578 Figure 2: Runtime performance of the algorithms under various settings. Table 3: Twenty leading words of mined topics from an F = 5 case of the TDT2 experiment. FastAnchor AnchorFree anchor anchor predicts slipping cleansing strangled tenday allegations poll columbia gm bulls lewinsky gm shuttle bulls jonesboro lewinsky cnnusa shuttle motors jazz monica motors space jazz arkansas clinton gallup space plants nba starr plants columbia nba school lady allegations crew workers utah grand flint astronauts chicago shooting white clinton astronauts michigan finals white workers nasa game boys hillary presidents nasa flint game jury michigan crew utah teacher monica rating experiments strikes chicago house auto experiments finals students starr lewinsky mission auto jordan clinton plant rats jordan westside house president stories plant series counsel strikes mission malone middle husband approval fix strike malone intern gms nervous michael 11year dissipate starr repair gms michael independent strike brain series fire president white rats idled championship president union aboard championship girls intern monica unit production tonight investigation idled system karl mitchell affair house aboard walkouts lakers affair assembly weightlessness pippen shootings infidelity hurting brain north win lewinskys production earth basketball suspects grand slipping system union karl relationship north mice win funerals jury americans broken assembly lewinsky sexual shut animals night children sexual public nervous talks games ken talks fish sixth killed justice sexual cleansing shut basketball former autoworkers neurological games 13year obstruction affair dioxide striking night starrs walkouts seven title johnson and is close to those of SNPA and XRAY which are greedy algorithms. The runtime performance on the Reuters dataset is shown in Fig. 2(b), where one can see that the deflation-based methods are faster. The reason is that the vocabulary size of the Reuters corpus is much smaller compared to that of the TDT2 corpus (18,933 v.s. 36,771). Table 3 shows the leading words of the mined topics by FastAnchor and AnchorFree from an F = 5 case using the TDT2 corpus. We only present the result of FastAnchor since it gives qualitatively the best benchmark – the complete result given by all baselines can be found in the supplementary material. We see that the topics given by AnchorFree show clear diversity: Lewinsky scandal, General Motors strike, Space Shuttle Columbia, 1997 NBA finals, and a school shooting in Jonesboro, Arkansas. FastAnchor, on the other hand, exhibit great overlap on the first and the second mined topics. Lewinsky also shows up in the fifth topic mined by FastAnchor, which is mainly about the 1997 NBA finals. This showcases the clear advantage of our proposed criterion in terms of giving more meaningful and interpretable results, compared to the anchor-word based approaches. 5 Conclusion In this paper, we considered identifiable anchor-free correlated topic modeling. A topic estimation criterion based on the word-word co-occurrence/correlation matrix was proposed and its identifiability conditions were proven. The proposed approach features topic identifiability guarantee under much milder conditions compared to the anchor-word assumption, and thus exhibits better robustness to model mismatch. A simple procedure that only involves one eigen-decomposition and a few small linear programs was proposed to deal with the formulated criterion. Experiments on real text corpus data showcased the effectiveness of the proposed approach. Acknowledgment This work is supported in part by the National Science Foundation (NSF) under the project numbers NSF-ECCS 1608961 and NSF IIS-1247632 and in part by the Digital Technology Initiative (DTI) Seed Grant, University of Minnesota. 8 References [1] D. M. Blei. Probabilistic topic models. Communications of the ACM, 55(4):77–84, 2012. [2] D. M. Blei, A. Y. Ng, and M. I. Jordan. Latent Dirichlet allocation. Journal of Machine Learning Research, 3:993–1022, 2003. [3] T. L. Griffiths and M. Steyvers. Finding scientific topics. Proceedings of the National Academy of Sciences, 101(suppl 1):5228–5235, 2004. [4] S. Arora, R. Ge, R. Kannan, and A. Moitra. Computing a nonnegative matrix factorization–provably. In ACM symposium on Theory of Computing, pages 145–162. ACM, 2012. [5] B. Recht, C. Re, J. Tropp, and V. Bittorf. Factoring nonnegative matrices with linear programs. In Proc. NIPS 2012, pages 1214–1222, 2012. [6] N. Gillis and S.A. Vavasis. Fast and robust recursive algorithms for separable nonnegative matrix factorization. IEEE Trans. Pattern Anal. Mach. Intell., 36(4):698–714, April 2014. [7] N. Gillis. Robustness analysis of hottopixx, a linear programming model for factoring nonnegative matrices. SIAM Journal on Matrix Analysis and Applications, 34(3):1189–1212, 2013. [8] A. Kumar, V. Sindhwani, and P. Kambadur. Fast conical hull algorithms for near-separable non-negative matrix factorization. In Proc. ICML-12, 2012. [9] S. Arora, R. Ge, and A. Moitra. Learning topic models–going beyond SVD. In Proc. FOCS 2012, pages 1–10. IEEE, 2012. [10] S. Arora, R. Ge, Y. Halpern, D. Mimno, A. Moitra, D. Sontag, Y. Wu, and M. Zhu. A practical algorithm for topic modeling with provable guarantees. In Proc. ICML-13, 2013. [11] N. Gillis. Successive nonnegative projection algorithm for robust nonnegative blind source separation. SIAM Journal on Imaging Sciences, 7(2):1420–1450, 2014. [12] D. Donoho and V. Stodden. When does non-negative matrix factorization give a correct decomposition into parts? In Proc. NIPS 2013, volume 16, 2003. [13] A. Anandkumar, Y.-K. Liu, D. J. Hsu, D. P. Foster, and S. M. Kakade. A spectral algorithm for latent Dirichlet allocation. In Proc. NIPS 2012, pages 917–925, 2012. [14] A. Anandkumar, S. M. Kakade, D. P. Foster, Y.-K. Liu, and D. Hsu. Two SVDs suffice: Spectral decompositions for probabilistic topic modeling and latent Dirichlet allocation. Technical report, 2012. [15] A. Anandkumar, D. J. Hsu, M. Janzamin, and S. M. Kakade. When are overcomplete topic models identifiable? uniqueness of tensor Tucker decompositions with structured sparsity. In Proc. NIPS 2013, pages 1986–1994, 2013. [16] D. Cai, X. He, and J. Han. Locally consistent concept factorization for document clustering. IEEE Trans. Knowl. Data Eng., 23(6):902–913, 2011. [17] K. Huang, N. Sidiropoulos, and A. Swami. Non-negative matrix factorization revisited: Uniqueness and algorithm for symmetric decomposition. IEEE Trans. Signal Process., 62(1):211–224, 2014. [18] K. Huang, N. D. Sidiropoulos, E. E. Papalexakis, C. Faloutsos, P. P. Talukdar, and T. M. Mitchell. Principled neuro-functional connectivity discovery. In Proc. SIAM Conference on Data Mining (SDM), 2015. [19] X. Fu, W.-K. Ma, K. Huang, and N. D. Sidiropoulos. Blind separation of quasi-stationary sources: Exploiting convex geometry in covariance domain. IEEE Trans. Signal Process., 63(9):2306–2320, May 2015. [20] W.-K. Ma, T.-H. Chan, C.-Y. Chi, and Y. Wang. Convex analysis for non-negative blind source separation with application in imaging. In D. P. Palomar and Y. Eldar, editors, Convex Optimization in Signal Processing and Communications, chapter 7, pages 229–265. 2010. [21] Wei Xu, Xin Liu, and Yihong Gong. Document clustering based on non-negative matrix factorization. In Proceedings of the 26th annual international ACM SIGIR conference on Research and development in informaion retrieval, pages 267–273. ACM, 2003. 9 | 2016 | 483 |
6,420 | High Dimensional Structured Superposition Models Qilong Gu Dept of Computer Science & Engineering University of Minnesota, Twin Cities guxxx396@cs.umn.edu Arindam Banerjee Dept of Computer Science & Engineering University of Minnesota, Twin Cities banerjee@cs.umn.edu Abstract High dimensional superposition models characterize observations using parameters which can be written as a sum of multiple component parameters, each with its own structure, e.g., sum of low rank and sparse matrices, sum of sparse and rotated sparse vectors, etc. In this paper, we consider general superposition models which allow sum of any number of component parameters, and each component structure can be characterized by any norm. We present a simple estimator for such models, give a geometric condition under which the components can be accurately estimated, characterize sample complexity of the estimator, and give high probability nonasymptotic bounds on the componentwise estimation error. We use tools from empirical processes and generic chaining for the statistical analysis, and our results, which substantially generalize prior work on superposition models, are in terms of Gaussian widths of suitable sets. 1 Introduction For high-dimensional structured estimation problems [3, 15], considerable advances have been made in accurately estimating a sparse or structured parameter θ ∈Rp even when the sample size n is far smaller than the ambient dimensionality of θ, i.e., n ≪p. Instead of a single structure, such as sparsity or low rank, recent years have seen interest in parameter estimation when the parameter θ is a superposition or sum of multiple different structures, i.e., θ = Pk i=1 θi, where θ1 may be sparse, θ2 may be low rank, and so on [1, 6, 7, 9, 11, 12, 13, 23, 24]. In this paper, we substantially generalize the non-asymptotic estimation error analysis for such superposition models such that (i) the parameter θ can be the superposition of any number of component parameters θi, and (ii) the structure in each θi can be captured by any suitable norm Ri(θi). We will analyze the following linear measurement based superposition model y = X k X i=1 θi + ω , (1) where X ∈Rn×p is a random sub-Gaussian design or compressive matrix, k is the number of components, θi is one component of the unknown parameters, y ∈Rn is the response vector, and ω ∈Rn is random noise independent of X. The structure in each component θi is captured by any suitable norm Ri(·), such that Ri(θi) has a small value, e.g., sparsity captured by ∥θi∥1, low-rank (for matrix θi) captured by the nuclear norm ∥θi∥∗, etc. Popular models such as Morphological Component Analysis (MCA) [10] and Robust PCA [6, 9] can be viewed as a special cases of this framework (see Section D). The superposition estimation problem can be posed as follows: Given (y, X) generated following (1), estimate component parameters {ˆθi} such that all the component-wise estimation errors ∆i = ˆθi−θ∗ i , where θ∗ i is the population mean, are small. Ideally, we want to obtain high-probability non-asymptotic bounds on the total componentwise error measured as Pk i=1 ∥ˆθi −θ∗ i ∥2, with the bound improving (getting smaller) with increase in the number n of samples. 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. We propose the following estimator for the superposition model in (1): min {θ1,...,θk}
y −X k X i=1 θi
2 2 s.t. Ri(θi) ≤αi , i = 1, . . . , k , (2) where αi are suitable constants. In this paper, we focus on the case where αi = Ri(θ∗ i ), e.g., if θ∗ i is s-sparse with ∥θ∗ i ∥2 = 1 and Ri(·) = ∥· ∥1, then αi = √s so that Ri(θ∗ i ) ≤√s, noting that recent advances [16] can be used to extend our results to more general settings. The superposition estimator in (2) succeeds if a certain geometric condition, which we call structural coherence (SC), is satisfied by certain sets (cones) associated with the component norms Ri(·). Since the estimate ˆθi = θ∗ i + ∆i is in the feasible set of the optimization problem (2), the error vector ∆i satisfies the constraint Ri(θ∗ i + ∆i) ≤αi where αi = Ri(θ∗ i ). The SC condition is a geometric relationship between the corresponding error cones Ci = cone{∆i|Ri(θ∗ i + ∆i) ≤Ri(θ∗ i )}. If SC is satisfied, then we can show that the sum of componentwise estimation error can be bounded with high probability, and the bound takes the form: k X i=1 ∥ˆθi −θ∗ i ∥2 ≤cmaxi w(Ci ∩Bp) + √log k √n , (3) where n is the sample size, k is the number of components, and w(Ci ∩Bp) is the Gaussian width [3, 8, 22] of the intersection of the error cone Ci with the unit Euclidean ball Bp ⊆Rp. Interestingly, the estimation error decreases at the rate of 1/√n, similar to the case of single parameter estimators [15, 3], and depends only logarithmically on the number of components k. Further, while dependency of the error on Gaussian width of the error cone has been established in recent results involving a single parameter [3, 22], the bound in (3) depends on the maximum of the Gaussian width of individual error cones, not their sum. The analysis thus gives a general way to construct estimators for superposition problems along with high-probability non-asymptotic upper bounds on the sum of componentwise errors. To show the generality of our work, we review and compare related work in Appendix B. Notation: In this paper, we use ∥.∥to denote vector norm, and |||.||| to denote operator norm. For example, ∥.∥2 is the Euclidean norm for a vector or matrix, and |||.|||∗is the nuclear norm of a matrix. We denote cone{E} as the smallest closed cone that contains a given set E. We denote ⟨., .⟩as the inner product. The rest of this paper is organized as follows: We start with a deterministic estimation error bound in Section 2, while laying down the key geometric and statistical quantities involved in the analysis. In Section 3, we discuss the geometry of the structural coherence (SC) condition, and in Section 4 show that the geometric SC condition implies statistical restricted eigenvalue (RE) condition. In Section 5, we develop the main error bound on the sum of componentwise errors which hold with high probability for sub-Gaussian designs and noise. We apply our error bound to practical problems in Section 6, and present experimental results in Section 7. We conclude in Section 8. In the Appendix, we compare an estimator using “infimal convolution”[18] of norms with our estimator (2) for the noiseless case, and provide some addition examples and experiments. The proofs of all technical results are also in the Appendix. 2 Error Structure and Recovery Guarantees In this section, we start with some basic results and, under suitable assumptions, provide a deterministic bound for the componentwise estimation error in superposition models. Subsequently, we will show that the assumptions made here hold with high probability as long as a purely geometric non-probabilistic condition characterized by structural coherence (SC) is satisfied. Let {ˆθi} be a solution to the superposition estimation problem in (2), {θ∗ i } be the optimal (population) parameters involved in the true data generation process. Let ∆i = ˆθi −θ∗ i be the error vector for component i of the superposition. Our goal is to provide a preliminary understanding of the structure of error sets where ∆i live, identify conditions under which a bound on the total componentwise error Pk i=1 ∥ˆθi −θ∗ i ∥2 will hold, and provide a preliminary version of such a bound, which will be subsequently refined to the form in (3) in Section 5. Since ˆθi = θ∗ i + ∆i lies in the feasible set of (2), 2 as discussed in Section 1, the error vectors ∆i will lie in the error sets Ei = {∆i ∈Rp|Ri(θ∗ i +∆i) ≤ Ri(θ∗ i )} respectively. For the analysis, we will be focusing on the cone of such error sets, given by Ci = cone{∆i ∈Rp|Ri(θ∗ i + ∆i) ≤Ri(θ∗ i )} . (4) Let θ∗= Pk i=1 θ∗ i , ˆθ = Pk i=1 ˆθi, and ∆= Pk i=1 ∆i, so that ∆= ˆθ −θ∗. From the optimality of ˆθ as a solution to (2), we have ∥y −X ˆθ∥2 ≤∥y −Xθ∗∥2 ⇒∥X∆∥2 ≤2ωT X∆, (5) using ˆθ = θ∗+ ∆and y = Xθ∗+ ω. In order to establish recovery guarantees, under suitable assumptions we construct a lower bound to ∥X∆∥2, the left hand side of (5). The lower bound is a generalized form of the restricted eigenvalue (RE) condition studied in the literature [4, 5, 17]. We also construct an upper bound to ωT X∆, the right hand side of (5), which needs to carefully analyze the noise-design (ND) interaction, i.e., between the noise ω and the design X. We start by assuming that a generalized form of RE condition is satisfied by the superposition of errors: there exists a constant κ > 0 such that for all ∆i ∈Ci, i = 1, 2, . . . , k: (RE) 1 √n
X k X i=1 ∆i
2 ≥κ k X i=1 ∥∆i∥2 . (6) The above RE condition considers the following set: H = nPk i=1 ∆i : ∆i ∈Ci, Pk i=1 ∥∆i∥2 = 1 o . (7) which involves all the k error cones, and the lower bound is over the sum of norms of the component wise errors. If k = 1, the RE condition in (6) above simplifies to the widely studied RE condition in the current literature on Lasso-type and Dantzig-type estimators [4, 17, 3] where only one error cone is involved. If we set all components but ∆i to zero, then (6) becomes the RE condition only for component i. We also note that the general RE condition as explicitly stated in (6) has been implicitly used in [1] and [24]. For subsequent analysis, we introduce the set ¯H defined as ¯H = nPk i=1 ∆i : ∆i ∈Ci, Pk i=1 ∥∆i∥2 ≤1 o . (8) noting that H ⊂¯H. The general RE condition in (6) depends on the random design matrix X, and is hence an inequality which will hold with certain probability depending on X and the set H. For superposition problems, the probabilistic RE condition as in (6) is intimately related to the following deterministic structural coherence (SC) condition on the interaction of the different component cones Ci, without any explicit reference to the random design matrix X: there is a constant ρ > 0 such that for all ∆i ∈Ci, i = 1, . . . , k, (SC)
k X i=1 ∆i
2 ≥ρ k X i=1 ∥∆i∥2 . (9) If k = 1, the SC condition is trivially satisfied with ρ = 1. Since most existing literature on highdimensional structured models focus on the k = 1 setting [4, 17, 3], there was no reason to study the SC condition carefully. For k > 1, the SC condition (9) implies a non-trivial relationship among the component cones. In particular, if the SC condition is true, then the sum Pk i=1 ∆i being zero implies that each component ∆i must also be zero. As presented in (9), the SC condition comes across as an algebraic condition. In Section 3, we present a geometric characterization of the SC condition [13], and illustrate that the condition is both necessary and sufficient for accurate recovery of each component. In Section 4, we show that for sub-Gaussian design matrices X, the SC condition in (9) in fact implies that the RE condition in (6) will hold with high probability, after the number of samples crosses a certain sample complexity, which depends on the Gaussian width of the component cones. For now, we assume the RE condition in (6) to hold, and proceed with the error bound analysis. To establish recovery guarantee, following (5), we need an upper bound on the interaction between noise ω and design X [3, 14]. In particular, we consider the noise-design (ND) interaction (ND) sn(γ) = inf s>0 s : sup u∈sH 1 √nωT Xu ≤γs2√n , (10) 3 Figure 1: Geometry of SC condition when k = 2. The error sets E1 and E2 are respectively shown as blue an green squares, and the corresponding error cones are C1 and C2 respectively. −C1 is the reflection of error cone C1. If −C1 and C2 do not share a ray, i.e., the angle α between the cones is larger than 0, then δ0 < 1, and the SC condition will hold. where γ > 0 is a constant, and sH is the scaled version of H where the scaling factor is s > 0. Here, sn(γ) denotes the minimal scaling needed on H such that one obtains a uniform bound over ∆∈sH of the form: 1 nωT X∆≤γs2 n(γ). Then, from the basic inequality in (5), with the bounds implied by the RE condition and the ND interaction, we have 1 √n∥X∆∥2 ≤ 1 √n √ ωT X∆ ⇒ κ k X i=1 ∥∆i∥2 ≤√γsn(γ) , (11) which implies a bound on the component-wise error. The main deterministic bound below states the result formally: Theorem 1 (Deterministic bound) Assume that the RE condition in (6) is satisfied in H with parameter κ. Then, if κ2 > γ, we have Pk i=1 ∥∆i∥2 ≤2sn(γ). The above bound is deterministic and holds only when the RE condition in (6) is satisfied with constant κ such that κ2 > γ. In the sequel, we first give a geometric characterization of the SC condition in Section 3, and show that the SC condition implies the RE condition with high probability in Section 4. Further, we give a high probability characterization of sn(γ) based on the noise ω and design X in terms of the Gaussian widths of the component cones, and also illustrate how one can choose γ in Section 5. With these characterizations, we will obtain the desired component-wise error bound of the form (3). 3 Geometry of Structural Coherence In this section, we give a geometric characterize the structural coherence (SC) condition in (9). We start with the simplest case of two vectors x, y. If they are not reflections of each other, i.e., x ̸= −y, then the following relationship holds: Proposition 2 If there exists a δ < 1 such that −⟨x, y⟩≤δ∥x∥2∥y∥2, then ∥x + y∥2 ≥ q 1−δ 2 (∥x∥2 + ∥y∥2) . (12) Next, we generalize the condition of Proposition 2 to vectors in two different cones C1 and C2. Given the cones, define δ0 = sup x∈C1∩Sp−1,y∈C2∩Sp−1 −⟨x, y⟩. (13) By construction, −⟨x, y⟩≤δ0∥x∥2∥y∥2 for all x ∈C1 and y ∈C2. If δ0 < 1, then (12) continues to hold for all x ∈C1 and y ∈C2 with constant p (1 −δ0)/2 > 0. Note that this corresponds to the SC condition with k = 2 and ρ = p (1 −δ0)/2. We can interpret this geometrically as follows: first reflect cone C1 to get −C1, then δ is the cosine of the minimum angle between −C1 and C2. If δ0 = 1, then −C1 and C2 share a ray, and structural coherence does not hold. Otherwise, δ0 < 1, implying −C1 ∩C2 = {0}, i.e., the two cones intersect only at the origin, and structural coherence holds. For the general case involving k cones, denote δi = sup u∈−Ci∩Sp−1,v∈P j̸=i Cj∩Sp−1 ⟨u, v⟩. (14) In recent work, [13] concluded that if δi < 1 for each i = 1, . . . , k then −Ci and P j̸=i Cj does not share a ray, and the original signal can be recovered in noiseless case. We show that the condition above in fact implies ρ > 0 for the SC condition in (9), which is sufficient for accurate recovery even in the noisy case. In particular, with δ := maxi δi, we have the following result: 4 Theorem 3 (Structural Coherence (SC) Condition) Let δ := maxi δi with δi as defined in (14). If δ < 1, then there exists a ρ > 0 such that for any ∆i ∈Ci, i = 1, . . . , k, the SC condition in (9) holds, i.e.,
Pk i=1 ∆i
2 ≥ρ Pk i=1 ∥∆i∥2 . (15) Thus, the SC condition is satisfied in the general case as long as the reflection −Ci of any cone Ci does not intersect, i.e., share a ray, with the Minkowski sum P j̸=i Cj of the other cones. 4 Restricted Eigenvalue Condition for Superposition Models Assuming that the SC condition is satisfied by the error cones {Ci}, i = 1, . . . , k, in this section we show that the general RE condition in (6) will be satisfied with high probability when the number of samples n in the sub-Gaussian design matrix X ∈Rn×p crosses the sample complexity n0. We give a precise characterization of the sample complexity n0 in terms of the Gaussian width of the set H. Our analysis is based on the results and techniques in [20, 14], and we note that [3] has related results using mildly different techniques. We start with a restricted eigenvalue condition on C. For a random vector Z ∈Rp, we define marginal tail function for an arbitrary set E as Qξ(E; Z) = infu∈E P(|⟨Z, u⟩| ≥ξ) , (16) noting that it is deterministic given the set E ⊆Rp. Let ϵi, i = 1, . . . , n, be independent Rademacher random variables, i.e., random variable with probability 1 2 of being either +1 or −1, and let Xi, i = 1, . . . , n, be independent copies of Z. We define empirical width of E as Wn(E; Z) = supu∈E⟨h, u⟩, where h = 1 √n Pn i=1 ϵiXi . (17) With this notation, we recall the following result from [20]: Lemma 1 Let X ∈Rn×p be a random design matrix with each row the independent copy of sub-Gaussian random vector Z. Then for any ξ, ρ, t > 0, we have inf u∈H ∥Xu∥2 ≥ρξ√nQ2ρξ(H; Z) −2Wn(H; Z) −ρξt (18) with probability at least 1 −e−t2 2 . In order to obtain lower bound of κ in RE condition (6), we need to lower bound Q2ρξ(H; Z) and upper bound Wn(H; Z). To lower bound Q2ρξ(H; Z), we consider the spherical cap A = (Pk i=1 Ci) ∩Sp−1 . (19) From [20, 14], one can obtain a lower bound to Qξ(A; Z) based on the Paley-Zygmund inequality. The Paley-Zygmund inequality lower bound the tail distribution of a random variable by its second momentum. Let u be an arbitrary vector, we use the following version of the inequality. P(|⟨Z, u⟩| ≥2ξ) ≥ [E|⟨Z,u⟩|−2ξ]2 + E|⟨Z,u⟩|2 (20) In the current context, the following result is a direct consequence of SC condition, which shows that Q2ρξ(H; Z) is lower bounded by Qξ(A; Z), which in turn is strictly bounded away from 0 . The proof of Lemma 2 is given in Appendix H.1. Lemma 2 Let sets H and A be as defined in (7) and (19) respectively. If the SC condition in (9) holds, then the marginal tail functions of the two sets have the following relationship: Qρξ(H; Z) ≥Qξ(A; Z). (21) Next we discuss how to upper bound the empirical width Wn(H; Z). Let set E be arbitrary, and random vector g ∼N(0, Ip) be a standard Gaussian random vector in Rp. The Gaussian width [3] of E is defined as w(E) = E sup u∈E ⟨g, u⟩. (22) Empirical width Wn(H; Z) can be seen as the supremum of a stochastic process. One way to upper bound the supremum of a stochastic process is by generic chaining [19, 3, 20], and by using generic 5 chaining we can upper bound the stochastic process by a Gaussian process, which is the Gaussian width. As we can bound Q2ρξ(H; Z) and Wn(H; Z), we come to the conclusion on RE condition. Let X ∈ Rn×p be a random matrix where each row is an independent copy of the sub-Gaussian random vector Z ∈Rp, and where Z has sub-Gaussian norm |||Z|||ψ2 ≤σx [21]. Let α = infu∈Sp−1 E[|⟨Z, u⟩|] so that α > 0 [14, 20]. We have the following lower bound of the RE condition. The proof of Theorem 4 is based on the proof of [20, Theorem 6.3], and we give it in appendix H.2. Theorem 4 (Restricted Eigenvalue Condition) Let X be the sub-Gaussian design matrix that satisfies the assumptions above. If the SC condition (9) holds with a ρ > 0, then with probability at least 1 −exp(−t2/2), we have inf u∈H ∥Xu∥2 ≥c1ρ√n −c2w(H) −c3ρt (23) where c1, c2 and c3 are positive constants determined by σx, σω and α. To get a κ > 0 in (6), one can simply choose t = (c1ρ√n −c2w(H))/2c3ρ. Then as long as n > c4w2(H)/ρ2 for c4 = c2 2/c2 1, we have κ = infu∈H 1 √n∥Xu∥2 ≥1 2 c1ρ −c2 w(H) √n > 0, with high probability. From the discussion above, if SC condition holds and the sample size n is large enough, then we can find a matrix X such that RE condition holds. On the other hand, once there is a matrix X such that RE condition holds, then we can show that SC must also be true. Its proof is give in Appendix H.3. Proposition 5 If X is a matrix such that the RE condition (6) holds for ∆i ∈Ci, then the SC condition (9) holds. Proposition 5 demonstrates that SC condition is a necessary condition for the possibility of RE. If SC condition does not hold, then there is {∆i} such that ∆i ̸= 0 for some i = 1, . . . , k, but ∥Pk i=1 ∆i∥2 = 0 which implies Pk i=1 ∆i = 0. Then for every matrix X, we have X Pk i=1 ∆i = 0, and RE condition is not possible. 5 General Error Bound Recall that the error bound in Theorem 1 is given in terms of the noise-design (ND) interaction sn(γ) = infs>0 n s : supu∈sC 1 √nωT Xu ≤γs2√n o . (24) In this section, we give a characterization of the ND interaction, which yields the final bound on the componentwise error as long as n ≥n0, i.e., the sample complexity is satisfied. Let ω be a centered sub-Gaussian random vector, and its sub-Gaussian norm |||ω|||ψ2 ≤σω. Let X be a row-wise i.i.d. sub-Gaussian random matrix, for each row Z, its sub-Gaussian norm |||Z|||ψ2 ≤σx. The ND interaction can be bounded by the following conclusion, and the proof of lemma 3 is given in appendix I.1. Lemma 3 Let design X ∈Rn×p be a row-wise i.i.d. sub-Gaussian random matrix, and noise ω ∈Rn be a centered sub-Gaussian random vector. Then sn(γ) ≤c w( ¯ H) γ√n . for some constant c > 0 with probability at least 1 −c1 exp(−c2w2( ¯H)) −c3 exp(−c4n). Constant c depends on σx and σω. In lemma 3 and theorem 6, we need the Gaussian width of ¯H and H respectively. From definition, both ¯H and H is related to the union of different cones; therefore bounding the width of ¯H and H may be difficult. We have the following bound of w(H) and w( ¯H) in terms of the width of the component spherical caps. The proof of Lemma 4 is given in Appendix I.2. Lemma 4 (Gaussian width bound) Let H and ¯H be as defined in (7) and (8) respectively. Then, we have w(H) = O maxi w(Ci ∩Sp−1) + √log k and w( ¯H) = O maxi w(Ci ∩Bp) + √log k . By applying lemma 4, we can derive the error bound using the Gaussian width of individual error cone. From our conclusion on deterministic bound in theorem 1, we can choose an appropriate γ such that κ2 > γ. Then, by combining the result of theorem 1, theorem 4, lemma 3 and lemma 4, we have the final form of the bound, as originally discussed in (3): 6 Theorem 6 For estimator (2), let Ci = cone{∆: Ri(θ∗ i + ∆) ≤Ri(θ∗ i )}, design X be a random matrix with each row an independent copy of sub-Gaussian random vector Z, noise ω be a centered sub-Gaussian random vector, and Bp ⊆Rp be the centered unit euclidean ball. If sample size n > c(maxi w2(Ci ∩Sp−1) + log k)/ρ2, then we have with probability at least 1 −η1 k exp(−η2 maxi w2(Ci ∩Sp−1)) −η3 exp(−η4n), Pk i=1 ∥ˆθi −θ∗ i ∥2 ≤C maxi w(Ci∩Bp)+√log k ρ2√n , (25) for constants c, C > 0 that depend on sub-Gaussian norms |||Z|||φ2 and |||ω|||φ2. Thus, assuming the SC condition in (9) is satisfied, the sample complexity and error bound of the estimator depends on the largest Gaussian width, rather than the sum of Gaussian widths. The result can be viewed as a direct generalization of existing results for k = 1, when the SC condition is always satisfied, and the sample complexity and error is given by w2(C1 ∩Sp−1) and w(C1 ∩Bp) [3, 8]. 6 Application of General Bound In this section, we instantiate the general error bounds on Morphological Component Analysis (MCA), and low-rank and sparse matrix decomposition. The comprehensive results are provided in Appendix D. 6.1 Morphological Component Analysis In Morphological Component Analysis [10], we consider the following linear model y = X(θ∗ 1 + θ∗ 2) + ω (26) where vector θ∗ 1 is sparse and θ∗ 2 is sparse under a rotation Q. Consider the following estimator min θ1,θ2 ∥y −X(θ1 + θ2)∥2 2 s.t. ∥θ1∥1 ≤∥θ∗ 1∥1, ∥Qθ2∥1 ≤∥Qθ∗ 2∥1, (27) where vector y ∈Rn is the observation, vectors θ1, θ2 ∈Rp are the parameters we want to estimate, matrix X ∈Rn×p is a sub-Gaussian random design, matrix Q ∈Rp×p is orthogonal. We assume θ∗ 1 and Qθ∗ 2 are s1-sparse and s2-sparse vectors respectively. Function ∥Q.∥1 is still a norm. In general, we can derive the following error bound from Theorem 6: ∥θ1 −θ∗ 1∥2 + ∥θ2 −θ∗ 2∥2 = O max q s1 log p n , q s2 log p n . 6.2 Low-rank and Sparse Matrix Decomposition To recover a sparse matrix and low-rank matrix from their sum [6, 9], one can use L1 norm to induce sparsity and nuclear norm to induce low-rank. These two kinds of norm ensure that the sparsity and the rank of the estimated matrices are small. Suppose we have a rank-r matrix L∗and a sparse matrix S∗with s nonzero entries, S∗, L∗∈Rd1×d2. Our observation Y comes from the following problem Yi = ⟨Xi, L∗+ S∗⟩+ Ei, i = 1, . . . , n, where each Xi ∈Rd1×d2 is a sub-Gaussian random design matrix. Ei is the noise matrix. The estimator takes the form: min L,S n X i=1 (Yi −⟨Xi, L + S⟩)2 s.t. |||L|||∗≤|||L∗|||∗, ∥S∥1 ≤∥S∗∥1. (28) By using Theorem 6, and existing results on Gaussian widths, the error bound is given by ∥L −L∗∥2 + ∥S −S∗∥2 = O max q s log(d1d2) n , q r(d1+d2−r) n . 7 Experimental Results In this section, we confirm the theoretical results in this paper with some simple experiments. We show our experimental results under different settings. In our experiments we focus on MCA when k = 2. The design matrix X are generated from Gaussian distribution such that every entry of X 7 Samples 0 100 200 300 400 500 600 700 800 900 1000 ∥θ1 −θ∗ 1∥2 + ∥θ2 −θ∗ 2∥2 0 0.5 1 1.5 2 2.5 ρ ≥0.026 ρ = 1/ √ 2 ρ = 0 (a) Samples 0 5 10 15 20 25 30 35 40 Fraction of Successful Recovery 0 0.2 0.4 0.6 0.8 1 p=20 p=40 p=80 p=160 (b) Figure 2: (a) Effect of parameter ρ on estimation error when noise ω ̸= 0. We choose the parameter ρ to be 0, 1/ √ 2, and a random sample. (b) Effect of dimension p on fraction of successful recovery in noiseless case. Dimension p varies in {20, 40, 50, 150} subjects to N(0, 1). The noise ω is generated from Gaussian distribution such that every entry of ω subjects to N(0, 1). We implement our algorithm 1 in MATLAB. We use synthetic data in all our experiments, and let the true signal θ1 = (1, . . . , 1 | {z } s1 , 0 . . . , 0), Qθ2 = (1, . . . , 1 | {z } s2 , 0 . . . , 0) We generate our data in different ways for our three experiments. 7.1 Recovery From Noisy Observation In our first experiment, we test the impact of ρ on the estimation error. We choose three different matrices Q, and ρ is determined the choice of Q. The first Q is given by random sampling: we sample a random orthogonal matrix Q such that Qij > 0, and ρ is lower bounded by (42). The second and third Q is given by identity matrix I and its negative −I; therefore ρ = 1/ √ 2 and ρ = 0 respectively. We choose dimension p = 1000, and let s1 = s2 = 1. The number of samples n varied between 1 and 1000. Observation y is given by y = X(θ∗ 1 + θ∗ 2) + ω. In this experiment, given Q, for each n, we generate 100 pairs of X and w. For each (X, w) pair, we get a solution ˆθ1 and ˆθ2. We take the average over all ∥ˆθ1 −θ∗ 1∥2 + ∥ˆθ2 −θ∗ 2∥2. Figure 2(a) shows the plot of number of samples vs the average error. From figure 2(a), we can see that the error curve given by random Q lies between curves given by two extreme cases, and larger ρ gives lower curve. In Appendix E, we provide an additional experiment using k-support norm [2]. 7.2 Recovery From Noiseless Observation In our second experiment, we test how the dimension p affects the successful recovery of true value. In this experiment, we choose different dimension p with p = 20, p = 40, p = 80, and p = 160. We let s1 = s2 = 1. To avoid the impact of ρ, for each sample size n, we sample 100 random orthogonal matrices Q. Observation y is given by y = X(θ∗ 1 + θ∗ 2). For each solution ˆθ1 and ˆθ2 of (41), we calculate the proportion of Q such that ∥ˆθ1 −θ∗ 1∥2 + ∥ˆθ2 −θ∗ 2∥2 ≤10−4. We increase n from 1 to 40, and the plot we get is figure 2(b). From figure 2(b) we can find that the sample complexity required to recover θ∗ 1 and θ∗ 2 increases with dimension p. 8 Conclusions We present a simple estimator for general superposition models and give a purely geometric characterization, based on structural coherence, of when accurate estimation of each component is possible. Further, we establish sample complexity of the estimator and upper bounds on componentwise estimation error and show that both, interestingly, depend on the largest Gaussian width among the spherical caps induced by the error cones corresponding to the component norms. Going forward, it will be interesting to investigate specific component structures which satisfy structural coherence, and also extend our results to allow more general measurement models. Acknowledgements: The research was also supported by NSF grants IIS-1563950, IIS-1447566, IIS-1447574, IIS-1422557, CCF-1451986, CNS- 1314560, IIS-0953274, IIS-1029711, NASA grant NNX12AQ39A, and gifts from Adobe, IBM, and Yahoo. 8 References [1] A. Agarwal, S. Negahban, and M. J. Wainwright. Noisy matrix decomposition via convex relaxation: Optimal rates in high dimensions. The Annals of Statistics, 40(2):1171–1197, 2012. [2] A. Argyriou, R. Foygel, and N. Srebro. Sparse Prediction with the k-Support Norm. In Advances in Neural Information Processing Systems, Apr. 2012. [3] A. Banerjee, S. Chen, F. Fazayeli, and V. Sivakumar. Estimation with Norm Regularization. In Advances in Neural Information Processing Systems, 2014. [4] P. J. Bickel, Y. Ritov, and A. B. Tsybakov. Simultaneous analysis of Lasso and Dantzig selector. The Annals of Statistics, 37(4):1705–1732, 2009. [5] P. Buhlmann and S. van de Geer. Statistics for High Dimensional Data: Methods, Theory and Applications. Springer Series in Statistics. Springer, 2011. [6] E. J. Candès, X. Li, Y. Ma, and J. Wright. Robust principal component analysis? J. ACM, 58(3):1–37, 2011. [7] V. Chandrasekaran, P. A. Parrilo, and A. S. Willsky. Latent variable graphical model selection via convex optimization. The Annals of Statistics, 40(4):1935–1967, 2012. [8] V. Chandrasekaran, B. Recht, P. A. Parrilo, and A. S. Willsky. The Convex Geometry of Linear Inverse Problems. Foundations of Computational Mathematics, 12:805–849, 2012. [9] V. Chandrasekaran, S. Sanghavi, P. a. Parrilo, and A. S. Willsky. Rank-Sparsity Incoherence for Matrix Decomposition. SIAM Journal on Optimization, 21(2):572–596, 2011. [10] D. L. Donoho and X. Huo. Uncertainty principles and ideal atomic decomposition. IEEE Transactions on Information Theory, 47(7):2845–2862, 2001. [11] R. Foygel and L. Mackey. Corrupted Sensing: Novel Guarantees for Separating Structured Signals. IEEE Transactions on Information Theory, 60(2):1223–1247, Feb. 2014. [12] D. Hsu, S. M. Kakade, and T. Zhang. Robust matrix decomposition with sparse corruptions. IEEE Transactions on Information Theory, 57(11):7221–7234, 2011. [13] M. B. McCoy and J. A. Tropp. The achievable performance of convex demixing. arXiv, 2013. [14] S. Mendelson. Learning without concentration. J. ACM, 62(3):21:1–21:25, June 2015. [15] S. N. Negahban, P. Ravikumar, M. J. Wainwright, and B. Yu. A Unified Framework for HighDimensional Analysis of M-Estimators with Decomposable Regularizers. Statistical Science, 27(4):538–557, Nov. 2012. [16] S. Oymak, B. Recht, and M. Soltanolkotabi. Sharp Time–Data Tradeoffs for Linear Inverse Problems. ArXiv e-prints, July 2015. [17] G. Raskutti, M. J. Wainwright, and B. Yu. Restricted Eigenvalue Properties for Correlated Gaussian Designs. Journal of Machine Learning Research, 11:2241–2259, 2010. [18] R. T. Rockafellar. Convex Analysis. Princeton University Press, 1970. [19] M. Talagrand. Upper and Lower Bounds for Stochastic Processes. A Series of Modern Surveys in Mathematics. Springer-Verlag Berlin Heidelberg, 2014. [20] J. A. Tropp. Convex recovery of a structured signal from independent random linear measurements. arXiv, May 2014. [21] R. Vershynin. Introduction to the non-asymptotic analysis of random matrices. In Y. Eldar and G. Kutyniok, editors, Compressed Sensing, pages 210–268. Cambridge University Press, Cambridge, Nov. 2012. [22] R. Vershynin. Estimation in high dimensions: a geometric perspective. Sampling Theory, a Renaissance, pages 3–66, 2015. [23] J. Wright, A. Ganesh, K. Min, and Y. Ma. Compressive principal component pursuit. IEEE International Symposium on Information Theory, pages 1276–1280, 2012. [24] E. Yang and P. Ravikumar. Dirty statistical models. Advances in Neural Information Processing Systems, pages 1–9, 2012. 9 | 2016 | 484 |
6,421 | A Bandit Framework for Strategic Regression Yang Liu and Yiling Chen School of Engineering and Applied Science, Harvard University {yangl,yiling}@seas.harvard.edu Abstract We consider a learner’s problem of acquiring data dynamically for training a regression model, where the training data are collected from strategic data sources. A fundamental challenge is to incentivize data holders to exert effort to improve the quality of their reported data, despite that the quality is not directly verifiable by the learner. In this work, we study a dynamic data acquisition process where data holders can contribute multiple times. Using a bandit framework, we leverage the long-term incentive of future job opportunities to incentivize high-quality contributions. We propose a Strategic Regression-Upper Confidence Bound (SRUCB) framework, a UCB-style index combined with a simple payment rule, where the index of a worker approximates the quality of his past contributions and is used by the learner to determine whether the worker receives future work. For linear regression and a certain family of non-linear regression problems, we show that SR-UCB enables an O p logT/T -Bayesian Nash Equilibrium (BNE) where each worker exerts a target effort level that the learner has chosen, with T being the number of data acquisition stages. The SR-UCB framework also has some other desirable properties: (1) The indexes can be updated in an online fashion (hence computation is light). (2) A slight variant, namely Private SR-UCB (PSR-UCB), is able to preserve (O log−1 T ,O log−1 T )-differential privacy for workers’ data, with only a small compromise on incentives (each worker exerting a target effort level is an O log6 T/ √ T -BNE). 1 Introduction More and more data for machine learning nowadays are acquired from distributed, unmonitored and strategic data sources and the quality of these collected data is often unverifiable. For example, in a crowdsourcing market, a data requester can pay crowd workers to label samples. While this approach has been widely adopted, crowdsourced labels have been shown to degrade the learning performance significantly, see e.g., [19], due to the low quality of the data. How to incentivize workers to contribute high-quality data is hence a fundamental question that is crucial to the longterm viability of this approach. Recent works [2,4,10] have considered incentivizing data contributions for the purpose of estimating a regression model. For example Cai et al. [2] design payment rules so that workers are incentivized to exert effort to improve the quality of their contributed data, while Cummings et al. [4] design mechanisms to compensate privacy-sensitive workers for their privacy loss when contributing their data. These studies focus on a static data acquisition process, only considering one-time data acquisition from each worker. Hence, the incentives completely rely on the payment rule. However, in stable crowdsourcing markets, workers return to receive additional work. Future job opportunities are thus another dimension of incentives that can be leveraged to motive high-quality data contributions. In this paper, we study dynamic data acquisition from strategic agents for regression problems and explore the use of future job opportunities to incentivize effort exertion. 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. In our setting, a learner has access to a pool of workers and in each round decides on which workers to ask for data. We propose a Multi-armed Bandit (MAB) framework, called Strategic RegressionUpper Confidence Bound (SR-UCB), that combines a UCB-style index rule with a simple per-round payment rule to align the incentives of data acquisition with the learning objective. Intuitively, each worker is an arm and has an index associated with him that measures the quality of his past contributions. The indexes are used by the learner to select workers in the next round. While MAB framework is natural for modeling selection problem with data contributors of potentially varying qualities, our setting has two challenges that are distinct from classical bandit settings. First, after a worker contributes his data, there is no ground-truth observation to evaluate how well the worker performs (or reward as commonly referred to in a MAB setting). Second, a worker’s performance is a result of his strategic decision (e.g. how much effort he exerts), instead of being purely exogenously determined. Our SR-UCB framework overcomes the first challenge by evaluating the quality of an agent’s contributed data against an estimator trained on data provided by all other agents to obtain an unbiased estimate of the quality, an idea inspired by the peer prediction literature [11,16]. To address the second challenge, our SR-UCB framework enables a game-theoretic equilibrium with workers exerting target effort levels chosen by the learner. More specifically, in addition to proposing the SR-UCB framework, our contributions include: • We show that SR-UCB helps simplify the design of payment, and successfully incentivizes effort exertion for acquiring data for linear regression. Every worker exerting a targeted effort level (for labeling and reporting the data) is an O p logT/T -Bayesian Nash Equilibrium (BNE). We can also extend the above results to a certain family of non-linear regression problems. • SR-UCB indexes can be maintained in an online fashion, hence are computationally light. • We extend SR-UCB to Private SR-UCB (PSR-UCB) to further provide privacy guarantees, with small compromise on incentives. PSR-UCB is (O log−1 T ,O log−1 T )-differentially private and every worker exerting the targeted effort level is an O log6 T/ √ T -BNE. 2 Related work Recent works have formulated various strategic learning settings under different objectives [2,4,10, 20]. Among these, payment based solutions are proposed for regression problems when data come from workers who are either effort sensitive [2] or privacy sensitive [4]. These solutions induce game-theoretic equilibria where high-quality data are contributed. The basic idea of designing the payment rules is inspired by the much mature literature of proper scoring rules [8] and peer prediction [16]. Both [2] and [4] consider a static data acquisition procedure, while our work focuses on a dynamic data acquisition process. Leveraging the long-term incentive of future job opportunities, our work has a much simpler payment rule than those of [2] and [4] and relaxes some of the restrictions on the learning objectives (e.g., well behaved in [2]), at the cost of a weaker equilibrium concept (approximate BNE in this work vs. dominate strategy in [2]). Multi-armed Bandit (MAB) is a sequential decision making and learning framework which has been extensively studied. It is nearly impossible to survey the entire bandit literature. The seminal work by Lai et al [13] derived lower and upper bounds on asymptotic regret on bandit selection. More recently, finite-time algorithms have been developed for i.i.d. bandits [1] . Different from the classical settings, this work needs to deal with challenges such as no ground-truth observations for bandits and bandits’ rewards being strategically determined. A few recent works [7, 15] also considered bandit settings with strategic arms. Our work differs from these in that we consider a regression learning setting without ground-truth observations, as well as we consider long-term workers whose decisions on reporting data can change over time. Our work and motivations have some resemblance to online contract design problems for a principalagent model [9]. But unlike the online contract design problems, our learner cannot verify the quality of finished work after each task assignment. In addition, instead of focusing on learning the optimal contract, we use bandits mainly to maintain a long-term incentive for inducing high-quality data. 3 Formulation The learner observes a set of feature data X for training. To make our analysis tractable, we assume each x ∈X is sampled uniformly from a unit ball with dimension d: x ∈Rd s.t. ||x||2 ≤1. Each 2 x associates with a ground-truth response (or label) y(x), which cannot be observed directly by the learner. Suppose x and y(x) are related through a function f : Rd →R that y(x) = f(x) + z, where z is a zero-mean noise with variance σz, and is independent of x. For example, for linear regression f(x) = θTx for some θ ∈Rd. The learner would like to learn a good estimate ˜f of f. For the purpose of training, the learner needs to figure out y(x) for different x ∈X. To obtain an estimate ˜y(x) of y(x), the learner assigns each x to a selected worker to obtain a label. Agent model: Suppose we have a set of workers U = {1,2,...,N} with N ≥2. After receiving the labeling task, each worker will decide on the effort level e he wants to exert to generate an outcome – higher effort leads to a better outcome, but is also associated with a higher cost. We assume e has bounded support [0, ¯e] for all worker i ∈U. When deciding on an effort level, a worker wants to maximize his expected payment minus cost for effort exertion. The resulted label ˜y(x) will be given back to the learner. Denote by ˜yi(x,e) the label returned by worker i for data instance x (if assigned) with chosen effort level e. We consider the following effort-sensitive agent model: ˜yi(x,e) = f(x) + z + zi(e), where zi(e) is a zero-mean noise with variance σi(e). σi(e) can be different for different workers, and σi(e) decreases in e,∀i. The z and zi’s have bounded support such that |z|,|zi| ≤Z, ∀i. Without loss of generality, we assume that the cost for exerting effort e is simply e for every worker. Learner’s objective Suppose the learner wants to learn f with the set of samples X. Then the learner finds effort levels e∗for data points in X such that e∗∈argmin{e(x)}x∈X ERROR( ˜f({x, ˜y(x,e(x))}x∈X))+λ·PAYMENT({e(x)}x∈X) , where e(x) is the effort level for sample x, and {˜y(x,e(x))}x∈X is the set of labeled responses for training data X. ˜f(·) is the regression model trained over this data. The learner assigns the data and pay appropriately to induce the corresponding effort level e∗. This formulation resembles the one presented in [2]. The ERROR term captures the expected error of the trained model using collected data (e.g., measure in squared loss), while the PAYMENT term captures the total expected budget that the learner spends to receive the labels. This payment quantity depends on the mechanism that the learner chooses to use and is the expected payment of the mechanism to induce selected effort level for each data point {e(x)}x∈X. λ > 0 is a weighting factor, which is a constant. It is clear that the objective function depends on σi’s. We assume for now that the learner knows σi(·)’s,1 and the optimal e∗can be computed. 4 StrategicRegression-UCB (SR-UCB): A general template We propose SR-UCB for solving the dynamic data acquisition problem. SR-UCB enjoys a bandit setting, where we borrow the idea from the classical UCB algorithm [1], which maintains an index for each arm (worker in our setting), balancing exploration and exploitation. While a bandit framework is not necessarily the best solution for our dynamic data acquisition problem, it is a promising option for the following reasons. First, as utility maximizers, workers would like to be assigned tasks as long as the marginal gain for taking a task is positive. A bandit algorithm can help execute the assignment process. Second, carefully designed indexes can potentially reflect the amount of effort exerted by the agents. Third, because the arm selection (of bandit algorithms) is based on the indexes of workers, it introduces competition among workers for improving their indexes. SR-UCB contains the following two critical components: Per-round payment For each worker i, once selected to label a sample x, we will assign a base payment pi = ei +γ, 2 after reporting the labeling outcome, where ei is the desired effort level that we would like to induce from worker i (for simplicity we have assumed the cost for exerting effort ei equals to the effort level), and γ > 0 is a small quantity. The design of this base payment is to ensure once selected, a worker’s base cost will be covered. Note the above payment depends on neither the assigned data instance x nor the reported outcome ˜y. Therefore such a payment procedure can be pre-defined after the learner sets a target effort level. 1This assumption can be relaxed. See our supplementary materials for the case with homogeneous σ. 2We assume workers have knowledge of how the mechanism sets up this γ. 3 Assignment The learner assigns multiple task {xi(t)}i∈d(t) at time t, with d(t) denoting the set of workers selected at t. Denote by ei(t) the effort level worker i exerted for xi(t), if i ∈d(t). Note all {xi(t)}i∈d(t) are different tasks, and each of them is assigned to exactly one worker. The selection of workers will depend on the notion of indexes. Details are given in Algorithm 1. Algorithm 1 SR-UCB: Worker index & selection Step 1. For each worker i, first train estimator ˜f−i,t using data {xj(n) : 1 ≤n ≤t −1, j ∈d(n), j ̸= i}, that is using the data collected from workers j ̸= i up to time t −1. When t = 1, we will initialize by sampling each worker at least once such that ˜f−i,t can be computed. Step 2. Then compute the following index for worker i at time t Ii(t) = 1 ni(t) t ∑ n=1 1(i ∈d(n)) a−b ˜f−i,t(xi(n))−˜yi(n,ei(n)) 2 +c s logt ni(t) , where ni(t) is the number of times worker i has been selected up to time t. a,b are two positive constants for “scoring”, and c is a normalization constant. ˜yi(n,ei(n)) is the corresponding label for task xi(n) with effort level ei(n), if i ∈d(n). Step 3. Based on the above index, we select d(t) at time t such that d(t) := { j : Ij(t) ≥maxi Ii(t)− τ(t)}, where τ(t) is a perturbation term decreasing in t. Some remarks on SR-UCB: (1) Different from the classical bandit setting, when calculating the indexes, there is no ground-truth observation for evaluating the performance of each worker. Therefore we adopt the notion of scoring rule [8]. Particularly the one we used above is the well-known Brier scoring rule: B(p,q) = a −b(p −q)2 . (2) The scoring rule based index looks similar to the payment rules studied in [2,4]. But as we will show later, under our framework the selection of a,b is much less sensitive to different problem settings, as with an index policy, only the relative values matter (ranking). This is another benefit of separating payment from selection. (3) Instead of only selecting the best worker with the highest index, we select workers whose index is within a certain range of the maximum one (a confidence region). This is because workers may have competing expertise level and hence selecting only one of them would de-incentivize workers’ effort exertion. 4.1 Solution concept Denote by e(n) := {e1(n),...,eN(n)}, and e−i(n) = {ej(n)}j̸=i. We define approximate Bayesian Nash Equilibrium as our solution concept: Definition 1. Suppose SR-UCB runs for T stages. {ei(t)}N,T i=1,t=1 is a π-BNE if ∀i,{˜ei(t)}T t=1: 1 T E[ T ∑ t=1 (pi −ei(t))1(i ∈d(t)) {e(n)}n≤t] ≥1 T E[ T ∑ t=1 (pi −˜ei(t))1(i ∈d(t)) {˜ei(n),e−i(n)}n≤t]−π. This is to say by deviating, each worker will gain no more than π net-payment per around. We will establish our main results in terms of π-BNE. The reason we adopt such a notion is that in a sequential setting it is generally hard to achieve strict BNE or other stronger notion as any one-step deviation may not affect a long-term evaluation by much.3 Approximate BNE is likely the best solution concept we can hope for. 5 Linear regression 5.1 Settings and a warm-up scenario In this section we present our results for a simple linear regression task where the feature x and observation y are linearly related via an unknown θ: y(x) = θTx+z, ∀x ∈X. Let’s start with assuming all workers are statistically identical such that σ1 = σ2 = ... = σN. This is an easier case that serves as a warm-up. It is known that given training data, we can find an estimation ˜θ that minimizes a 3Certainly, we can run mechanisms that induce BNE or dominant-strategy equilibrium for one-shot setting, e.g. [2], for every time step. But such solution does not incorporate long-term incentives. 4 non-regularized empirical risk function: ˜θ = argminˆθ∈Rd ∑x∈X(y(x)−ˆθTx)2 (linear least square). To put this model into SR-UCB, denote ˜θ−i(t) as the linear least square estimator trained using data from workers j ̸= i up to time t −1. And Ii(t) := Si(t)+c p logt/ni(t), with Si(t) := 1 ni(t) t−1 ∑ n=1 1(i ∈d(n)) a−b ˜θT −i(t)xi(n)−˜yi(n,ei(n)) 2 . (5.1) Suppose ||θ||2 ≤M. Given ||x||2 ≤1 and |z|, |zi| ≤Z, we then prove that ∀t,n,i, (˜θT −i(t)xi(n) − ˜yi(n,ei(n)))2 ≤8M2 +2Z2. Choose a,b such that a−(8M2 +2Z2)b ≥0, then we have 0 ≤Si(t) ≤ a, ∀i,t. For the perturbation term, we set τ(t) := O p logt/t . The intuition is that with t samples, the uncertainties in the indexes, coming from both the score calculation and the bias term, can be upper bounded at the order of O p logt/t . Thus, to not miss a competitive worker, we set the tolerance to be at the same order. We now develop the formal equilibrium result of SR-UCB for linear least square. Our analysis requires the following assumption on the smoothness of σ. Assumption 1. We assume σ(e) is convex on e ∈[0, ¯e], with gradient σ′(e) being both upper bounded, and lower bounded away from 0, i.e., L ≥|σ′(e)| ≥L > 0, ∀e. The learner wants to learn f with a total of NT (= |X| or ⌈NT⌉= |X|) samples. Since workers are statistically equivalent, ideally the learner would like to run SR-UCB for T steps and collect a label for a unique sample from each worker at each step. Hence, the learner would like to elicit a single target effort level e∗from all workers and for all samples: e∗∈argmineEx,y,˜y θT({xi(n), ˜yi(n,e)}N,T i=1,n=1)·x−y 2 +λ·(e+γ)NT. (5.2) Due to the uncertainty in worker selection, it is highly likely that after step T, there will be tasks left unlabelled. We can let the mechanism go for extra steps to complete labelling of these tasks. But due to the bounded number of missed selections as we will show later, stopping at step T won’t affect the accuracy in the model trained. Theorem 1. Under SR-UCB for linear least square, set fixed payment pi = e∗+ γ for all i, where γ = Ω( p logT/T), choose c to be a large enough constant, c ≥Const.(M,Z,N,b), and let τ(t) := O p logt/t . Workers have full knowledge of the mechanism and the values of the parameters. Then at an O p logT/T -BNE, workers, whenever selected, exert effort ei(t) ≡e∗for all i and t. The net payment (payment minus the cost of effort) per task can be made arbitrarily small by setting γ exactly on the order of O p logT/T , and pi −e∗= γ = O p logT/T →0, as T →∞. Our solution heavily relies on forming a race among workers. By establishing the convergence of bandit indexes to a function of effort (via σ(·)), we show that when other workers j ̸= i follow the equilibrium strategy, worker i will be selected w.h.p. at each round, if he also puts in the same amount of effort. On the other hand, if worker i shirks from doing so by as much as (O p logT/T ), his number of selection will go down in order. This establishes the π-BNE. As long as there exists one competitive worker, all others will be incentivized to exert effort. Though as will be shown in the next section, all workers shirking from exerting effort is also an O p logT/T -BNE. This equilibrium can be removed by adding some uncertainty on top of the bandit selection procedure. When there are ≥2 workers being selected in SR-UCB, each of them will be assigned a task with certain probability 0 < ps < 1. While when there is a single selected worker, the worker is assigned a task w.p. 1. Set ps := 1−O p logT/T/γ . So with probability 1−ps = O p logT/T/γ , even the “winning”workers will miss the selection. With this change, exerting e∗still forms an O p logT/T -BNE, while every worker exerting any effort level that is ∆e > O γ lower than the target effort level is not a π-BNE with π ≤O p logT/T . 5 5.2 Linear regression with different σ Now we consider the more realistic case that different workers have different noise-effort function σ’s. W.l.o.g., we assume σ1(e) < σ2(e) < ... < σN(e),∀e.4 In such a setting, ideally we would always like to collect data from worker 1 since he has the best expertise level (lowest variance in labeling noise). Suppose we are targeting an effort level e∗ 1 from data source 1 (the best data source). We first argue that we also need to incentivize worker 2 to exert competitive effort level e∗ 2 such that σ1(e∗ 1) = σ2(e∗ 2), and we assume such an e∗ 2 exists.5 This also naturally implies that e∗ 2 > e∗ 1 as worker 1 contributes data with less variance in noise at the same effort level. The reason is similar to the homogeneous setting—over time workers form a competition on σi(ei). Having a competitive peer will motivate workers to exert as much effort as he can (up to the payment). Therefore the goal for such a learner (with 2T samples to assign) is to find an effort level e∗such that 6 e∗∈argmine2:σ1(e1)=σ2(e2)Ex,y,˜y θT({xi(n), ˜yi(n,ei))}2,T i=1,n=1)x−y 2 +λ·(e2 +γ)2T. Set the one-step payment to be pi = e∗+ γ,∀i. Let e∗ 1 be the solution to σ1(e∗ 1) = σ2(e∗) and let e∗ i = e∗for i ≥2. Note for i > 2 we have σi(e∗ i ) −σ1(e∗ 1) > 0. While we have argued about the necessity for choosing the top two most competitive workers, we have not mentioned the optimality of doing so. In fact selecting the top two is the best we can do. Suppose on the contrary, the optimal solution is by selecting top k > 2 workers, at effort level ek. According to our solution, we targeted the effort level that leads to variance of noise σk(ek) (so the least competitive worker will be incentivized). Then we can simply target the same effort level ek, but migrating the task loads to only the top two workers – this keeps the payment the same, but the variance of noise now becomes σ2(ek) < σk(ek), which leads to better performance. Denote ∆1 := σ3(e∗)−σ1(e∗ 1) > 0 and assume Assumption 1 applies to all σi’s. We prove: Theorem 2. Under SR-UCB for linear least square, set c ≥Const.(M,Z,b,∆1), Ω( p logT/T) = γ ≤∆1 2L, τ(t) := O p logt/t . Then, each worker i exerting effort e∗ i once selected forms an O p logT/T -BNE. Performance with acquired data If workers follow the π-BNE, the contributed data from the top two workers (who have been selected the most number of times) will have the same variance σ1(e∗ 1). Then following results in [4], w.h.p. the performance of the trained classifier is bounded by O σ1(e∗ 1)/(∑i=1,2 ni(T))2 . Ideally we want to have ∑i=1,2 ni(T) = 2T, such that an upper bound of O σ1(e∗ 1)/(2T)2 can be achieved. Compared to the bound O σ1(e∗ 1)/(2T)2 , SR-UCB’s expected performance loss (due to missed sampling & wrong selection, which is bounded at the order of O logT ) is bounded by E[σ1(e∗ 1)/(∑i=1,2 ni(T))2 −σ1(e∗ 1)/(2T)2] ≤O σ1(e∗ 1)logT/T 3 w.h.p. . Regularized linear regression Ridge estimator has been widely adopted for solving linear regression. The objective is to find a linear model ˜θ that minimizes the following regularized empirical risk: ˜θ = argminˆθ∈Rd ∑x∈X(y(x) −ˆθTx)2 + ρ||ˆθ||2 2 , with ρ > 0 being the regularization parameter. We claim that simply changing the ˜f−i,t(·) in SR-UCB to the output from the above ridge regression, the O p logT/T -BNE for inducing an effort level e∗will hold. Different from the non-regularized case, the introduction of the regularization term will add bias in ˜θT −i(t), which gives a biased evaluation of indexes. However, we prove the convergence of ˜θT −i(t) (so again the indexes will converge properly) in the following lemma, which enables an easy adaption of our previous results for nonregularized case to ridge regression: Lemma 1. With n i.i.d. samples, w.p. ≥1−e−Kn (K > 0 is a constant), ||˜θ−i(t)−θ||2 2 ≤O 1 n2 . Non-linear regression The basic idea for extending the results to non-linear regression is inspired by the consistency results on M-estimator [14], when the error of training data satisfies zero mean. Similar to the reasoning for Lemma 1, if ( ˜f−i,t(x)−f(x))2 →0, we can hope for an easy adaptation 4Combing with the results for homogeneous workers, we can again easily extend our results to the case where there are a mixture of homogeneous and heterogenous workers. 5It exists when the supports for σ1(·),σ2(·) overlap for a large support range. 6Since we only target the top two workers, we can limit the number of acquisitions on each stage to be no more than two, so the number of query does not go beyond 2T. 6 of our previous results. Suppose the non-linear regression model can be characterized by a parameter family Θ, where f is characterized by parameter θ, and ˜f−i,t by ˜θi(t). Due to the consistency of M-estimator we will have ||˜θi(t) −θ||2 →0. More specifically, according to the results from [18], for the non-linear regression model we can establish an O 1/√n convergence rate with n training samples. When f is Lipschitz in parameter space, i.e. there exists a constant LN > 0 such that | ˜f−i,t(x) −f(x)| ≤LN||˜θi(t) −θ||2, by dominated convergence theorem we also have ( ˜f−i,t(x)−f(x))2 →0, and ( ˜f−i,t(x)−f(x))2 ≤O 1/t . The rest of the proof can then follow. Example 1. Logistic function f(x) = 1 1+e−θT x satisfies Lipschitz condition with LN = 1/4. 6 Computational issues In order to update the indexes and select workers adaptively, we face a few computational challenges. First, in order to update the index for each worker at any time t, a new estimator ˜θ−i(t) (using data from all other workers j ̸= i up to time t −1) needs to be re-computed. Second, we need to re-apply ˜θ−i(t) to every collected sample from worker i,{(xi(n), ˜yi(n,ei(n)) : i ∈d(n),n = 1,2,...t −1} from previous rounds. We propose online variants of SR-UCB to address these challenges. Online update of ˜θ−i(·) Inspired by the online learning literature, instead of re-computing ˜θ−i(t) at each step, which involves re-calculating the inverse of a covariance matrix (e.g., (ρI + XTX)−1 for ridge regression) whenever there is a new sample point arriving, we can update ˜θ−i(t) in an online fashion, which is computationally much more efficient. We demonstrate our results with ridge linear regression. Start with an initial model ˜θonline −i (1). Denote by (x−i(t), ˜y−i(t)) any newly arrived sample at time t from worker j ̸= i. Update ˜θonline −i (t +1) (for computing Ii(t +1)) as [17]: ˜θonline −i (t +1) := ˜θonline −i (t)−ηt ·∇˜θonline −i (t)[(θTx−i(t)−˜y−i(t))2 +ρ||θ||2 2] , Notice there could be multiple such data points arriving at each time – in which case we will update sequentially in an arbitrarily order. It is also possible that there is no sample point arriving from workers other than i at a time t, in which case we simply do not perform an update. Name this online updating SR-UCB as OSR1-UCB. With online updating, the accuracy of trained model ˜θonline −i (t +1) converges slower, so is the accuracy in the index for characterizing worker’s performance. Nevertheless we prove exerting targeted effort exertion e∗is O p logT/T -BNE under OSR1-UCB for ridge regression, using convergence results for ˜θonline −i (t) proved in [17]. Online score update Online updating can also help compute Si(t) (in Ii(t)) efficiently. Instead of repeatedly re-calculating the score for each data point (in Si(t)), we only update the newly assigned samples which has not been evaluated yet, by replacing ˜θonline −i (t) with ˜θonline −i (n) in Si(t): Sonline i (t) := 1 ni(t) t ∑ n=1 1(i ∈d(n))[a−b((˜θonline −i (n))Txi(n)−˜yi(n,ei(n)))2]. (6.1) With less aggressive update, again the index term’s accuracy converges slower than before, which is due to the fact the older data is scored using an older (and less accurate) version of ˜θonline −i without being further updated. We propose OSR2-UCB where we change the index SR-UCB to: Sonline i (t)+ c p (logt)2/ni(t), to accommondate the slower convergence. We establish an O logT/ √ T -BNE for workers exerting target effort—the change is due to the change of the bias term. 7 Privacy preserving SR-UCB With a repeated data acquisition setting, workers’ privacy in data may leak repeatedly. In this section we study an extension of SR-UCB to preserve privacy of each individual worker’s contributed data. Denote the training data collected as D := {˜yi(t,ei(t))}i∈d(t),t. We quantify privacy using differential privacy [5], and we adopt (ε,δ)-differential privacy (DP) [6], which for our setting is defined below: Definition 2. A mechanism M : (X ×R)|D| →O is (ε,δ)-differentially private if for any i ∈d(t),t, any two distinct ˜yi(t,ei(t)), ˜y′ i(t,e′ i(t)), and for every subset of possible outputs S ⊆O, Pr[M (D) ∈ S] ≤exp(ε)Pr[M (D\{˜yi(t,ei(t))}, ˜y′ i(t,e′ i(t))) ∈S]+δ. 7 An outcome o ∈O of a mechanism contains two parts, both of which can contribute to privacy leakage: (1) The learned regression model ˜θ(T), which is trained using all data collected after T rounds. Suppose after learning the regression model ˜θ(T), this information will be released for public usage or monitoring. This information contains each individual worker’s private information. Note this is a one-shot leak of privacy (published at the end of the training (step T)). (2) The indexes can reveal private information. Each worker i’s data will be utilized towards calculating other workers’ indexes Ij(t), j ̸= i, as well as his own Ii(t), which will be published.7 Note this type of leakage occurs at each step. The lemma below allows us to focus on the privacy losses in Sj(t), instead of Ij(t), as both Ij(t) and ni(t) are functions of {Sj(n)}n≤t. Lemma 2. At any time t, ∀i, ni(t) can be written as a function of {Sj(n),n < t}j. Preserving privacy in ˜θ(T) To protect privacy in ˜θ(T), following standard method [6], we add a Laplacian noise vector vθ to it: ˜θp(T) = ˜θ(T) + vθ, where Pr(vθ) ∝exp(−εθ||vθ||2). εθ > 0 is a parameter controlling the noise level. Lemma 3. Set εθ = 2 √ T, the output ˜θp(T) of SR-UCB for linear regression preserves (O T −1/2 ,exp(−O T ))-DP. Further w.p. ≥1−1/T 2, ||˜θp(T)−˜θ(T)||2 = ||vθ||2 ≤logT/ √ T . Preserving privacy in {Ii(t)}i,t: a continual privacy preserving model For indexes {Ii(t)}i, it is also tempting to add vi(t) to each index, i.e. Ii(t) := Ii(t) + vi(t), where again vi(t) is a zeromean Laplacian noise. However releasing {Ii(t)}i at each step will release a noisy version of each ˜yi(n,ei(n)),i ∈d(n),∀n < t. The composition theory in differential privacy [12] implies that the preserved privacy level will grow in time t, unless we add significant noise on each stage, which will completely destroy the informativeness of our index policy. We borrow the partial sum idea for continual observations [3]. The idea is when releasing continual data, instead of inserting noise at every step, the current to-be-released data will be decoupled into sum of partial sums, and we only add noise to each partial sum and this noisy version of the partial sums can be re-used repeatedly. We consider adding noise to a modified version of the online indexes {Sonline i (t)}i,t as defined in Eqn. (6.1), with ˜θonline −i (t) replaced by ∑t n=1 ˜θ−i(n)/t, where ˜θ−i(n) is the regression model we estimated using all data from worker j ̸= i up to time n. For each worker i, his contributed data appear in both {Sonline i (t)}t and{Sonline j (t)}t, j ̸= i. For Sonline j (t), j ̸= i, we want to preserve privacy in ∑t n=1 ˜θ−j(n)/t, which contains information of ˜yi(n,ei(n)). We first apply the partial sums idea to ∑t n=1 ˜θ−j(n)/t. Write down t as a binary string and find the rightmost digit that is a 1, then flip that digit to 0: convert is back to decimal gives q(t). Take the sum from q(t) + 1 to t: ∑t n=q(t)+1 ˜θ−j(n) as one partial sum. Repeat above for q(t), to get q(q(t)), and the second partial sum ∑ q(t) n=q(q(t))+1 ˜θ−j(n), until we reach q(·) = 0. So t ∑ n=1 ˜θ−j(n)/t = 1 t ( t ∑ n=q(t)+1 ˜θ−j(n)+ q(t) ∑ n=q(q(t))+1 ˜θ−j(n)+...+ 0 ∑ n=0 ˜θ−j(n)) . (7.1) Add noise v˜θ with Pr(v˜θ) ∝e−ε||v˜θ||2 to each partial sum. The number of noise terms is bounded by ≤⌈logt⌉at time t. So is the number of appearance of each private data in the partial sums [3]. Denote the noisy version of ∑t n=1 ˜θ−j(n)/t as ˜˜θonline −i (n). Each Sonline i (t) is computed using ˜˜θonline −i (n). For Sonline i (t), we also want to preserve privacy in ˜yi(n,ei(n)). Clearly Sonline i (t) can be written as sum of partial sums of terms involving ˜yi(n,ei(n)): write Sonline i (t) as a summation: ∑ ni(t) n=1 dS(n)/ni(t) (short-handing dS(n) := a−b((˜˜θonline −i (t(n)))Txi(t(n))−˜yi(t(n),ei(t(n))))2, where t(n) denotes the time of worker i being sampled the n-th time.). Decouple Sonline i (t) into partial sums using the same technique. For each partial sum, add a noise vS with distribution Pr(vS) ∝e−ε|vS|. We then show that with the above two noise exertion procedures, our index policy SR-UCB will not lose its value in incentivizing effort. In order to prove similar convergence results, we need to modify SR-UCB by changing the index to the following format: Ii(t) = ˆSonline i (t)+c(log3t log3 T)/ p ni(t), τ(t) = O (log3t log3 T)/ √ t , 7It is debatable whether the indexes should be published or not. But revealing decisions on worker selection will also reveal information on the indexes. We consider the more direct scenario – indexes are published. 8 where ˆSonline i (t) denotes the noisy version of Sonline i (t) with added noises ( vS,v˜θ etc). The change of bias is mainly to incorporate the increased uncertainty level (due to added privacy preserving noise). Denote this mechanism as PSR-UCB, we have: Theorem 3. Set ε := 1/log3 T for added noises (both vS and v˜θ), PSR-UCB preserves (O log−1 T ,O log−1 T )-DP for linear regression. With homogeneous workers, we similarly can prove exerting effort {e∗ i }i (optimal effort level) is O log6 T/ √ T -BNE. We can see that, in order to protect privacy in the bandit setting, the approximation term of BNE is worse than before. Acknowledgement: We acknowledge the support of NSF grant CCF-1301976. References [1] Peter Auer, Nicolo Cesa-Bianchi, and Paul Fischer. Finite-time analysis of the multiarmed bandit problem. Machine learning, 47(2-3):235–256, 2002. [2] Yang Cai, Constantinos Daskalakis, and Christos H Papadimitriou. Optimum statistical estimation with strategic data sources. arXiv preprint arXiv:1408.2539, 2014. [3] T-H Hubert Chan, Elaine Shi, and Dawn Song. Private and continual release of statistics. ACM Transactions on Information and System Security (TISSEC), 14(3):26, 2011. [4] Rachel Cummings, Stratis Ioannidis, and Katrina Ligett. Truthful linear regression. In Proceedings of The 28th Conference on Learning Theory, COLT 2015, pages 448–483, 2015. [5] Cynthia Dwork. Differential privacy. In Automata, languages and programming. 2006. [6] Cynthia Dwork and Aaron Roth. The algorithmic foundations of differential privacy. [7] Arpita Ghosh and Patrick Hummel. Learning and incentives in user-generated content: Multiarmed bandits with endogenous arms. In Proceedings of the 4th conference on Innovations in Theoretical Computer Science, pages 233–246. ACM, 2013. [8] Tilmann Gneiting and Adrian E Raftery. Strictly proper scoring rules, prediction, and estimation. Journal of the American Statistical Association, 102(477):359–378, 2007. [9] Chien-Ju Ho, Aleksandrs Slivkins, and Jennifer Wortman Vaughan. Adaptive contract design for crowdsourcing markets: Bandit algorithms for repeated principal-agent problems. In Proceedings of the fifteenth ACM EC, pages 359–376. ACM, 2014. [10] Stratis Ioannidis and Patrick Loiseau. Linear regression as a non-cooperative game. In Web and Internet Economics, pages 277–290. Springer, 2013. [11] Radu Jurca and Boi Faltings. Collusion-resistant, incentive-compatible feedback payments. In Proceedings of the 8th ACM conference on Electronic commerce, pages 200–209. ACM, 2007. [12] Peter Kairouz, Sewoong Oh, and Pramod Viswanath. The composition theorem for differential privacy. arXiv preprint arXiv:1311.0776, 2013. [13] Tze Leung Lai and Herbert Robbins. Asymptotically efficient adaptive allocation rules. Advances in applied mathematics, 6(1):4–22, 1985. [14] Guy Lebanon. m-estimators and z-estimators. [15] Yishay Mansour, Aleksandrs Slivkins, and Vasilis Syrgkanis. Bayesian incentive-compatible bandit exploration. In Proceedings of the Sixteenth ACM EC, pages 565–582. ACM, 2015. [16] Nolan Miller, Paul Resnick, and Richard Zeckhauser. Eliciting informative feedback: The peer-prediction method. Management Science, 51(9):1359–1373, 2005. [17] Alexander Rakhlin, Ohad Shamir, and Karthik Sridharan. Making gradient descent optimal for strongly convex stochastic optimization. arXiv preprint arXiv:1109.5647, 2011. [18] BLS Prakasa Rao. The rate of convergence of the least squares estimator in a non-linear regression model with dependent errors. Journal of Multivariate Analysis, 1984. [19] Victor S Sheng, Foster Provost, and Panagiotis G Ipeirotis. Get another label? improving data quality and data mining using multiple, noisy labelers. In Proceedings of the 14th ACM SIGKDD international conference on Knowledge discovery and data mining, 2008. [20] Panos Toulis, David C. Parkes, Elery Pfeffer, and James Zou. Incentive-Compatible Experimental Design. Proceedings 16th ACM EC’15, pages 285–302, 2015. 9 | 2016 | 485 |
6,422 | Linear Relaxations for Finding Diverse Elements in Metric Spaces Aditya Bhaskara University of Utah bhaskara@cs.utah.edu Mehrdad Ghadiri Sharif University of Technology ghadiri@ce.sharif.edu Vahab Mirrokni Google Research mirrokni@google.com Ola Svensson EPFL ola.svensson@epfl.ch Abstract Choosing a diverse subset of a large collection of points in a metric space is a fundamental problem, with applications in feature selection, recommender systems, web search, data summarization, etc. Various notions of diversity have been proposed, tailored to different applications. The general algorithmic goal is to find a subset of points that maximize diversity, while obeying a cardinality (or more generally, matroid) constraint. The goal of this paper is to develop a novel linear programming (LP) framework that allows us to design approximation algorithms for such problems. We study an objective known as sum-min diversity, which is known to be effective in many applications, and give the first constant factor approximation algorithm. Our LP framework allows us to easily incorporate additional constraints, as well as secondary objectives. We also prove a hardness result for two natural diversity objectives, under the so-called planted clique assumption. Finally, we study the empirical performance of our algorithm on several standard datasets. We first study the approximation quality of the algorithm by comparing with the LP objective. Then, we compare the quality of the solutions produced by our method with other popular diversity maximization algorithms. 1 Introduction Computing a concise, yet diverse and representative subset of a large collection of elements is a central problem in many areas. In machine learning, it has been used for feature selection [23], and in recommender systems [24]. There are also several data mining applications, such as web search [21, 20], news aggregation [2], etc. Diversity maximization has also found applications in drug discovery, where the goal is to choose a small and diverse subset of a large collection of compounds to use for testing [16]. A general way to formalize the problem is as follows: we are given a set of objects in a metric space, and the goal is to find a subset of them of a prescribed size so as to maximize some measure of diversity (a function of the distances between the chosen points). One well studied example of a diversity measure is the minimum pairwise distance between the selected points – the larger it is, the more “mutually separated” the chosen points are. This, as well as other diversity measures have been studied in the literature [11, 10, 6, 23], including those based on mutual information and linear algebraic notions of distance, and approximation algorithms have been proposed. This is similar in spirit to the rich and beautiful literature on clustering problems with various objectives (e.g. k-center, k-median, k-means). Similar to clustering, many of the variants of diversity maximization admit 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. Figure 1: Preference for far clusters in sum-sum(·) maximization constant factor approximation algorithms. Most of the known algorithms for diversity maximization are based on a natural greedy approach, or on local search. Our goal in this work is to develop novel linear programming formulations for diversity maximization and provide new approximation guarantees. Convex relaxation approaches are typically powerful in that they can incorporate additional constraints and additional objective functions, as we will illustrate. This is important in some applications, and indeed, diversity maximization has been studied under additional knapsack [3] and matroid [2] constraints. In applications such as web search, it is important to optimize diversity, along with other objectives, such as total relevance or coverage (see [4]). Another contribution of this work is to explore approximation lower bounds for diversity maximization. Given the simplicity of the best known algorithms for some objectives (e.g., greedy addition, single-swap local search), it is natural to ask if better algorithms are possible. Rather surprisingly, we show that the answer is no, for the most common objectives. Objective functions. The many variants of diversity maximization differ in their choice of the objective function, i.e., how they define diversity of a set S of points. Our focus in this paper will be distance based objectives, which can be defined over arbitrary metric spaces, via pairwise distances between the chosen points. Let d(u, v) be the distance between points u and v, and for a set of points T, let d(u, T) = minv∈T d(u, v). The three most common objectives are: 1. Min-min diversity, defined by min-min(S) = minu∈S d(u, S \ u). 2. Sum-min diversity, defined by sum-min(S) = u∈S d(u, S \ u). 3. Sum-sum diversity, defined by sum-sum(S) = u∈S v∈S d(u, v). All three objectives have been used in applications [16]. Of these min-min and sum-sum are also known to admit constant factor approximation algorithms. In fact, a natural greedy algorithm gives a factor 1/2 approximation for min-min, while local search gives a constant factor approximation for sum-sum, even with matroid constraints [6, 2, 4]. However, for the sum-min objective, the best known algorithm had an approximation factor of O(1/ log n) [6] and no inapproximability results were known. Combinatorial methods such as greedy and local search fail (see Lemma 1), and achieving a constant factor approximation has remained a challenge. Compared to the other objectives, the sets that maximize the sum-min objective have properties that are desirable in practice, as observed in [16], and demonstrated in our experiments. We will now outline some theoretical reasons. Drawbacks of the min-min and sum-sum objectives. The main problem with min-min stems from the fact that it solely depends on the closest pair of chosen points, and it does not capture the distance distribution between the chosen points well. Another concern is that it is highly nonmonotone in the size of |S| – in applications such as search, it is paradoxical for the diversity to take a sharp drop once we add one extra element to the set of search results. The sum-sum objective is much more robust, and is hence much more popular in applications. However, as also noted in [16], it tends to promote picking too many “corner” points. To illustrate, suppose we have a set of points that fall into k clusters (which is common in candidate search results). Suppose the points are distributed as a mixture of k equally spaced Gaussians on a line (see Figure 1). The intuitively desired solution is to pick one point from each of the clusters. However the optimizer for sum-sum picks all the points from the farthest two clusters (shown shaded in Figure 1). The sum-min objective inherits the good properties of both – it is robust to a small number of additions/removals, and it tries to ensure that each point is far from the others. However, it is trickier to optimize, as we mentioned earlier. In fact, in the supplement, Section E, we show that: Lemma 1. The natural Greedy and Local-Search algorithms for sum-min diversity have an approximation ratio of O(1/ √ k). 2 Our contributions. With these motivations, we study the problem of maximizing sum-min diversity subject to a cardinality constraint – max|S|≤k sum-min(S). Our main algorithmic results are: • We give a factor 1/8 approximation for sum-min diversity maximization with cardinality constraint (the first constant factor approximation). Indeed, when k is a large enough constant, we give a (roughly) 1 2e-approximation. This is presented in Section 2 to illustrate our ideas (Theorem 1). The algorithm can also incorporate arbitrary concave functions of distance, as well as explicit constraints to avoid duplicates (end of Section 2). • We show that the 1/8 approximation holds when we replace cardinality constraints with arbitrary matroid constraints. Such constraints arise in applications such as product search [3] or news aggregators [2] where it is desirable to report items from different brands or different news agencies. This can be modeled as a partition matroid. • Our formulation can be used to maximize the sum-min diversity, along with total relevance or coverage objectives (Theorem 3). This is motivated by applications in recommender systems in which we also want the set of results we output to cover a large range of topics [4, 2], or have a high total relevance to a query. Next, we show that for both the sum-sum and the sum-min variants of diversity maximization, obtaining an approximation factor better than 1/2 is hard, under the planted clique assumption (Theorem 5). (We observe that such a result for min-min is easy, by a reduction from independent set.) This implies that the simple local search algorithms developed for the sum-sum diversity maximization problem [6, 10, 11] are the best possible under the planted clique assumption. Finally, we study the empirical performance of our algorithm on several standard datasets. Our goal here is two-fold: first, we make an experimental case for the sum-min objective, by comparing the quality of the solutions output by our algorithm (which aims to maximize sum-min) with other popular algorithms (that maximize sum-sum). This is measured by how well the solution covers various clusters in the data, as well as by measuring quality in a feature selection task. Second, we study the approximation quality of the algorithm on real datasets, and observe that it performs much better than the theoretical guarantee (factor 1/8). 1.1 Notation and Preliminaries Throughout, (V, d) will denote the metric space we are working with, and we will write n = |V |. The number of points we need to output will, unless specified otherwise, be denoted by k. Approximation factor. We say that an algorithm provides an α factor approximation if, on every instance, it outputs a solution whose objective value is at least α · opt, where opt is the optimum value of the objective. (Since we wish to maximize our diversity objectives, α will be ≤1, and ratios closer to 1 are better.) Monotonicity of sum-min.We observe that our main objective, sum-min(·), is not monotone. I.e., sum-min(S ∪u) could be ≤sum-min(S) (for instance, if u is very close to one of the elements of S). This means that it could be better for an algorithm to output k < k elements if the goal is to maximize sum-min(·). However, this non-monotonicity is not too serious a problem, as the following lemma shows (proof in the supplement, Section A.1). Lemma 2. Let (V, d) be a metric space, and n = |V |. Suppose 1 < k < n/3 be the target number of elements. Let S be any subset of V of size ≤k. Then we can efficiently find an S ⊆V of size = k, such that sum-min(S) ≥1/4 · sum-min(S). Since our aim is to design a constant factor approximation algorithm, in what follows, we will allow our algorithms to output ≤k elements (we can then use the lemma above to output precisely k). Matroid constraints. Let D be a ground set of elements (which in our case, it will be V or its subset). A matroid M is defined by I, a family of subsets of D, called the independent sets of the matroid. I is required to have the properties of being subset-closed and having the basis exchange property (see Schrijver [22] for details). Some well-studied matroids which we consider are: (a) the uniform matroid of rank k, for which we have I := {X ⊆D : |X| ≤k}, (b) partition matroids, which are the direct sum of uniform matroids. 3 In matroid constrained diversity maximization, we are given a matroid M as above, and the goal is to output an element of I that maximizes diversity. Note that if M is the uniform matroid, this is equivalent to a cardinality constraint. The matroid polytope P(M), defined to be the convex hull of the indicator vectors of sets in I, plays a key role in optimization under matroid constraints. For most matroids of practical interest, it turns out optimization over P(M) can be done in polynomial time. 2 Basic Linear Programming Formulation We will now illustrate the main ideas behind our LP framework. We do so by proving a slightly simpler form of our result, where we assume that k is not too small. Specifically, we show that: Theorem 1. Let (V, d) be a metric space on n points, and let , k be parameters that satisfy ∈ (0, 1) and k > 8 log(1/)/2. There is a randomized polynomial time algorithm that outputs a set S ⊆V of size ≤k with E[sum-min(S)] ≥1−2 2e · opt, where opt is the largest possible sum-min() value for a subset of V of size ≤k. The main challenge in formulating an LP for the sum-min objective is to capture the quantity d(u, S\ u). The key trick is to introduce new variables to do so. To make things formal, for i ∈V , we denote by Ri = {d(i, j) : j = i} the set of candidate distances from i to its closest point in S. Next, let B(i, r) denote the “open” ball of radius r centered at i, i.e., B(i, r) = {j ∈V : d(i, j) < r}; and let B(i, r) = B(i, r/2) denote the ball of half the radius. The LP we consider is as follows: we have a variable xir for each i ∈V and r ∈Ri which is supposed to be 1 iff i ∈S and r = minj∈S\{i} d(i, j). Thus for every i, at most one xir is 1 and the rest are 0. Hence i,r∈Ri xir ≤k for the intended solution. The other set of constraints we add is the following: for each u ∈V , i∈V,r∈Ri:u∈B(i,r) xir ≤1. (figure in Section A.3 of supplement) (1) These constraints are the crux of our LP formulation. They capture the fact that if we take any solution S ⊆V , the balls B(s, r/2), where s ∈S and r = d(s, S \ {s}) are disjoint. This is because if u ∈B(i1, r1) ∩B(i2, r2), then assuming r1 ≥r2 (w.l.o.g.), triangle inequality implies that d(i1, i2) < r1 (the strict inequality is because we defined the balls to be ‘open’); Thus, in an integral solution, we will set at most one of xi1r1 and xi2r2 to 1. The full LP can now be written as follows maximize i r∈Ri xir · r subject to i∈V,r∈Ri xir ≤k, i∈V,r∈Ri:u∈B(i,r) xir ≤1 for all u ∈V , 0 ≤xir ≤1. The algorithm then proceeds by solving this LP, and rounding via the procedure defined below. Note that after step 2, we may have pairs with the same first coordinate, since we round them independently. But after step 3, this will not happen, as all but one of them will have been removed. procedure round(x) // LP solution (x) 1: Initialize S = ∅. 2: Add (i, r) to S with probability (1 −)(1 −e−xir) (independent of the other point-radius pairs). 3: If (i, r) = (j, r) ∈S such that r ≤r and i ∈B(j, r), remove (i, r) from S. 4: If |S| > k, abort (i.e., return ∅which has value 0); else return S, the set of first coordinates of S. Running time. The LP as described contains n2 variables, n for each vertex. This can easily be reduced to O(log n) per vertex, by only considering r in multiples of (1 + δ), for some fixed δ > 0. 4 Further, we note that the LP is a packing LP. Thus it can be solved in time that is nearly linear in the size (and can be solved in parallel) [19]. Analysis. Let us now show that round returns a solution to with large expected value for the objective (note that due to the last step, it always returns a feasible solution, i.e., size ≤k). The idea is to write the expected diversity as a sum of appropriately defined random variables, and then use the linearity of expectation. For a (vertex, radius) pair (i, r), define χir to be an indicator random variable that is 1 iff (a) the pair (i, r) is picked in step 2, (b) it is not removed in step 3, and (c) |S| ≤k after step 3. Then we have the following. Lemma 3. Let S be the solution output by the algorithm, and define χir as above. Then we have sum-min(S) ≥ i,r r 2 · χir. Proof. If the set S after step 3 is of size > k, each χir = 0, and so there is nothing to prove. Otherwise, consider the set S at the end of step 3 and consider two pairs (i, r), (j, r) ∈S. The fact that both of them survived step 3 implies that d(i, j) ≥max(r, r)/2. Thus d(i, j) ≥r/2 for any j = i in the output, which implies that the contribution of i to the sum-min objective is ≥r/2. This completes the proof. Now, we will fix one pair (i, r) and show a lower bound on Pr[χir = 1]. Lemma 4. Consider the execution of the algorithm, and consider some pair (i, r). Define χir as above. We have Pr[χir = 1] ≥(1 −2)xir/e. Proof. Let T be the set of all (point, radius) pairs (j, r) such that (i, r) = (j, r), i ∈B(j, r), and r ≥r. Now, the condition (b) in the definition of χir is equivalent to the condition that none of the pairs in T are picked in step 2. Let us denote by χ(a) (resp., χ(b), χ(c)) the indicator variable for the condition (a) (resp. (b), (c)) in the definition of χir. We need to lower bound Pr[χ(a) ∧χ(b) ∧χ(c)]. To this end, note that Pr[χ(a) ∧χ(b) ∧χ(c)] = Pr[χ(a) ∧χ(b)] −Pr[χ(a) ∧χ(b) ∧χ(c)] ≥Pr[χ(a) ∧χ(b)] −Pr[χ(a) ∧χ(c)]. (2) Here χ(c) denotes the complement of χ(c), i.e., the event |S| > k at the end of step 3. Now, since the rounding selects pairs independently, we can lower bound the first term as Pr[χ(a) ∧χ(b)] ≥(1 −) 1 −e−xir (j,r)∈T 1 −(1 −)(1 −e−xjr ) ≥(1 −) 1 −e−xir (j,r)∈T e−xjr (3) Now, we can upper bound (j,r)∈T xjr, by noting that for all such pairs, B(j, r) contains i, and thus the LP constraint for i implies that (j,r)∈T xjr ≤1 −xir. Plugging this into (3), we get Pr[χ(a) ∧χ(b)] ≥(1 −) 1 −e−xir e−(1−xir) = (1 −)exir −1 e ≥(1 −)xir/e. We then need to upper bound the second term of (2). This is done using a Chernoff bound, which then implies the lemma. (see the Supplement, Section A.2 for details). Proof of Theorem 1. The proof follows from Lemmas 3 and 4, together with linearity of expectation. For details, see Section A.3 of the supplementary material. Direct Extensions. We mention two useful extensions that follow from our argument. (1) We can explicitly prevent the LP from picking points that are too close to each other (near duplicates). Suppose we are only looking for solutions in which every pair of points are at least a distance τ. Then, we can modify the set of ‘candidate’ distances Ri for each vertex to only include those ≥τ. This way, in the final solution, all the chosen points are at least τ/2 apart. (2) Our approximation guarantee also holds if the objective has any monotone concave function g() of d(u, S \ u). In the LP, we could maximize i r∈Ri xir · g(r), and the monotone concavity (which implies g(r/2) ≥g(r)/2) ensures the same approximation ratio. In some settings, having a cap on a vertex’s contribution to the objective is useful (e.g., bounding the effect of outliers). 5 3 General Matroid Constraints Let us now state our general result. It removes the restriction on k, and has arbitrary matroid constraints, as opposed to cardinality constraints in Section 2. Theorem 2. Let (V, d) be a metric space on n points, and let M = (V, I) be a matroid on V . Then there is an efficient randomized algorithm1 to find an S ∈I whose expected sum-min(S) value is at least opt/8, where opt = maxI∈I sum-min(I). The algorithm proceeds by solving an LP relaxation as before. The key differences in the formulation are: (1) we introduce new opening variables yi := r∈Ri xir for each i ∈V , and (2) the constraint i yi ≤k (which we had written in terms of the x variables) is now replaced with a general matroid constraint, which states that y ∈P(M). See Section B (of the supplementary material) for the full LP. This LP is now rounded using a different procedure, which we call generalized-round. Here, instead of independent rounding, we employ the randomized swap rounding algorithm (or the closely related pipage rounding) of [7], followed by a randomized rounding step. procedure generalized-round(y, x) // LP solution (y, x). 1: Initialize S = ∅. 2: Apply randomized swap rounding to the vector y/2 to obtain Y ∈{0, 1}V ∩P(M). 3: For each i with Yi = 1, add i to S and sample a radius ri according to the probability distribution that selects r ∈Ri with probability xir/yi. 4: If i ∈B(j, rj) with i = j ∈S and rj ≥ri, remove i from S. 5: Return S. Note that the rounding outputs S, along with an ri value for each i ∈S. The idea behind the analysis is that this rounding has the same properties as randomized rounding, while ensuring that S is an independent set of M. The details, and the proof of Theorem 2 are deferred to the supplementary material (Section B). 4 Additional Objectives and Hardness The LP framework allows us to incorporate “secondary objectives”. As an example, consider the problem of selecting search results, in which every candidate page has a relevance to the query, along with the metric between pages. Here, we are interested in selecting a subset with a high total relevance, in addition to a large value of sum-min(). A generalization of relevance is coverage. Suppose every page u comes with a set Cu of topics it covers. Now consider the problem of picking a set S of pages so as to simultaneously maximize sum-min() and the total coverage, i.e., the size of the union ∪u∈SCu, subject to cardinality constraints. (Coverage generalizes relevance, because if the sets Cu are all disjoint, then |Cu| acts as the relevance of u.) Because we have a simple formulation and rounding procedure, we can easily incorporate a coverage (and therefore relevance) objective into our LP, and obtain simultaneous guarantees. We prove the following: (A discussion of the theorem and its proof are deferred to Section C.) Theorem 3. Let (V, d) be a metric space and let {Cu : u ∈V } be a collection of subsets of a universe [m]. Suppose there exists a set S∗⊆V of size ≤k with sum-min(S∗) = opt, and | ∪u∈S∗Cu| = C. Then there is an efficient randomized algorithm that outputs a set S satisfying: (1) E[|S|] ≤k, (2) E[sum-min(S)] ≥opt/8, and (3) E[| ∪u∈S Cu|] ≥C/16. 4.1 Hardness Beyond Factor 1/2 For diversity maximization under both the sum-sum and the sum-min objectives, we show that obtaining approximation ratios better than 2 is unlikely, by a reduction from the so-called planted clique problem. Such a reduction for sum-sum was independently obtained by Borodin et al. [4]. For completeness, we provide the details and proof in the supplementary material (Section D). 1Assuming optimization over P(M) can be done efficiently, which is true for all standard matroids. 6 5 Experiments Goals and design. The goal of our experiments is to evaluate the sum-min objective as well as the approximation quality of our algorithm on real datasets. For the first of the two, we consider the k-element subsets obtained by maximizing the sum-min objective (using a slight variant of our algorithm), and compare their quality (in terms of being representative of the data) with subsets obtained by maximizing the sum-sum objective, which is the most commonly used diversity objective. Since measuring the quality as above is not clearly defined, we come up with two measures, using datasets that have a known clustering: (1) First, we see how well the different clusters are represented in the chosen subset. This is important in web search applications, and we do this in two ways: (a) by measuring the number of distinct clusters present, and (b) by observing the “non-uniformity” in the number of nodes picked from the different clusters, measured as a deviation from the mean. (2) Second, we consider feature-selection. Here, we consider data in which each object has several features, and then we pick a subset of the features (treating each feature as a vector of size equal to the number of data points). Then, we restrict data to just the chosen features, and see how well 3-NN clustering in the obtained space (which is much faster to perform than in the original space, due to the reduced number of features) compares with ground-truth clustering. Let us go into the details of (1) above. We used two datasets with ground-truth clusterings. The first is COIL100, which contains images of 100 different objects [17]. It includes 72 images per object. We convert them into 32 × 32 grayscale images and consider 6 pictures per object. We used Euclidean distance as the metric. The second dataset is CDK2 – a drug discovery dataset publicly available in BindingDB.org [15, 1]. It contains 2253 compounds in 151 different clusters. Tanimoto distance, which is widely used in the drug discovery literature (and is similar to Jaccard distance), was used as the metric. Figure 2 (top) shows the number of distinct clusters picked by algorithms for the two objectives, and (bottom) shows the non-uniformity in the #(elements) picked from the different clusters (mean std deviation). We note that throughout this section, augmented LP is the algorithm that first does our LP rounding, and then adds nodes in a greedy manner to as to produce a subset of size precisely k (since randomized rounding could produce smaller sets). (a) COIL100 coverage (b) CDK2 coverage (c) COIL100 non-uniformity (d) CDK2 non-uniformity Figure 2: Sum-min vs Sum-sum objectives – how chosen subsets represent clusters 7 Now consider (2) above – feature selection. We used two handwritten text datasets. Multiple Features is a dataset of handwritten digits (649 features, 2000 instances [14]). USPS is a dataset of handwritten text (256 features, 9298 instances [12, 5]). We used the Euclidean distance as the metric (we could use more sophisticated features to compute distance, but even the simplistic one produces good results). Figure 3 shows the performance of the features selected by various algorithms. (a) Multiple Features dataset (b) USPS dataset Figure 3: Comparing outputs of feature selection via 3-NN classification with 10-fold cross validation. Next, we evaluate the practical performance of our LP algorithm, in terms of the proximity to the optimum objective value. Since we do not know the optimum, we compare it with the minimum of two upper bounds: the first is simply the value of the LP solution. The second is obtained as follows. For every i, let tj i denote the jth largest distance from i to other points in the dataset. The sum of k largest elements of {tk−1 i |i = 1, . . . , n} is clearly an upper bound on the sum-min objective, and sometimes it could be better than the LP optimum. Figure 4 shows the percentage of the minimum of the upperbounds that the augmented-LP algorithm achieves for two datasets [14, 18, 12, 8]. Note that it is significantly better than the theoretical guarantee 1/8. In fact, by adding the so-called clique constraints on the LP, we can obtain an even better bounds on the approximation ratio. However, this will result in a quadratic number of constraints, making the LP approach slow. Figure 4 also depicts the value of the simple LP algorithm (without augmenting to select k points). Finally, we point out that for many of the datasets we consider, there is no significant difference between the LP based algorithm, and the Local Search (and sometimes even the Greedy) heuristic in terms of the sum-min objective value. However, as we noted, the heuristics do not have worst case guarantees. A comparision is shown in Figure 4 (c). (a) Madelon dataset (b) USPS dataset (c) COIL100 dataset Figure 4: (a) and (b) show the approximation factor of LP and augmented LP algorithms; (c) compares Augmented LP with Greedy and LocalSearch in terms of sum-min objective value Conclusions. We have presented an approximation algorithm for diversity maximization, under the sum-min objective, by developing a new linear programming (LP) framework for the problem. Sum-min diversity turns out to be very effective at picking representatives from clustered data – a fact that we have demonstrated experimentally. Simple algorithms such as Greedy and Local Search could perform quite badly for sum-min diversity, which led us to the design of the LP approach. The approximation factor turns out to be much better in practice (compared to 1/8, which is the theoretical bound). Our LP approach is also quite general, and can easily incorporate additional objectives (such as relevance), which often arise in applications. 8 References [1] The binding database. http://www.bindingdb.org/. Accessed: 2016-05-01. [2] Z. Abbassi, V. S. Mirrokni, and M. Thakur. Diversity maximization under matroid constraints. In KDD, pages 32–40, 2013. [3] S. Bhattacharya, S. Gollapudi, and K. Munagala. Consideration set generation in commerce search. In S. Srinivasan, K. Ramamritham, A. Kumar, M. P. Ravindra, E. Bertino, and R. Kumar, editors, WWW, pages 317–326. ACM, 2011. [4] A. Borodin, H. C. Lee, and Y. Ye. Max-sum diversification, monotone submodular functions and dynamic updates. In M. Benedikt, M. Kr¨otzsch, and M. Lenzerini, editors, PODS, pages 155–166. ACM, 2012. [5] D. Cai, X. He, J. Han, and T. S. Huang. Graph regularized nonnegative matrix factorization for data representation. Pattern Analysis and Machine Intelligence, IEEE Transactions on, 33(8):1548–1560, 2011. [6] B. Chandra and M. M. Halld´orsson. Approximation algorithms for dispersion problems. Journal of algorithms, 38(2):438–465, 2001. [7] C. Chekuri, J. Vondrak, and R. Zenklusen. Dependent randomized rounding via exchange properties of combinatorial structures. In Foundations of Computer Science (FOCS), 2010 51st Annual IEEE Symposium on, pages 575–584, Oct 2010. [8] P. Duygulu, K. Barnard, J. F. G. de Freitas, and D. A. Forsyth. Object recognition as machine translation: Learning a lexicon for a fixed image vocabulary. In Computer Vision - ECCV 2002, 7th European Conference on Computer Vision, Copenhagen, Denmark, May 28-31, 2002, Proceedings, Part IV, pages 97–112, 2002. [9] V. Feldman, E. Grigorescu, L. Reyzin, S. Vempala, and Y. Xiao. Statistical algorithms and a lower bound for detecting planted cliques. In Proceedings of the Forty-fifth Annual ACM Symposium on Theory of Computing, STOC ’13, pages 655–664, New York, NY, USA, 2013. ACM. [10] S. Gollapudi and A. Sharma. An axiomatic approach for result diversification. In J. Quemada, G. Le´on, Y. S. Maarek, and W. Nejdl, editors, WWW, pages 381–390. ACM, 2009. [11] R. Hassin, S. Rubinstein, and A. Tamir. Approximation algorithms for maximum dispersion. Oper. Res. Lett., 21(3):133–137, 1997. [12] J. J. Hull. A database for handwritten text recognition research. IEEE Trans. Pattern Anal. Mach. Intell., 16(5):550–554, 1994. [13] R. M. Karp. Probabilistic analysis of some combinatorial search problems. Algorithms and Complexity: New Directions and Recent Results, pages 1–19, 1976. [14] M. Lichman. UCI machine learning repository, 2013. [15] T. Liu, Y. Lin, X. Wen, R. N. Jorissen, and M. K. Gilson. Bindingdb: a web-accessible database of experimentally determined protein–ligand binding affinities. Nucleic acids research, 35(suppl 1):D198– D201, 2007. [16] T. Meinl, C. Ostermann, and M. R. Berthold. Maximum-score diversity selection for early drug discovery. Journal of chemical information and modeling, 51(2):237–247, 2011. [17] S. Nayar, S. Nene, and H. Murase. Columbia object image library (coil 100). Department of Comp. Science, Columbia University, Tech. Rep. CUCS-006-96, 1996. [18] H. Peng, F. Long, and C. Ding. Feature selection based on mutual information criteria of max-dependency, max-relevance, and min-redundancy. Pattern Analysis and Machine Intelligence, IEEE Transactions on, 27(8):1226–1238, 2005. [19] S. A. Plotkin, D. B. Shmoys, and E. Tardos. Fast approximation algorithms for fractional packing and covering problems. In Proceedings of the 32Nd Annual Symposium on Foundations of Computer Science, SFCS ’91, pages 495–504, Washington, DC, USA, 1991. IEEE Computer Society. [20] L. Qin, J. X. Yu, and L. Chang. Diversifying top-k results. Proceedings of the VLDB Endowment, 5(11):1124–1135, 2012. [21] F. Radlinski and S. T. Dumais. Improving Personalized Web Search using Result Diversification. In SIGIR, 2006. [22] A. Schrijver. Combinatorial Optimization. Springer-Verlag, Berlin, 2003. [23] N. Vasconcelos. Feature selection by maximum marginal diversity: optimality and implications for visual recognition. In Computer Vision and Pattern Recognition, 2003. Proceedings. 2003 IEEE Computer Society Conference on, volume 1, pages I–762–I–769 vol.1, June 2003. [24] M. R. Vieira, H. L. Razente, M. C. Barioni, M. Hadjieleftheriou, D. Srivastava, C. Traina, and V. J. Tsotras. On query result diversification. In Data Engineering (ICDE), 2011 IEEE 27th International Conference on, pages 1163–1174. IEEE, 2011. 9 | 2016 | 486 |
6,423 | Binarized Neural Networks Itay Hubara1* itayh@technion.ac.il Matthieu Courbariaux2* matthieu.courbariaux@gmail.com Daniel Soudry3 daniel.soudry@gmail.com Ran El-Yaniv1 rani@cs.technion.ac.il Yoshua Bengio2,4 yoshua.umontreal@gmail.com (1) Technion, Israel Institute of Technology. (2) Université de Montréal. (3) Columbia University. (4) CIFAR Senior Fellow. (*) Indicates equal contribution. Abstract We introduce a method to train Binarized Neural Networks (BNNs) - neural networks with binary weights and activations at run-time. At train-time the binary weights and activations are used for computing the parameter gradients. During the forward pass, BNNs drastically reduce memory size and accesses, and replace most arithmetic operations with bit-wise operations, which is expected to substantially improve power-efficiency. To validate the effectiveness of BNNs, we conducted two sets of experiments on the Torch7 and Theano frameworks. On both, BNNs achieved nearly state-of-the-art results over the MNIST, CIFAR-10 and SVHN datasets. We also report our preliminary results on the challenging ImageNet dataset. Last but not least, we wrote a binary matrix multiplication GPU kernel with which it is possible to run our MNIST BNN 7 times faster than with an unoptimized GPU kernel, without suffering any loss in classification accuracy. The code for training and running our BNNs is available on-line. Introduction Deep Neural Networks (DNNs) have substantially pushed Artificial Intelligence (AI) limits in a wide range of tasks (LeCun et al., 2015). Today, DNNs are almost exclusively trained on one or many very fast and power-hungry Graphic Processing Units (GPUs) (Coates et al., 2013). As a result, it is often a challenge to run DNNs on target low-power devices, and substantial research efforts are invested in speeding up DNNs at run-time on both general-purpose (Gong et al., 2014; Han et al., 2015b) and specialized computer hardware (Chen et al., 2014; Esser et al., 2015). This paper makes the following contributions: • We introduce a method to train Binarized-Neural-Networks (BNNs), neural networks with binary weights and activations, at run-time, and when computing the parameter gradients at train-time (see Section 1). • We conduct two sets of experiments, each implemented on a different framework, namely Torch7 and Theano, which show that it is possible to train BNNs on MNIST, CIFAR-10 and SVHN and achieve near state-of-the-art results (see Section 2). Moreover, we report preliminary results on the challenging ImageNet dataset • We show that during the forward pass (both at run-time and train-time), BNNs drastically reduce memory consumption (size and number of accesses), and replace most arithmetic operations with bit-wise operations, which potentially lead to a substantial increase in power-efficiency (see Section 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. 3). Moreover, a binarized CNN can lead to binary convolution kernel repetitions; we argue that dedicated hardware could reduce the time complexity by 60% . • Last but not least, we programed a binary matrix multiplication GPU kernel with which it is possible to run our MNIST BNN 7 times faster than with an unoptimized GPU kernel, without suffering any loss in classification accuracy (see Section 4). The code for training and running our BNNs is available on-line (both Theano1 and Torch framework2). 1 Binarized Neural Networks In this section, we detail our binarization function, show how we use it to compute the parameter gradients,and how we backpropagate through it. Deterministic vs Stochastic Binarization When training a BNN, we constrain both the weights and the activations to either +1 or −1. Those two values are very advantageous from a hardware perspective, as we explain in Section 4. In order to transform the real-valued variables into those two values, we use two different binarization functions, as in (Courbariaux et al., 2015). Our first binarization function is deterministic: xb = Sign(x) = +1 if x ≥0, −1 otherwise, (1) where xb is the binarized variable (weight or activation) and x the real-valued variable. It is very straightforward to implement and works quite well in practice. Our second binarization function is stochastic: xb = +1 with probability p = σ(x), −1 with probability 1 −p, (2) where σ is the “hard sigmoid” function: σ(x) = clip(x + 1 2 , 0, 1) = max(0, min(1, x + 1 2 )). (3) The stochastic binarization is more appealing than the sign function, but harder to implement as it requires the hardware to generate random bits when quantizing. As a result, we mostly use the deterministic binarization function (i.e., the sign function), with the exception of activations at train-time in some of our experiments. Gradient Computation and Accumulation Although our BNN training method uses binary weights and activation to compute the parameter gradients, the real-valued gradients of the weights are accumulated in real-valued variables, as per Algorithm 1. Real-valued weights are likely required for Stochasic Gradient Descent (SGD) to work at all. SGD explores the space of parameters in small and noisy steps, and that noise is averaged out by the stochastic gradient contributions accumulated in each weight. Therefore, it is important to maintain sufficient resolution for these accumulators, which at first glance suggests that high precision is absolutely required. Moreover, adding noise to weights and activations when computing the parameter gradients provide a form of regularization that can help to generalize better, as previously shown with variational weight noise (Graves, 2011), Dropout (Srivastava et al., 2014) and DropConnect (Wan et al., 2013). Our method of training BNNs can be seen as a variant of Dropout, in which instead of randomly setting half of the activations to zero when computing the parameter gradients, we binarize both the activations and the weights. Propagating Gradients Through Discretization The derivative of the sign function is zero almost everywhere, making it apparently incompatible with back-propagation, since the exact gradient of the cost with respect to the quantities before the discretization (pre-activations or weights) would 1https://github.com/MatthieuCourbariaux/BinaryNet 2https://github.com/itayhubara/BinaryNet 2 be zero. Note that this remains true even if stochastic quantization is used. Bengio (2013) studied the question of estimating or propagating gradients through stochastic discrete neurons. He found in his experiments that the fastest training was obtained when using the “straight-through estimator,” previously introduced in Hinton’s lectures (Hinton, 2012). We follow a similar approach but use the version of the straight-through estimator that takes into account the saturation effect, and does use deterministic rather than stochastic sampling of the bit. Consider the sign function quantization q = Sign(r), and assume that an estimator gq of the gradient ∂C ∂q has been obtained (with the straight-through estimator when needed). Algorithm 1: Training a BNN. C is the cost function for minibatch, λ the learning rate decay factor and L the number of layers. ◦indicates element-wise multiplication. The function Binarize() specifies how to (stochastically or deterministically) binarize the activations and weights, and Clip() specifies how to clip the weights. BatchNorm() specifies how to batch-normalize the activations, using either batch normalization (Ioffe & Szegedy, 2015) or its shift-based variant we describe in Algorithm 3. BackBatchNorm() specifies how to backpropagate through the normalization. Update() specifies how to update the parameters when their gradients are known, using either ADAM (Kingma & Ba, 2014) or the shift-based AdaMax we describe in Algorithm 2. Require: a minibatch of inputs and targets (a0, a∗), previous weights W, previous BatchNorm parameters θ, weight initialization coefficients from (Glorot & Bengio, 2010) γ, and previous learning rate η. Ensure: updated weights W t+1, updated BatchNorm parameters θt+1 and updated learning rate ηt+1. {1. Computing the gradients:} {1.1. Forward propagation:} for k = 1 to L do W b k ←Binarize(Wk), sk ←ab k−1W b k ak ←BatchNorm(sk, θk) if k < L then ab k ←Binarize(ak) {1.2. Backward propagation:} {Please note that the gradients are not binary.} Compute gaL = ∂C ∂aL knowing aL and a∗ for k = L to 1 do if k < L then gak ←gab k ◦1|ak|≤1 (gsk, gθk) ←BackBatchNorm(gak, sk, θk) gab k−1 ←gskW b k, gW b k ←g⊤ skab k−1 {2. Accumulating the gradients:} for k = 1 to L do θt+1 k ←Update(θk, ηt, gθk), ηt+1 ←ληt W t+1 k ←Clip(Update(Wk, γkηt, gW b k), −1, 1) Algorithm 2: Shift based AdaMax learning rule (Kingma & Ba, 2014). g2 t indicates the element-wise square gt◦gt and ⊘stands for both left and right bit-shift. Good default settings are α = 2−10, 1 −β1 = 2−3, 1 − β2 = 2−10. All operations on vectors are element-wise. With βt 1 and βt 2 we denote β1 and β2 to the power t. Require: Previous parameters θt−1 and their gradient gt, and learning rate α. Ensure: Updated parameters θt. {Biased 1st and 2nd moment estimates:} mt ←β1 · mt−1 + (1 −β1) · gt vt ←max(β2 · vt−1, |gt|) {Updated parameters:} θt ←θt−1 −(α ⊘(1 −β1)) · ˆm ⊘v−1 t ) Algorithm 3: Shift based Batch Normalizing Transform, applied to activation x over a mini-batch. The approximate power-of2 is3AP2(x) = sign(x)2round(log2|x|), and ⊘stands for both left and right binary shift. Require: Values of x over a mini-batch: B = {x1...m}; parameters to learn: γ, β. Ensure: {yi = BN(xi,γ, β)} {1. Mini-batch mean:} µB ←1 m Pm i=1 xi {2. Centered input: } C(xi) ←(xi −µB) {3. Approximate variance:} σ2 B ←1 m Pm i=1(C(xi)⊘AP2(C(xi))) {4. Normalize:} ˆxi ←C(xi) ⊘AP2(( p σ2 B + ϵ)−1) {5. Scale and shift:} yi ←AP2(γ) ⊘ˆxi Then, our straight-through estimator of ∂C ∂r is simply gr = gq1|r|≤1. (4) Note that this preserves the gradient’s information and cancels the gradient when r is too large. Not cancelling the gradient when r is too large significantly worsens the performance. The use of this straight-through estimator is illustrated in Algorithm 1. The derivative 1|r|≤1 can also be seen as propagating the gradient through hard tanh, which is the following piece-wise linear activation function: Htanh(x) = Clip(x, −1, 1). (5) 3 Algorithm 4: Running a BNN. L = layers. Require: a vector of 8-bit inputs a0, the binary weights W b, and the BatchNorm parameters θ. Ensure: the MLP output aL. {1. First layer:} a1 ←0 for n = 1 to 8 do a1 ←a1+2n−1·XnorDotProduct(an 0, Wb 1) ab 1 ←Sign(BatchNorm(a1, θ1)) {2. Remaining hidden layers:} for k = 2 to L −1 do ak ←XnorDotProduct(ab k−1, W b k) ab k ←Sign(BatchNorm(ak, θk)) {3. Output layer:} aL ←XnorDotProduct(ab L−1, W b L) aL ←BatchNorm(aL, θL) For hidden units, we use the sign function nonlinearity to obtain binary activations, and for weights we combine two ingredients: • Constrain each real-valued weight between -1 and 1, by projecting wr to -1 or 1 when the weight update brings wr outside of [−1, 1], i.e., clipping the weights during training, as per Algorithm 1. The real-valued weights would otherwise grow very large without any impact on the binary weights. • When using a weight wr, quantize it using wb = Sign(wr). This is consistent with the gradient canceling when |wr| > 1, according to Eq. 4. Shift-based Batch Normalization Batch Normalization (BN) (Ioffe & Szegedy, 2015), accelerates the training and also seems to reduces the overall impact of the weight scale. The normalization noise may also help to regularize the model. However, at train-time, BN requires many multiplications (calculating the standard deviation and dividing by it), namely, dividing by the running variance (the weighted mean of the training set activation variance). Although the number of scaling calculations is the same as the number of neurons, in the case of ConvNets this number is quite large. For example, in the CIFAR-10 dataset (using our architecture), the first convolution layer, consisting of only 128 × 3 × 3 filter masks, converts an image of size 3 × 32 × 32 to size 3 × 128 × 28 × 28, which is two orders of magnitude larger than the number of weights. To achieve the results that BN would obtain, we use a shift-based batch normalization (SBN) technique. detailed in Algorithm 3. SBN approximates BN almost without multiplications. In the experiment we conducted we did not observe accuracy loss when using the shift based BN algorithm instead of the vanilla BN algorithm. Shift based AdaMax The ADAM learning rule (Kingma & Ba, 2014) also seems to reduce the impact of the weight scale. Since ADAM requires many multiplications, we suggest using instead the shift-based AdaMax we detail in Algorithm 2. In the experiment we conducted we did not observe accuracy loss when using the shift-based AdaMax algorithm instead of the vanilla ADAM algorithm. First Layer In a BNN, only the binarized values of the weights and activations are used in all calculations. As the output of one layer is the input of the next, all the layers inputs are binary, with the exception of the first layer. However, we do not believe this to be a major issue. First, in computer vision, the input representation typically has far fewer channels (e.g, red, green and blue) than internal representations (e.g, 512). As a result, the first layer of a ConvNet is often the smallest convolution layer, both in terms of parameters and computations (Szegedy et al., 2014). Second, it is relatively easy to handle continuous-valued inputs as fixed point numbers, with m bits of precision. For example, in the common case of 8-bit fixed point inputs: s = x · wb ; s = 8 X n=1 2n−1(xn · wb), (6) where x is a vector of 1024 8-bit inputs, x8 1 is the most significant bit of the first input, wb is a vector of 1024 1-bit weights, and s is the resulting weighted sum. This trick is used in Algorithm 4. 2 Benchmark Results We conduct two sets of experiments, each based on a different framework, namely Torch7 and Theano. Implementation details are reported in Appendix A and code for both frameworks is available online. Results are reported in Table 1. 3Hardware implementation of AP2 is as simple as extracting the index of the most significant bit from the number’s binary representation. 4 Table 1: Classification test error rates of DNNs trained on MNIST (fully connected architecture), CIFAR-10 and SVHN (convnet). No unsupervised pre-training or data augmentation was used. Data set MNIST SVHN CIFAR-10 Binarized activations+weights, during training and test BNN (Torch7) 1.40% 2.53% 10.15% BNN (Theano) 0.96% 2.80% 11.40% Committee Machines’ Array (Baldassi et al., 2015) 1.35% Binarized weights, during training and test BinaryConnect (Courbariaux et al., 2015) 1.29± 0.08% 2.30% 9.90% Binarized activations+weights, during test EBP (Cheng et al., 2015) 2.2± 0.1% Bitwise DNNs (Kim & Smaragdis, 2016) 1.33% Ternary weights, binary activations, during test (Hwang & Sung, 2014) 1.45% No binarization (standard results) No regularization 1.3± 0.2% 2.44% 10.94% Gated pooling (Lee et al., 2015) 1.69% 7.62% Figure 1: Training curves for different methods on CIFAR-10 dataset. The dotted lines represent the training costs (square hinge losses) and the continuous lines the corresponding validation error rates. Although BNNs are slower to train, they are nearly as accurate as 32-bit float DNNs. Preliminary Results on ImageNet To test the strength of our method, we applied it to the challenging ImageNet classification task. Considerable research has been concerned with compressing ImageNet architectures while preserving high accuracy performance (e.g., Han et al. (2015a)). Previous approaches that have been tried include pruning near zero weights using matrix factorization techniques, quantizing the weights and applying Huffman codes among others. To the best of the our knowledge, so far there are no reports on successfully quantizing the network’s activations. Moreover, a recent work Han et al. (2015a) showed that accuracy significantly deteriorates when trying to quantize convolutional layers’ weights below 4 bits (FC layers are more robust to quantization and can operate quite well with only 2 bits). In the present work we attempted to tackle the difficult task of binarizing both weights and activations. Employing the well known AlexNet and GoogleNet architectures, we applied our techniques and achieved 36.1% top-1 and 60.1% top-5 accuracies using AlexNet and 47.1% top-1 and 69.1% top-5 accuracies using GoogleNet. While this performance leaves room for improvement (relative to full precision nets), they are by far better than all previous attempts to compress ImageNet architectures using less than 4 bits precision for the weights. Moreover, this advantage is achieved while also binarizing neuron activations. Detailed descriptions of these results as well as full implementation details of our experiments are reported in the supplementary material (Appendix B). In our latest work (Hubara et al., 2016) we relaxed the binary constrains and allowed more than 1-bit per weight and activations. The resulting QNNs achieve prediction accuracy comparable to their 32-bit counterparts. For example, our quantized version of AlexNet with 1-bit weights and 2-bit activations achieves 51% top-1 accuracy and GoogleNet with 4-bits weighs and activation achived 66.6%. Moreover, we quantize the parameter gradients to 6-bits as well which enables gradients computation using only bit-wise operation. Full details can be found in (Hubara et al., 2016) 5 Table 2: Energy consumption of multiplyaccumulations in pico-joules (Horowitz, 2014) Operation MUL ADD 8bit Integer 0.2pJ 0.03pJ 32bit Integer 3.1pJ 0.1pJ 16bit Floating Point 1.1pJ 0.4pJ 32tbit Floating Point 3.7pJ 0.9pJ Table 3: Energy consumption of memory accesses in pico-joules (Horowitz, 2014) Memory size 64-bit memory access 8K 10pJ 32K 20pJ 1M 100pJ DRAM 1.3-2.6nJ 3 High Power Efficiency during the Forward Pass Computer hardware, be it general-purpose or specialized, is composed of memories, arithmetic operators and control logic. During the forward pass (both at run-time and train-time), BNNs drastically reduce memory size and accesses, and replace most arithmetic operations with bit-wise operations, which might lead to a great increase in power-efficiency. Moreover, a binarized CNN can lead to binary convolution kernel repetitions, and we argue that dedicated hardware could reduce the time complexity by 60% . Memory Size and Accesses Improving computing performance has always been and remains a challenge. Over the last decade, power has been the main constraint on performance (Horowitz, 2014). This is why much research effort has been devoted to reducing the energy consumption of neural networks. Horowitz (2014) provides rough numbers for the energy consumed by the computation (the given numbers are for 45nm technology), as summarized in Tables 2 and 3. Importantly, we can see that memory accesses typically consume more energy than arithmetic operations, and memory access cost augments with memory size. In comparison with 32-bit DNNs, BNNs require 32 times smaller memory size and 32 times fewer memory accesses. This is expected to reduce energy consumption drastically (i.e., more than 32 times). XNOR-Count Applying a DNN mainly consists of convolutions and matrix multiplications. The key arithmetic operation of deep learning is thus the multiply-accumulate operation. Artificial neurons are basically multiply-accumulators computing weighted sums of their inputs. In BNNs, both the activations and the weights are constrained to either −1 or +1. As a result, most of the 32-bit floating point multiply-accumulations are replaced by 1-bit XNOR-count operations. This could have a big impact on dedicated deep learning hardware. For instance, a 32-bit floating point multiplier costs about 200 Xilinx FPGA slices (Govindu et al., 2004; Beauchamp et al., 2006), whereas a 1-bit XNOR gate only costs a single slice. Exploiting Filter Repetitions When using a ConvNet architecture with binary weights, the number of unique filters is bounded by the filter size. For example, in our implementation we use filters of size 3 × 3, so the maximum number of unique 2D filters is 29 = 512. Since we now have binary filters, many 2D filters of size k × k repeat themselves. By using dedicated hardware/software, we can apply only the unique 2D filters on each feature map and sum the results to receive each 3D filter’s convolutional result. For example, in our ConvNet architecture trained on the CIFAR-10 benchmark, there are only 42% unique filters per layer on average. Hence we can reduce the number of the XNOR-popcount operations by 3. 4 Seven Times Faster on GPU at Run-Time It is possible to speed up GPU implementations of BNNs, by using a method sometimes called SIMD (single instruction, multiple data) within a register (SWAR). The basic idea of SWAR is to concatenate groups of 32 binary variables into 32-bit registers, and thus obtain a 32-times speed-up on bitwise operations (e.g, XNOR). Using SWAR, it is possible to evaluate 32 connections with only 3 instructions: a1+ = popcount(xnor(a32b 0 , w32b 1 )), (7) where a1 is the resulting weighted sum, and a32b 0 and w32b 1 are the concatenated inputs and weights. Those 3 instructions (accumulation, popcount, xnor) take 1 + 4 + 1 = 6 clock cycles on recent 6 Nvidia GPUs (and if they were to become a fused instruction, it would only take a single clock cycle). Consequently, we obtain a theoretical Nvidia GPU speed-up of factor of 32/6 ≈5.3. In practice, this speed-up is quite easy to obtain as the memory bandwidth to computation ratio is also increased by 6 times. Figure 2: The first three columns represent the time it takes to perform a 8192 × 8192 × 8192 (binary) matrix multiplication on a GTX750 Nvidia GPU, depending on which kernel is used. We can see that our XNOR kernel is 23 times faster than our baseline kernel and 3.4 times faster than cuBLAS. The next three columns represent the time it takes to run the MLP from Section 2 on the full MNIST test set. As MNIST’s images are not binary, the first layer’s computations are always performed by the baseline kernel. The last three columns show that the MLP accuracy does not depend on which kernel is used. In order to validate those theoretical results, we programed two GPU kernels: • The first kernel (baseline) is an unoptimized matrix multiplication kernel. • The second kernel (XNOR) is nearly identical to the baseline kernel, except that it uses the SWAR method, as in Equation (7). The two GPU kernels return identical outputs when their inputs are constrained to −1 or +1 (but not otherwise). The XNOR kernel is about 23 times faster than the baseline kernel and 3.4 times faster than cuBLAS, as shown in Figure 2. Last but not least, the MLP from Section 2 runs 7 times faster with the XNOR kernel than with the baseline kernel, without suffering any loss in classification accuracy (see Figure 2). 5 Discussion and Related Work Until recently, the use of extremely lowprecision networks (binary in the extreme case) was believed to be highly destructive to the network performance (Courbariaux et al., 2014). Soudry et al. (2014) and Cheng et al. (2015) proved the contrary by showing that good performance could be achieved even if all neurons and weights are binarized to ±1 . This was done using Expectation BackPropagation (EBP), a variational Bayesian approach, which infers networks with binary weights and neurons by updating the posterior distributions over the weights. These distributions are updated by differentiating their parameters (e.g., mean values) via the back propagation (BP) algorithm. Esser et al. (2015) implemented a fully binary network at run time using a very similar approach to EBP, showing significant improvement in energy efficiency. The drawback of EBP is that the binarized parameters are only used during inference. The probabilistic idea behind EBP was extended in the BinaryConnect algorithm of Courbariaux et al. (2015). In BinaryConnect, the real-valued version of the weights is saved and used as a key reference for the binarization process. The binarization noise is independent between different weights, either by construction (by using stochastic quantization) or by assumption (a common simplification; see Spang (1962). The noise would have little effect on the next neuron’s input because the input is a summation over many weighted neurons. Thus, the real-valued version could be updated by the back propagated error by simply ignoring the binarization noise in the update. Using this method, Courbariaux et al. (2015) were the first to binarize weights in CNNs and achieved near state-of-the-art performance on several datasets. They also argued that noisy weights provide a form of regularization, which could help to improve generalization, as previously shown in (Wan et al., 2013). This method binarized weights while still maintaining full precision neurons. Lin et al. (2015) carried over the work of Courbariaux et al. (2015) to the back-propagation process by quantizing the representations at each layer of the network, to convert some of the remaining multiplications into bit-shifts by restricting the neurons values to be power-of-two integers. Lin et al. (2015)’s work and ours seem to share similar characteristics . However, their approach continues to use full precision weights during the test phase. Moreover, Lin et al. (2015) quantize the neurons only during the back propagation process, and not during forward propagation. 7 Other research Baldassi et al. (2015) showed that full binary training and testing is possible in an array of committee machines with randomized input, where only one weight layer is being adjusted. Gong et al. (2014) aimed to compress a fully trained high precision network by using a quantization or matrix factorization methods. These methods required training the network with full precision weights and neurons, thus requiring numerous MAC operations the proposed BNN algorithm avoids. Hwang & Sung (2014) focused on a fixed-point neural network design and achieved performance almost identical to that of the floating-point architecture. Kim & Smaragdis (2016) retrained neural networks with binary weights and activations. So far, to the best of our knowledge, no work has succeeded in binarizing weights and neurons, at the inference phase and the entire training phase of a deep network. This was achieved in the present work. We relied on the idea that binarization can be done stochastically, or be approximated as random noise. This was previously done for the weights by Courbariaux et al. (2015), but our BNNs extend this to the activations. Note that the binary activations are especially important for ConvNets, where there are typically many more neurons than free weights. This allows highly efficient operation of the binarized DNN at run time, and at the forward-propagation phase during training. Moreover, our training method has almost no multiplications, and therefore might be implemented efficiently in dedicated hardware. However, we have to save the value of the full precision weights. This is a remaining computational bottleneck during training, since it is an energy-consuming operation. Conclusion We have introduced BNNs, which binarize deep neural networks and can lead to dramatic improvements in both power consumption and computation speed. During the forward pass (both at run-time and train-time), BNNs drastically reduce memory size and accesses, and replace most arithmetic operations with bit-wise operations. Our estimates indicate that power efficiency can be improved by more than one order of magnitude (see Section 3). In terms of speed, we programed a binary matrix multiplication GPU kernel that enabled running MLP over the MNIST datset 7 times faster (than with an unoptimized GPU kernel) without suffering any accuracy degradation (see Section 4). We have shown that BNNs can handle MNIST, CIFAR-10 and SVHN while achieving nearly stateof-the-art accuracy performance. While our preliminary results for the challenging ImageNet are not on par with the best results achievable with full precision networks, they significantly improve all previous attempts to compress ImageNet-capable architectures (see Section 2 and supplementary material - Appendix B). Moreover by relaxing the binary constrains and allowed more than 1-bit per weight and activations we have been able to achieve prediction accuracy comparable to their 32-bit counterparts. Full details can be found in our latest work (Hubara et al., 2016) A major open question would be to further improve our results on ImageNet. A substantial progress in this direction might lead to huge impact on DNN usability in low power instruments such as mobile phones. Acknowledgments We would like to express our appreciation to Elad Hoffer, for his technical assistance and constructive comments. We thank our fellow MILA lab members who took the time to read the article and give us some feedback. We thank the developers of Torch, Collobert et al. (2011) a Lua based environment, and Theano (Bergstra et al., 2010; Bastien et al., 2012), a Python library which allowed us to easily develop a fast and optimized code for GPU. We also thank the developers of Pylearn2 (Goodfellow et al., 2013) and Lasagne (Dieleman et al., 2015), two Deep Learning libraries built on the top of Theano. We thank Yuxin Wu for helping us compare our GPU kernels with cuBLAS. We are also grateful for funding from NSERC, the Canada Research Chairs, Compute Canada, and CIFAR. We are also grateful for funding from CIFAR, NSERC, IBM, Samsung. This research was also supported by The Israel Science Foundation (grant No. 1890/14). References Baldassi, C., Ingrosso, A., Lucibello, C., Saglietti, L., and Zecchina, R. Subdominant Dense Clusters Allow for Simple Learning and High Computational Performance in Neural Networks with Discrete Synapses. Physical Review Letters, 115(12):1–5, 2015. 8 Bastien, F., Lamblin, P., Pascanu, R., et al. Theano: new features and speed improvements. Deep Learning and Unsupervised Feature Learning NIPS 2012 Workshop, 2012. Beauchamp, M. J., Hauck, S., Underwood, K. D., and Hemmert, K. S. Embedded floating-point units in FPGAs. In Proceedings of the 2006 ACM/SIGDA 14th international symposium on Field programmable gate arrays, pp. 12–20. ACM, 2006. Bengio, Y. Estimating or propagating gradients through stochastic neurons. Technical Report arXiv:1305.2982, Universite de Montreal, 2013. Bergstra, J., Breuleux, O., Bastien, F., et al. Theano: a CPU and GPU math expression compiler. In Proceedings of the Python for Scientific Computing Conference (SciPy), June 2010. Oral Presentation. Chen, T., Du, Z., Sun, N., et al. Diannao: A small-footprint high-throughput accelerator for ubiquitous machinelearning. In Proceedings of the 19th international conference on Architectural support for programming languages and operating systems, pp. 269–284. ACM, 2014. Cheng, Z., Soudry, D., Mao, Z., and Lan, Z. Training binary multilayer neural networks for image classification using expectation backpropgation. arXiv preprint arXiv:1503.03562, 2015. Coates, A., Huval, B., Wang, T., et al. Deep learning with COTS HPC systems. In Proceedings of the 30th international conference on machine learning, pp. 1337–1345, 2013. Collobert, R., Kavukcuoglu, K., and Farabet, C. Torch7: A matlab-like environment for machine learning. In BigLearn, NIPS Workshop, 2011. Courbariaux, M., Bengio, Y., and David, J.-P. Training deep neural networks with low precision multiplications. ArXiv e-prints, abs/1412.7024, December 2014. Courbariaux, M., Bengio, Y., and David, J.-P. Binaryconnect: Training deep neural networks with binary weights during propagations. ArXiv e-prints, abs/1511.00363, November 2015. Dieleman, S., Schlüter, J., Raffel, C., et al. Lasagne: First release., August 2015. Esser, S. K., Appuswamy, R., Merolla, P., Arthur, J. V., and Modha, D. S. Backpropagation for energy-efficient neuromorphic computing. In Advances in Neural Information Processing Systems, pp. 1117–1125, 2015. Glorot, X. and Bengio, Y. Understanding the difficulty of training deep feedforward neural networks. In AISTATS’2010, 2010. Gong, Y., Liu, L., Yang, M., and Bourdev, L. Compressing deep convolutional networks using vector quantization. arXiv preprint arXiv:1412.6115, 2014. Goodfellow, I. J., Warde-Farley, D., Lamblin, P., et al. Pylearn2: a machine learning research library. arXiv preprint arXiv:1308.4214, 2013. Govindu, G., Zhuo, L., Choi, S., and Prasanna, V. Analysis of high-performance floating-point arithmetic on FPGAs. In Parallel and Distributed Processing Symposium, 2004. Proceedings. 18th International, pp. 149. IEEE, 2004. Graves, A. Practical variational inference for neural networks. In Advances in Neural Information Processing Systems, pp. 2348–2356, 2011. Han, S., Mao, H., and Dally, W. J. Deep compression: Compressing deep neural networks with pruning, trained quantization and huffman coding. arXiv preprint arXiv:1510.00149, 2015a. Han, S., Pool, J., Tran, J., and Dally, W. Learning both weights and connections for efficient neural network. In Advances in Neural Information Processing Systems, pp. 1135–1143, 2015b. Hinton, G. Neural networks for machine learning. Coursera, video lectures, 2012. Horowitz, M. Computing’s Energy Problem (and what we can do about it). IEEE Interational Solid State Circuits Conference, pp. 10–14, 2014. Hubara, I., Courbariaux, M., Soudry, D., El-Yaniv, R., and Bengio, Y. Quantized neural networks: Training neural networks with low precision weights and activations. arXiv preprint arXiv:1609.07061, 2016. Hwang, K. and Sung, W. Fixed-point feedforward deep neural network design using weights+ 1, 0, and- 1. In Signal Processing Systems (SiPS), 2014 IEEE Workshop on, pp. 1–6. IEEE, 2014. Ioffe, S. and Szegedy, C. Batch normalization: Accelerating deep network training by reducing internal covariate shift. 2015. Kim, M. and Smaragdis, P. Bitwise Neural Networks. ArXiv e-prints, January 2016. Kingma, D. and Ba, J. Adam: A method for stochastic optimization. arXiv preprint arXiv:1412.6980, 2014. LeCun, Y., Bengio, Y., and Hinton, G. Deep learning. Nature, 521(7553):436–444, 2015. Lee, C.-Y., Gallagher, P. W., and Tu, Z. Generalizing pooling functions in convolutional neural networks: Mixed, gated, and tree. arXiv preprint arXiv:1509.08985, 2015. Lin, Z., Courbariaux, M., Memisevic, R., and Bengio, Y. Neural networks with few multiplications. ArXiv e-prints, abs/1510.03009, October 2015. Soudry, D., Hubara, I., and Meir, R. Expectation backpropagation: Parameter-free training of multilayer neural networks with continuous or discrete weights. In NIPS’2014, 2014. Srivastava, N., Hinton, G., Krizhevsky, A., Sutskever, I., and Salakhutdinov, R. Dropout: A simple way to prevent neural networks from overfitting. Journal of Machine Learning Research, 15:1929–1958, 2014. Szegedy, C., Liu, W., Jia, Y., et al. Going deeper with convolutions. Technical report, arXiv:1409.4842, 2014. Wan, L., Zeiler, M., Zhang, S., LeCun, Y., and Fergus, R. Regularization of neural networks using dropconnect. In ICML’2013, 2013. 9 | 2016 | 487 |
6,424 | A Appendix: Proof of Theorem 1 We first show that the estimate is unbiased. Indeed, for every i 6= j we can rewrite L(z) as E⇡`⇡(i),⇡(j)(z). Therefore, L(z) = 1 k2 −k X i6=j2[k] L(z) = 1 k2 −k X i6=j2[k] E ⇡`⇡(i),⇡(j)(z) = E ⇡L⇡(z) , which proves that the multibatch estimate is unbiased. Next, we turn to analyze the variance of the multibatch estimate. let I ⇢[k]4 be all the indices i, j, s, t s.t. i 6= j, s 6= t, and we partition I to I1 [ I2 [ I3, where I1 is the set where i = s and j = t, I2 is when all indices are different, and I3 is when i = s and j 6= t or i 6= s and j = t. Then: E ⇡krL⇡(z) −rL(z)k2 = 1 (k2 −k)2 E ⇡ X (i,j,s,t)2I (r`⇡(i),⇡(j)(z) −rL(z)) · (r`⇡(s),⇡(t)(z) −rL(z)) = d X r=1 1 (k2 −k)2 3 X q=1 X (i,j,s,t)2Iq E ⇡(rr`⇡(i),⇡(j)(z) −rrL(z)) (rr`⇡(s),⇡(t)(z) −rrL(z)) For every r, denote by A(r) the matrix with A(r) i,j = rr`i,j(z) −rrL(z). Observe that for every r, Ei6=j A(r) i,j = 0, and that X r E i6=j(A(r) i,j )2 = E i6=j kr`i,j(z) −rL(z)k2. Therefore, E ⇡krL⇡(z) −rL(z)k2 = d X r=1 1 (k2 −k)2 3 X q=1 X (i,j,s,t)2Iq E ⇡A(r) ⇡(i),⇡(j)A(r) ⇡(s),⇡(t) Let us momentarily fix r and omit the superscript from A(r). We consider the value of E⇡A⇡(i),⇡(j)A⇡(s),⇡(t) according to the value of q. • For q = 1: we obtain E⇡A2 ⇡(i),⇡(j) which is the variance of the random variable rr`i,j(z)− rrL(z). • For q = 2: When we fix i, j, s, t which are all different, and take expectation over ⇡, then all products of off-diagonal elements of A appear the same number of times in E⇡A⇡(i),⇡(j)A⇡(s),⇡(t). Therefore, this quantity is proportional to P p6=r vpvr, where v is the vector of all non-diagonal entries of A. Since P p vp = 0, we obtain (using Lemma 1) that P p6=r vpvr 0, which means that the entire sum for this case is non-positive. • For q = 3: Let us consider the case when i = s and j 6= t, and the derivation for the case when i 6= s and j = t is analogous. The expression we obtain is E⇡A⇡(i),⇡(j)A⇡(i),⇡(t). This is like first sampling a row and then sampling, without replacement, two indices from the row (while not allowing to take the diagonal element). So, we can rewrite the expression as: E ⇡A⇡(i),⇡(j)A⇡(s),⇡(t) = E i⇠[m] E j,t2[m]\{i}:j6=t Ai,jAi,t E i⇠[m] ✓ E j6=i Ai,j ◆2 = E i⇠[m]( ¯Ai)2 , (5) where we denote ¯Ai = Ej6=i Ai,j and in the inequality we used again Lemma 1. Finally, the bound on the variance follows by observing that the number of summands in I1 is k2 −k and the number of summands in I3 is O(k3). This concludes our proof. 10 Lemma 1 Let v 2 Rn be any vector. Then, E s6=t[vsvt] (E i [vi])2 In particular, if Ei[vi] = 0 then P s6=t vsvt 0. Proof For simplicity, we use E[v] for Ei[vi] and E[v2] for Ei[v2 i ]. Then: E s6=t vsvt = 1 n2 −n n X s=1 n X t=1 vsvt − 1 n2 −n n X s=1 v2 s = 1 n2 −n n X s=1 vs n X t=1 vt − 1 n2 −n n X s=1 v2 s = n2 n2 −n E[v]2 − n n2 −n E[v2] = n n2 −n(E[v]2 −E[v2]) + n2 −n n2 −n E[v]2 0 + E[v]2 11 | 2016 | 488 |
6,425 | Operator Variational Inference Rajesh Ranganath Princeton University Jaan Altosaar Princeton University Dustin Tran Columbia University David M. Blei Columbia University Abstract Variational inference is an umbrella term for algorithms which cast Bayesian inference as optimization. Classically, variational inference uses the Kullback-Leibler divergence to define the optimization. Though this divergence has been widely used, the resultant posterior approximation can suffer from undesirable statistical properties. To address this, we reexamine variational inference from its roots as an optimization problem. We use operators, or functions of functions, to design variational objectives. As one example, we design a variational objective with a Langevin-Stein operator. We develop a black box algorithm, operator variational inference (opvi), for optimizing any operator objective. Importantly, operators enable us to make explicit the statistical and computational tradeoffs for variational inference. We can characterize different properties of variational objectives, such as objectives that admit data subsampling—allowing inference to scale to massive data—as well as objectives that admit variational programs—a rich class of posterior approximations that does not require a tractable density. We illustrate the benefits of opvi on a mixture model and a generative model of images. 1 Introduction Variational inference is an umbrella term for algorithms that cast Bayesian inference as optimization [10]. Originally developed in the 1990s, recent advances in variational inference have scaled Bayesian computation to massive data [7], provided black box strategies for generic inference in many models [19], and enabled more accurate approximations of a model’s posterior without sacrificing efficiency [21, 20]. These innovations have both scaled Bayesian analysis and removed the analytic burdens that have traditionally taxed its practice. Given a model of latent and observed variables p.x; z/, variational inference posits a family of distributions over its latent variables and then finds the member of that family closest to the posterior, p.z j x/. This is typically formalized as minimizing a Kullback-Leibler (kl) divergence from the approximating family q./ to the posterior p./. However, while the kl.q k p/ objective offers many beneficial computational properties, it is ultimately designed for convenience; it sacrifices many desirable statistical properties of the resultant approximation. When optimizing kl, there are two issues with the posterior approximation that we highlight. First, it typically underestimates the variance of the posterior. Second, it can result in degenerate solutions that zero out the probability of certain configurations of the latent variables. While both of these issues can be partially circumvented by using more expressive approximating families, they ultimately stem from the choice of the objective. Under the kl divergence, we pay a large price when q./ is big where p./ is tiny; this price becomes infinite when q./ has larger support than p./. In this paper, we revisit variational inference from its core principle as an optimization problem. We use operators—mappings from functions to functions—to design variational objectives, explicitly trading offcomputational properties of the optimization with statistical properties of the approximation. We use operators to formalize the basic properties needed for variational inference algorithms. We further outline how to use them to define new variational objectives; as one example, we design a variational objective using a Langevin-Stein operator. 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. We develop operator variational inference (opvi), a black box algorithm that optimizes any operator objective. In the context of opvi, we show that the Langevin-Stein objective enjoys two good properties. First, it is amenable to data subsampling, which allows inference to scale to massive data. Second, it permits rich approximating families, called variational programs, which do not require analytically tractable densities. This greatly expands the class of variational families and the fidelity of the resulting approximation. (We note that the traditional kl is not amenable to using variational programs.) We study opvi with the Langevin-Stein objective on a mixture model and a generative model of images. Related Work. There are several threads of research in variational inference with alternative divergences. An early example is expectation propagation (ep) [16]. ep promises approximate minimization of the inclusive kl divergence kl.pjjq/ to find overdispersed approximations to the posterior. ep hinges on local minimization with respect to subsets of data and connects to work on ˛-divergence minimization [17, 6]. However, it does not have convergence guarantees and typically does not minimize kl or an ˛-divergence because it is not a global optimization method. We note that these divergences can be written as operator variational objectives, but they do not satisfy the tractability criteria and thus require further approximations. Li and Turner [14] present a variant of ˛-divergences that satisfy the full requirements of opvi. Score matching [9], a method for estimating models by matching the score function of one distribution to another that can be sampled, also falls into the class of objectives we develop. Here we show how to construct new objectives, including some not yet studied. We make explicit the requirements to construct objectives for variational inference. Finally, we discuss further properties that make them amenable to both scalable and flexible variational inference. 2 Operator Variational Objectives We define operator variational objectives and the conditions needed for an objective to be useful for variational inference. We develop a new objective, the Langevin-Stein objective, and show how to place the classical kl into this class. In the next section, we develop a general algorithm for optimizing operator variational objectives. 2.1 Variational Objectives Consider a probabilistic model p.x; z/ of data x and latent variables z. Given a data set x, approximate Bayesian inference seeks to approximate the posterior distribution p.z j x/, which is applied in all downstream tasks. Variational inference posits a family of approximating distributions q.z/ and optimizes a divergence function to find the member of the family closest to the posterior. The divergence function is the variational objective, a function of both the posterior and the approximating distribution. Useful variational objectives hinge on two properties: first, optimizing the function yields a good posterior approximation; second, the problem is tractable when the posterior distribution is known up to a constant. The classic construction that satisfies these properties is the evidence lower bound (elbo), Eq.z/Œlog p.x; z/ log q.z/: (1) It is maximized when q.z/ D p.z j x/ and it only depends on the posterior distribution up to a tractable constant, log p.x; z/. The elbo has been the focus in much of the classical literature. Maximizing the elbo is equivalent to minimizing the kl divergence to the posterior, and the expectations are analytic for a large class of models [4]. 2.2 Operator Variational Objectives We define a new class of variational objectives, operator variational objectives. An operator objective has three components. The first component is an operator Op;q that depends on p.z j x/ and q.z/. (Recall that an operator maps functions to other functions.) The second component is a family of test functions F , where each f .z/ 2 F maps realizations of the latent variables to real vectors Rd. In the objective, the operator and a function will combine in an expectation Eq.z/Œ.Op;q f /.z/, designed such that values close to zero indicate that q is close to p. The third component is a distance 2 function t.a/ W R ! Œ0; 1/, which is applied to the expectation so that the objective is non-negative. (Our example uses the square function t.a/ D a2.) These three components combine to form the operator variational objective. It is a non-negative function of the variational distribution, L.qI Op;q; F ; t/ D sup f 2F t.Eq.z/Œ.Op;q f /.z//: (2) Intuitively, it is the worst-case expected value among all test functions f 2 F . Operator variational inference seeks to minimize this objective with respect to the variational family q 2 Q. We use operator objectives for posterior inference. This requires two conditions on the operator and function family. 1. Closeness. The minimum of the variational objective is at the posterior, q.z/ D p.z j x/. We meet this condition by requiring that Ep.z j x/Œ.Op;p f /.z/ D 0 for all f 2 F . Thus, optimizing the objective will produce p.z j x/ if it is the only member of Q with zero expectation (otherwise it will produce a distribution in the equivalence class: q 2 Q with zero expectation). In practice, the minimum will be the closest member of Q to p.z j x/. 2. Tractability. We can calculate the variational objective up to a constant without involving the exact posterior p.z j x/. In other words, we do not require calculating the normalizing constant of the posterior, which is typically intractable. We meet this condition by requiring that the operator Op;q—originally in terms of p.z j x/ and q.z/—can be written in terms of p.x; z/ and q.z/. Tractability also imposes conditions on F : it must be feasible to find the supremum. Below, we satisfy this by defining a parametric family for F that is amenable to stochastic optimization. Equation 2 and the two conditions provide a mechanism to design meaningful variational objectives for posterior inference. Operator variational objectives try to match expectations with respect to q.z/ to those with respect to p.z j x/. 2.3 Understanding Operator Variational Objectives Consider operators where Eq.z/Œ.Op;q f /.z/ only takes positive values. In this case, distance to zero can be measured with the identity t.a/ D a, so tractability implies the operator need only be known up to a constant. This family includes tractable forms of familiar divergences like the kl divergence (elbo), Rényi’s ˛-divergence [14], and the -divergence [18]. When the expectation can take positive or negative values, operator variational objectives are closely related to Stein divergences [2]. Consider a family of scalar test functions F that have expectation zero with respect to the posterior, Ep.z j x/Œf .z/ D 0. Using this family, a Stein divergence is DStein.p; q/ D sup f 2F jEq.z/Œf .z/ Ep.z j x/Œf .z/j: Now recall the operator objective of Equation 2. The closeness condition implies that L.qI Op;q; F ; t/ D sup f 2F t.Eq.z/Œ.Op;q f /.z/ Ep.z j x/Œ.Op;p f /.z//: In other words, operators with positive or negative expectations lead to Stein divergences with a more generalized notion of distance. 2.4 Langevin-Stein Operator Variational Objective We developed the operator variational objective. It is a class of tractable objectives, each of which can be optimized to yield an approximation to the posterior. An operator variational objective is built from an operator, function class, and distance function to zero. We now use this construction to design a new type of variational objective. An operator objective involves a class of functions that has known expectations with respect to an intractable distribution. There are many ways to construct such classes [1, 2]. Here, we construct an operator objective from the generator Stein’s method applied to the Langevin diffusion. 3 Let r>f denote the divergence of a vector-valued function f , that is, the sum of its individual gradients. Applying the generator method of Barbour [2] to Langevin diffusion gives the operator .Op ls f /.z/ D rz log p.x; z/>f .z/ C r>f: (3) We call this the Langevin-Stein (ls) operator. We obtain the corresponding variational objective by using the squared distance function and substituting Equation 3 into Equation 2, L.qI Op ls; F / D sup f 2F .EqŒrz log p.x; z/>f .z/ C r>f /2: (4) The ls operator satisfies both conditions. First, it satisfies closeness because it has expectation zero under the posterior (Appendix A) and its unique minimizer is the posterior (Appendix B). Second, it is tractable because it requires only the joint distribution. The functions f will also be a parametric family, which we detail later. Additionally, while the kl divergence finds variational distributions that underestimate the variance, the ls objective does not suffer from that pathology. The reason is that kl is infinite when the support of q is larger than p; here this is not the case. We provided one example of a variational objectives using operators, which is specific to continuous variables. In general, operator objectives are not limited to continuous variables; Appendix C describes an operator for discrete variables. 2.5 The KL Divergence as an Operator Variational Objective Finally, we demonstrate how classical variational methods fall inside the operator family. For example, traditional variational inference minimizes the kl divergence from an approximating family to the posterior [10]. This can be construed as an operator variational objective, .Op;q KL f /.z/ D log q.z/ log p.zjx/ 8f 2 F : (5) This operator does not use the family of functions—it trivially maps all functions f to the same function. Further, because kl is strictly positive, we use the identity distance t.a/ D a. The operator satisfies both conditions. It satisfies closeness because KL.pjjp/ D 0. It satisfies tractability because it can be computed up to a constant when used in the operator objective of Equation 2. Tractability comes from the fact that log p.z j x/ D log p.z; x/ log p.x/. 3 Operator Variational Inference We described operator variational objectives, a broad class of objectives for variational inference. We now examine how it can be optimized. We develop a black box algorithm [27, 19] based on Monte Carlo estimation and stochastic optimization. Our algorithm applies to a general class of models and any operator objective. Minimizing the operator objective involves two optimizations: minimizing the objective with respect to the approximating family Q and maximizing the objective with respect to the function class F (which is part of the objective). We index the family Q with variational parameters and require that it satisfies properties typically assumed by black box methods [19]: the variational distribution q.zI / has a known and tractable density; we can sample from q.zI /; and we can tractably compute the score function r log q.zI /. We index the function class F with parameters , and require that f./ is differentiable. In the experiments, we use neural networks, which are flexible enough to approximate a general family of test functions [8]. Given parameterizations of the variational family and test family, operator variational inference (opvi) seeks to solve a minimax problem, D inf sup t.EŒ.Op;qf/.z//: (6) We will use stochastic optimization [23, 13]. In principle, we can find stochastic gradients of by rewriting the objective in terms of the optimized value of , ./. In practice, however, we 4 Algorithm 1: Operator variational inference Input : Model log p.x; z/, variational approximation q.zI / Output: Variational parameters Initialize and randomly. while not converged do Compute unbiased estimates of rL from Equation 7. Compute unbiased esimates of rL from Equation 8. Update , with unbiased stochastic gradients. end simultaneously solve the maximization and minimization. Though computationally beneficial, this produces saddle points. In our experiments we found it to be stable enough. We derive gradients for the variational parameters and test function parameters . (We fix the distance function to be the square t.a/ D a2; the identity t.a/ D a also readily applies.) Gradient with respect to . For a fixed test function with parameters , denote the objective L D t.EŒ.Op;q f/.z//: The gradient with respect to variational parameters is rL D 2 EŒ.Op;q f/.z/ rEŒ.Op;q f/.z/: Now write the second expectation with the score function gradient [19]. This gradient is rL D 2 EŒ.Op;q f/.z/ EŒr log q.zI /.Op;q f/.z/ C r.Op;q f/.z/: (7) Equation 7 lets us calculate unbiased stochastic gradients. We first generate two sets of independent samples from q; we then form Monte Carlo estimates of the first and second expectations. For the second expectation, we can use the variance reduction techniques developed for black box variational inference, such as Rao-Blackwellization [19]. We described the score gradient because it is general. An alternative is to use the reparameterization gradient for the second expectation [11, 22]. It requires that the operator be differentiable with respect to z and that samples from q can be drawn as a transformation r of a parameter-free noise source , z D r.; /. In our experiments, we use the reparameterization gradient. Gradient with respect to . Mirroring the notation above, the operator objective for fixed variational is L D t.EŒ.Op;q f/.z//: The gradient with respect to test function parameters is rL D 2 EŒ.Op;qf/.z/ EŒrOp;q f.z/: (8) Again, we can construct unbiased stochastic gradients with two sets of Monte Carlo estimates. Note that gradients for the test function do not require score gradients (or reparameterization gradients) because the expectation does not depend on . Algorithm. Algorithm 1 outlines opvi. We simultaneously minimize the variational objective with respect to the variational family q while maximizing it with respect to the function class f. Given a model, operator, and function class parameterization, we can use automatic differentiation to calculate the necessary gradients [3]. Provided the operator does not require model-specific computation, this algorithm satisfies the black box criteria. 3.1 Data Subsampling and opvi With stochastic optimization, data subsampling scales up traditional variational inference to massive data [7, 26]. The idea is to calculate noisy gradients by repeatedly subsampling from the data set, without needing to pass through the entire data set for each gradient. 5 An as illustration, consider hierarchical models. Hierarchical models consist of global latent variables ˇ that are shared across data points and local latent variables zi each of which is associated to a data point xi. The model’s log joint density is log p.x1Wn; z1Wn; ˇ/ D log p.ˇ/ C n X iD1 h log p.xi j zi; ˇ/ C log p.zi j ˇ/ i : Hoffman et al. [7] calculate unbiased estimates of the log joint density (and its gradient) by subsampling data and appropriately scaling the sum. We can characterize whether opvi with a particular operator supports data subsampling. opvi relies on evaluating the operator and its gradient at different realizations of the latent variables (Equation 7 and Equation 8). Thus we can subsample data to calculate estimates of the operator when it derives from linear operators of the log density, such as differentiation and the identity. This follows as a linear operator of sums is a sum of linear operators, so the gradients in Equation 7 and Equation 8 decompose into a sum. The Langevin-Stein and kl operator are both linear in the log density; both support data subsampling. 3.2 Variational Programs Given an operator and variational family, Algorithm 1 optimizes the corresponding operator objective. Certain operators require the density of q. For example, the kl operator (Equation 5) requires its log density. This potentially limits the construction of rich variational approximations for which the density of q is difficult to compute.1 Some operators, however, do not depend on having a analytic density; the Langevin-Stein (ls) operator (Equation 3) is an example. These operators can be used with a much richer class of variational approximations, those that can be sampled from but might not have analytically tractable densities. We call such approximating families variational programs. Inference with a variational program requires the family to be reparameterizable [11, 22]. (Otherwise we need to use the score function, which requires the derivative of the density.) A reparameterizable variational program consists of a parametric deterministic transformation R of random noise . Formally, let Normal.0; 1/; z D R.I /: (9) This generates samples for z, is differentiable with respect to , and its density may be intractable. For operators that do not require the density of q, it can be used as a powerful variational approximation. This is in contrast to the standard Kullback-Leibler (kl) operator. As an example, consider the following variational program for a one-dimensional random variable. Let i denote the ith dimension of and make the corresponding definition for : z D .3 > 0/R.1I 1/ .3 0/R.2I 2/: (10) When R outputs positive values, this separates the parametrization of the density to the positive and negative halves of the reals; its density is generally intractable. In Section 4, we will use this distribution as a variational approximation. Equation 9 contains many densities when the function class R can approximate arbitrary continuous functions. We state it formally. Theorem 1. Consider a posterior distribution p.z j x/ with a finite number of latent variables and continuous quantile function. Assume the operator variational objective has a unique root at the posterior p.z j x/ and that R can approximate continuous functions. Then there exists a sequence of parameters 1; 2 : : : ; in the variational program, such that the operator variational objective converges to 0, and thus q converges in distribution to p.z j x/. This theorem says that we can use variational programs with an appropriate q-independent operator to approximate continuous distributions. The proof is in Appendix D. 1It is possible to construct rich approximating families with kl.qjjp/, but this requires the introduction of an auxiliary distribution [15]. 6 4 Empirical Study We evaluate operator variational inference on a mixture of Gaussians, comparing different choices in the objective. We then study logistic factor analysis for images. 4.1 Mixture of Gaussians Consider a one-dimensional mixture of Gaussians as the posterior of interest, p.z/ D 1 2Normal.zI 3; 1/ C 1 2Normal.zI 3; 1/. The posterior contains multiple modes. We seek to approximate it with three variational objectives: Kullback-Leibler (kl) with a Gaussian approximating family, Langevin-Stein (ls) with a Gaussian approximating family, and ls with a variational program. 5 0 5 Value of Latent Variable z KL Truth 5 0 5 Value of Latent Variable z Langevin-Stein Truth 5 0 5 Value of Latent Variable z Variational Program Truth Figure 1: The true posterior is a mixture of two Gaussians, in green. We approximate it with a Gaussian using two operators (in blue). The density on the far right is a variational program given in Equation 10 and using the Langevin-Stein operator; it approximates the truth well. The density of the variational program is intractable. We plot a histogram of its samples and compare this to the histogram of the true posterior. Figure 1 displays the posterior approximations. We find that the kl divergence and ls divergence choose a single mode and have slightly different variances. These operators do not produce good results because a single Gaussian is a poor approximation to the mixture. The remaining distribution in Figure 1 comes from the toy variational program described by Equation 10 with the ls operator. Because this program captures different distributions for the positive and negative half of the real line, it is able to capture the posterior. In general, the choice of an objective balances statistical and computational properties of variational inference. We highlight one tradeoff: the ls objective admits the use of a variational program; however, the objective is more difficult to optimize than the kl. 4.2 Logistic Factor Analysis Logistic factor analysis models binary vectors xi with a matrix of parameters W and biases b, zi Normal.0; 1/ xi;k Bernoulli..w> k zi C bk//; where zi has fixed dimension K and is the sigmoid function. This model captures correlations of the entries in xi through W . We apply logistic factor analysis to analyze the binarized MNIST data set [24], which contains 28x28 binary pixel images of handwritten digits. (We set the latent dimensionality to 10.) We fix the model parameters to those learned with variational expectation-maximization using the kl divergence, and focus on comparing posterior inferences. We compare the kl operator to the ls operator and study two choices of variational models: a fully factorized Gaussian distribution and a variational program. The variational program generates samples by transforming a K-dimensional standard normal input with a two-layer neural network, using rectified linear activation functions and a hidden size of twice the latent dimensionality. Formally, 7 Inference method Completed data log-likelihood Mean-field Gaussian + kl -59.3 Mean-field Gaussian + ls -75.3 Variational Program + ls -58.9 Table 1: Benchmarks on logistic factor analysis for binarized MNIST. The same variational approximation with ls performs worse than kl on likelihood performance. The variational program with ls performs better without directly optimizing for likelihoods. the variational program we use generates samples of z as follows: z0 Normal.0; I/ h0 D ReLU.W q 0 >z0 C bq 0/ h1 D ReLU.W q 1 >h0 C bq 1/ z D W q 2 >h1 C bq 2: The variational parameters are the weights W q and biases bq. For f , we use a three-layer neural network with the same hidden size as the variational program and hyperbolic tangent activations where unit activations were bounded to have norm two. Bounding the unit norm bounds the divergence. We used the Adam optimizer [12] with learning rates 210 4 for f and 210 5 for the variational approximation. There is no standard for evaluating generative models and their inference algorithms [25]. Following Rezende et al. [22], we consider a missing data problem. We remove half of the pixels in the test set (at random) and reconstruct them from a fitted posterior predictive distribution. Table 1 summarizes the results on 100 test images; we report the log-likelihood of the completed image. ls with the variational program performs best. It is followed by kl and the simpler ls inference. The ls performs better than kl even though the model parameters were learned with kl. 5 Summary We present operator variational objectives, a broad yet tractable class of optimization problems for approximating posterior distributions. Operator objectives are built from an operator, a family of test functions, and a distance function. We outline the connection between operator objectives and existing divergences such as the KL divergence, and develop a new variational objective using the Langevin-Stein operator. In general, operator objectives produce new ways of posing variational inference. Given an operator objective, we develop a black box algorithm for optimizing it and show which operators allow scalable optimization through data subsampling. Further, unlike the popular evidence lower bound, not all operators explicitly depend on the approximating density. This permits flexible approximating families, called variational programs, where the distributional form is not tractable. We demonstrate this approach on a mixture model and a factor model of images. There are several possible avenues for future directions such as developing new variational objectives, adversarially learning [5] model parameters with operators, and learning model parameters with operator variational objectives. Acknowledgments. This work is supported by NSF IIS-1247664, ONR N00014-11-1-0651, DARPA FA8750-14-2-0009, DARPA N66001-15-C-4032, Adobe, NSERC PGS-D, Porter Ogden Jacobus Fellowship, Seibel Foundation, and the Sloan Foundation. The authors would like to thank Dawen Liang, Ben Poole, Stephan Mandt, Kevin Murphy, Christian Naesseth, and the anonymous reviews for their helpful feedback and comments. References [1] Assaraf, R. and Caffarel, M. (1999). Zero-variance principle for monte carlo algorithms. In Phys. Rev. Let. [2] Barbour, A. D. (1988). Stein’s method and poisson process convergence. Journal of Applied Probability. 8 [3] Carpenter, B., Hoffman, M. D., Brubaker, M., Lee, D., Li, P., and Betancourt, M. (2015). The Stan Math Library: Reverse-mode automatic differentiation in C++. arXiv preprint arXiv:1509.07164. [4] Ghahramani, Z. and Beal, M. (2001). Propagation algorithms for variational Bayesian learning. In NIPS 13, pages 507–513. [5] Goodfellow, I., Pouget-Abadie, J., Mirza, M., Xu, B., Warde-Farley, D., Ozair, S., Courville, A., and Bengio, Y. (2014). Generative adversarial nets. In Neural Information Processing Systems. [6] Hernández-Lobato, J. M., Li, Y., Rowland, M., Hernández-Lobato, D., Bui, T., and Turner, R. E. (2015). Black-box ˛-divergence Minimization. arXiv.org. [7] Hoffman, M., Blei, D., Wang, C., and Paisley, J. (2013). Stochastic variational inference. Journal of Machine Learning Research, 14(1303–1347). [8] Hornik, K., Stinchcombe, M., and White, H. (1989). Multilayer feedforward networks are universal approximators. Neural networks, 2(5):359–366. [9] Hyvärinen, A. (2005). Estimation of non-normalized statistical models by score matching. Journal of Machine Learning Research, 6(Apr):695–709. [10] Jordan, M., Ghahramani, Z., Jaakkola, T., and Saul, L. (1999). Introduction to variational methods for graphical models. Machine Learning, 37:183–233. [11] Kingma, D. and Welling, M. (2014). Auto-encoding variational bayes. In (ICLR). [12] Kingma, D. P. and Ba, J. (2014). Adam: A method for stochastic optimization. CoRR, abs/1412.6980. [13] Kushner, H. and Yin, G. (1997). Stochastic Approximation Algorithms and Applications. Springer New York. [14] Li, Y. and Turner, R. E. (2016). Rényi divergence variational inference. arXiv preprint arXiv:1602.02311. [15] Maaløe, L., Sønderby, C. K., Sønderby, S. K., and Winther, O. (2016). Auxiliary deep generative models. arXiv preprint arXiv:1602.05473. [16] Minka, T. P. (2001). Expectation propagation for approximate Bayesian inference. In UAI. [17] Minka, T. P. (2004). Power EP. Technical report, Microsoft Research, Cambridge. [18] Nielsen, F. and Nock, R. (2013). On the chi square and higher-order chi distances for approximating f-divergences. arXiv preprint arXiv:1309.3029. [19] Ranganath, R., Gerrish, S., and Blei, D. (2014). Black Box Variational Inference. In AISTATS. [20] Ranganath, R., Tran, D., and Blei, D. M. (2016). Hierarchical variational models. In International Conference on Machine Learning. [21] Rezende, D. J. and Mohamed, S. (2015). Variational inference with normalizing flows. In Proceedings of the 31st International Conference on Machine Learning (ICML-15). [22] Rezende, D. J., Mohamed, S., and Wierstra, D. (2014). Stochastic backpropagation and approximate inference in deep generative models. In International Conference on Machine Learning. [23] Robbins, H. and Monro, S. (1951). A stochastic approximation method. The Annals of Mathematical Statistics, 22(3):pp. 400–407. [24] Salakhutdinov, R. and Murray, I. (2008). On the quantitative analysis of deep belief networks. In International Conference on Machine Learning. [25] Theis, L., van den Oord, A., and Bethge, M. (2016). A note on the evaluation of generative models. In International Conference on Learning Representations. [26] Titsias, M. and Lázaro-Gredilla, M. (2014). Doubly stochastic variational bayes for non-conjugate inference. In Proceedings of the 31st International Conference on Machine Learning (ICML-14), pages 1971– 1979. [27] Wingate, D. and Weber, T. (2013). Automated variational inference in probabilistic programming. ArXiv e-prints. 9 | 2016 | 489 |
6,426 | Learning from Small Sample Sets by Combining Unsupervised Meta-Training with CNNs Yu-Xiong Wang Martial Hebert Robotics Institute, Carnegie Mellon University {yuxiongw, hebert}@cs.cmu.edu Abstract This work explores CNNs for the recognition of novel categories from few examples. Inspired by the transferability properties of CNNs, we introduce an additional unsupervised meta-training stage that exposes multiple top layer units to a large amount of unlabeled real-world images. By encouraging these units to learn diverse sets of low-density separators across the unlabeled data, we capture a more generic, richer description of the visual world, which decouples these units from ties to a specific set of categories. We propose an unsupervised margin maximization that jointly estimates compact high-density regions and infers low-density separators. The low-density separator (LDS) modules can be plugged into any or all of the top layers of a standard CNN architecture. The resulting CNNs significantly improve the performance in scene classification, fine-grained recognition, and action recognition with small training samples. 1 Motivation To successfully learn a deep convolutional neural network (CNN) model, hundreds of millions of parameters need to be inferred from millions of labeled examples on thousands of image categories [1, 2, 3]. In practice, however, for novel categories/tasks of interest, collecting a large corpus of annotated data to train CNNs from scratch is typically unrealistic, such as in robotics applications [4] and for customized categories [5]. Fortunately, although trained on particular categories, CNNs exhibit certain attractive transferability properties [6, 7]. This suggests that they could serve as universal feature extractors for novel categories, either as off-the-shelf features or through fine-tuning [7, 8, 9, 10]. Such transferability is promising but still restrictive, especially for novel-category recognition from few examples [11, 12, 13, 14, 15, 16, 17, 18]. The overall generality of CNNs is negatively affected by the specialization of top layer units to their original task. Recent analysis shows that from bottom, middle, to top layers of the network, features make a transition from general to specific [6, 8]. While features in the bottom and middle layers are fairly generic to many categories (i.e., low-level features of Gabor filters or color blobs and mid-level features of object parts), high-level features in the top layers eventually become specific and biased to best discriminate between a particular set of chosen categories. With limited samples from target tasks, fine-tuning cannot effectively adjust the units and would result in over-fitting, since it typically requires a significant amount of labeled data. Using off-the-shelf CNNs becomes the best strategy, despite the specialization and reduced performance. In this work we investigate how to improve pre-trained CNNs for the learning from few examples. Our key insight is to expose multiple top layer units to a massive set of unlabeled images, as shown in Figure 1, which decouples these units from ties to the original specific set of categories. This additional stage is called unsupervised meta-training to distinguish this phase from the conventional unsupervised pre-training phase [19] and the training phase on the target tasks. Based on the above transferability analysis, intuitively, bottom and middle layers construct a feature space with highdensity regions corresponding to potential latent categories. Top layer units in the pre-trained CNN, however, only have access to those regions associated with the original, observed categories. The 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. 1.2
M
100
M
Supervised Pre-Training of Bottom and Middle Layers Unsupervised Meta-Training of Top Layers Novel Category Recognition from Few Examples è
è
Figure 1: We aim to improve the transferability of pre-trained CNNs for the recognition of novel categories from few labeled examples. We perform a multi-stage training procedure: 1) We first pre-train a CNN that recognizes a specific set of categories on a large-scale labeled dataset (e.g., ImageNet 1.2M), which provides fairly generic bottom and middle layer units; 2) We then meta-train the top layers as low-density separators on a far larger set of unlabeled data (e.g., Flickr 100M), which further improves the generality of multiple top layer units; 3) Finally, we use our modified CNN on new categories/tasks (e.g., scene classification, fine-grained recognition, and action recognition), either as off-the-shelf features or as initialization of fine-tuning that allows for end-to-end training. units are then tuned to discriminate between these regions by separating the regions while pushing them further away from each other. To tackle this limitation, our unsupervised meta-training provides a far larger pool of unlabeled images as a much less biased sampling in the feature space. Now, instead of producing separations tied to the original categories, we generate diverse sets of separations across the unlabeled data. Since the unit “tries to discriminate the data manifold from its surroundings, in all non-manifold directions”1, we capture a more generic and richer description of the visual world. How can we generate these separations in an unsupervised manner? Inspired by the structure/manifold assumption in shallow semi-supervised and unsupervised learning (i.e., the decision boundary should not cross high-density regions, but instead lie in low-density regions) [20, 21], we introduce a lowdensity separator (LDS) module that can be plugged into any (or all) top layers of a standard CNN architecture. More precisely, the vector of weights connecting a unit to its previous layer (together with the non-linearity) can be viewed as a separator or decision boundary in the activation space of the previous layer. LDS then generates connection weights (decision boundaries) between successive layers that traverse regions of as low density as possible and avoid intersecting high-density regions in the activation space. Many LDS methods typically infer a probability distribution, for example through densest region detection, lowest-density hyperplane estimation [21], and clustering [22]. However, exact clustering or density estimation is known to be notoriously difficult in high-dimensional spaces. We instead adopt a discriminative paradigm [20, 23, 24, 14] to circumvent the aforementioned difficulties. Using a max-margin framework, we propose an unsupervised, scalable, coarse-to-fine approach that jointly estimates compact, distinct high-density quasi-classes (HDQC), i.e., sets of data points sampled in high-density regions, as stand-ins for plausible high-density regions and infers lowdensity hyperplanes (separators). Our decoupled formulations generalize those in supervised binary code discovery [23] and semi-supervised learning [24], respectively; and more crucially, we propose a novel combined optimization to jointly estimate HDQC and learn LDS in large-scale unsupervised scenarios, from the labeled ImageNet 1.2M [25] to the unlabeled Flickr 100M dataset [26]. Our approach of exploiting unsupervised learning on top of CNN transfer learning is unique as opposed to other recent work on unsupervised, weakly-supervised, and semi-supervised deep learning. Most existing unsupervised deep learning approaches focus on unsupervised learning of visual representations that are both sparse and allow image reconstruction [19], including deep belief networks (DBN), convolutional sparse coding, and (denoising) auto-encoders (DAE). Our unsupervised LDS meta-training is different from conventional unsupervised pre-training as in DBN and DAE in two important ways: 1) our meta-training “post-arranges” the network that has undergone supervised training on a labeled dataset and then serves as a kind of network “pre-conditioner” [19] for the target tasks; and 2) our meta-training phase is not necessarily followed by fine-tuning and the features obtained by meta-training could be used off the shelf. Other types of supervisory information (by creating auxiliary tasks), such as clustering, surrogate classes [27, 4], spatial context, temporal consistency, web supervision, and image captions [28], have been explored to train CNNs in an unsupervised (or weakly-supervised) manner. Although showing 1Yoshua Bengio. https://disqus.com/by/yoshuabengio/ 2 initial promise, the performance of these unsupervised (or weakly-supervised) deep models is still not on par with that of their supervised counterparts, partially due to noisy or biased external information [28]. In addition, our LDS, if viewed as an auxiliary task, is directly related to discriminative classification, which results in more desirable and consistent features for the final novel-category recognition tasks. Unlike using a single image and its pre-defined transformations [27] or other labeled multi-view object [4] to simulate a surrogate class, our quasi-classes capture a more natural representation of realistic images. Finally, while we boost the overall generality of CNNs for a wide spectrum of unseen categories, semi-supervised deep learning approaches typically improve the model generalization for specific tasks, with both labeled and unlabeled data coming from the tasks of interest [29, 30]. Our contribution is three-fold: First, we show how LDS, based on an unsupervised margin maximization, is generated without a bias to a particular set of categories (Section 2). Second, we detail how to use LDS modules in CNNs by plugging them into any (or all) top layers of the architecture, leading to single-scale (or multi-scale) low-density separator networks (Section 3). Finally, we show how such modified CNNs, with enhanced generality, are used to facilitate the recognition of novel categories from few examples and significantly improve the performance in scene classification, fine-grained recognition, and action recognition (Section 4). The general setup is depicted in Figure 1. 2 Pre-trained low-density separators from unsupervised data Given a CNN architecture pre-trained on a specific set of categories, such as the ImageNet (ILSVRC) 1,000 categories, we aim to improve the generality of one of its top layers, e.g., the k-th layer. We fix the structures and weights of the layers from 1 to k−1, and view the activation of layer k−1 as a feature space. A unit s in layer k is fully connected to all the units in layer k−1 via a vector of weights ws. Each ws corresponds to a particular decision boundary (partition) of the feature space. Intuitively, all the ws’s then jointly further discriminate between these 1,000 categories, enforcing that the new activations in layer k are more similar within classes and more dissimilar between classes. To make ws’s and the associated units in layer k unspecific to the ImageNet 1,000 categories, we use a large amount of unlabeled images at the unsupervised meta-training stage. The layers from 1 to k−1 remain unchanged, which means that we still tackle the same feature space. The new unlabeled images now constitute a less biased sampling of the feature space in layer k−1. We introduce a new k-th layer with more units and encourage their unbiased exploration of the feature space. More precisely, we enforce that the units learn many diverse decision boundaries ws’s that traverse different low-density regions while avoiding intersecting high-density regions of the unsupervised data (untied to the original ImageNet categories). The set of possible arrangements of such decision boundaries is rich, meaning that we can potentially generalize to a broad range of categories. 2.1 Approach overview We denote column vectors and matrices with italic bold letters. For each unlabeled image Ii, where i ∈{1, 2, . . . , N}, let xi ∈RD and φi ∈RS be the vectorized activations in layers k −1 and k, respectively. Let W be the weights between the two layers, where ws is the weight vector associated with the unit s in layer k. For notational simplicity, xi already includes a constant 1 as the last element and ws includes the bias term. We then have φs i = f wsT xi , where f(·) is a non-linear function, such as sigmoid or ReLU. The resulting activation spaces of layers k−1 and k are denoted as X and F, respectively. To learn ws’s as low-density separators, we are supposed to have certain high-density regions which ws’s separate. However, accurate estimation of high-density regions is difficult. We instead generate quasi-classes as stand-ins for plausible high-density regions. We want samples with the same quasilabels to be similar in activation spaces (constraint within quasi-classes), while those with different quasi-labels should be very dissimilar in activation spaces (constraints between quasi-classes). Note that in contrast to clustering, generating quasi-classes does not require inferring membership for each data point. Formally, assuming that there are C desired quasi-classes, we introduce a sample selection vector Tc ∈{0, 1}N for each quasi-class c. Tc,i = 1 if Ii is selected for assignment to quasi-class c and zero otherwise. As illustrated in Figure 4, the optimization for seeking low-density separators (LDS) while identifying high-density quasi-classes (HDQC) can be framed as find W ∈LDS, T ∈HDQC (1) subject to W separate T . This optimization problem enforces that each unit s learns a partition ws lying across the low-density region among certain salient high-density quasi-classes discovered by T. This leads to a difficult joint optimization problem in theory, because W and T are interdependent. 3 In practice, however, it may be unnecessary to find the global optimum. Reasonable local optima are sufficient in our case to describe the feature space, as shown by the empirical results in Section 4. We use an iterative approach that obtains salient high-density quasi-classes from coarse to fine (Section 2.3) and produces promising discriminative low-density partitions among them (Section 2.2). We found that the optimization procedures converge in our experiments. 2.2 Learning low-density separators Assume that T is known, which means that we have already defined C high-density quasi-classes by Tc. We then use a max-margin formulation to learn W. Each unit s in layer k corresponds to a low-density hyperplane ws that separates positive and negative examples in a max-margin fashion. To train ws, we need to generate label variables ls ∈{−1, 1} for each ws, which label the samples in the quasi-classes either as positive (1) or negative (−1) training examples. We can stack all the labels for learning ws’s to form L = l1, . . . , lS. Moreover, in the activation space F of layer k, which is induced by the activation space X of layer k−1 and ws, it would be beneficial to further push for large inter-quasi-class and small intra-quasi-class distances. We achieve such properties by optimizing min W ,L,Φ S X s=1 ∥ws∥2+η N X i=1 S X s=1 Ii h 1−ls i wsTxi i + + λ1 2 C X c=1 N X u=1 v=1 Tc,uTc,vd (φu, φv) −λ2 2 C X c′=1 C X c′′=1 c′′̸=c′ N X p=1 q=1 Tc′,pTc′′,qd (φp, φq), (2) where d is a distance metric (e.g., square of Euclidean distance) in the activation space F of layer k. [x]+ = max (0, x) represents the hinge loss. Here we introduce an additional indicator vector I ∈{0, 1}N for all the quasi-classes. Ii = 0 if Ii is not selected for assignment to any quasi-class (i.e., PC c=1Tc,i = 0) and one otherwise. Note that I is actually sparse, since only a portion of unlabeled samples are selected as quasi-classes and only their memberships are estimated in T. The new objective is much easier to optimize compared to Eqn. (1), as it only requires producing the low-density separators ws from known quasi-classes given Tc. We then derive an algorithm to optimize problem (2) using block coordinate descent. Specifically, problem (2) can be viewed as a generalization of predictable discriminative binary codes in [23]: 1) compared with the fully labeled case in [23], Eqn. (2) introduces additional quasi-class indicator variables to handle the unsupervised scenario; 2) Eqn. (2) extends the specific binary-valued hash functions in [23] to general real-valued non-linear activation functions in neural networks. We adopt a similar iterative optimization strategy as in [23]. To achieve a good local minimum, our insight is that there should be diversity in ws’s and we thus initialize ws’s as the top-S orthogonal directions of PCA on data points belonging to the quasi-classes. We found that this initialization yields promising results that work better than random initialization and do not contaminate the pre-trained CNNs. For fixed W, we update Φ using stochastic gradient descent to achieve improved separation in the activation space F of layer k. This optimization is efficient if using ReLU as non-linearity. We use Φ to update L. ls i = 1 if φs i > 0 and zero otherwise. Using L as training labels, we then train S linear SVMs to update W. We iterate this process a fixed number of times—2 ∼4 in practice, and we thus obtain the low-density separator ws for each unit and construct the activation space F of layer k. 2.3 Generating high-density quasi-classes In the previous section, we assumed T known and learned low-density separators between highdensity quasi-classes. Now we explain how to find these quasi-classes. Given the activation space X of layer k−1 and the activation space F of layer k (linked by the low-density separators W as weights), we need to generate C high-density quasi-classes from the unlabeled data selected by Tc. We hope that the quasi-classes are distinct and compact in the activation spaces. That is, we want samples belonging to the same quasi-classes to be close to each other in the activation spaces, while samples from different quasi-classes should be far from each other in the activation spaces. To this end, we propose a coarse-to-fine procedure that combines the seeding heuristics of K-means++ [31] and a max-margin formulation [24] to gradually augment confident samples into the quasi-classes. We suppose that each quasi-class contains at least τ0 images and at most τ images. Learning T includes the following steps: Skeleton Generation. We first choose a single seed point Tc,ic = 1 for each quasi-class using the K-means++ heuristics in the activation space X of layer k−1. All the seed points are now spread out as the skeleton of the quasi-classes. 4 CNN Single-Scale LDS+CNN Layer Layer 2 Layer1 Output Layer Multi-Scale LDS+CNN LDS Layer Layer 2 Layer 1 Output Layer LDS Layer Layer 1 Output Layer LDS Layer K Layer K Layer k (a) … … Conv Max-pool Avg-pool è è ê Layer i Conv Avg-pool è ê Layer K Conv Norm Max-pool Avg-pool è è è ê è Layer LDS FCa ê FCb ê LDS FCa ê FCb Softmax ê ê ê Add LDS FCa ê FCb ê ReLU ReLU ReLU j ê ê ê (b) Figure 2: We use our LDS to revisit CNN architectures. In Figure 2a, we embed LDS learned from a large collection of unlabeled data as a new top layer into a standard CNN structure pre-trained on a specific set of categories (left), leading to single-scale LDS+CNN (middle). LDS could be also embedded into different layers, resulting multi-scale LDS+CNN (right). More specifically in Figure 2b, our multi-scale LDS+CNN architecture is constructed by introducing LDS layers into multi-scale DAG-CNN [10]. For each scale (level), we spatially (average) pool activations, learn and plug in LDS in this activation space, add fully-connected layers FCa and FCb (with K outputs), and finally add the scores across all layers as predictions for K output classes (that are finally soft-maxed together) on the target task. We show that the resulting LDS+CNNs can be either used as off-the-shelf features or discriminatively trained in an end-to-end fashion to facilitate novel category recognition. Quasi-Class Initialization. We extend each single skeletal point to an initial quasi-class by adding its nearest neighbors [31] in the activation space X of layer k−1. Each of the resulting quasi-classes thus contains τ0 images, which satisfies the constraint for the minimum number of selected samples. Augmentation and Refinement. In the above two steps, we select samples for quasi-classes based on the similarity in the activation space of layer k−1. Given this initial estimate of quasi-classes, we select additional samples using joint similarity in both activation spaces of layers k−1 and k by leveraging a max-margin formulation. For each quasi-class c, we construct quasi-class classifiers hX c and hF c in the two activation spaces. Note that hX c and hF c are different from the low-density separator ws. We use SVM responses to select additional samples, leading to the following optimization: min T ,hX c ,hF c α C X c=1
hX c
2 2 + λX N X i=1 Ii h 1 −yc,i hX T c xi i + ! + C X c′=1 C X c′′=1 c′̸=c′′ N X j=1 Tc′,jTc′′,j +β C X c=1
hF c
2 2 + λF N X i=1 Ii h 1 −yc,i hFT c φi i + − N X j=1 Tc,j hFT c φj ! s.t. τ0 ≤ N X i=1 Tc,i ≤τ, ∀c ∈{1, . . . , C}, (3) where yc,i is the corresponding binary label used for one-vs.-all multi-quasi-class classification: yc,i = 1 if Tc,i = 1 and −1 otherwise. The first and second terms denote a max-margin classifier in the activation space X, and the fourth and fifth terms denote a max-margin classifier in the activation space F. The third term ensures that the same unlabeled sample is not shared by multiple quasiclasses. The last term is a sample selection criterion that chooses those unlabeled samples with high classifier responses in the activation space F. This formulation is inspired by the approach to selecting unlabeled images using joint visual features and attributes [24]. We view our activation space X of layer k −1 as the feature space, and the activation space F of layer k as the learned attribute space. However, different from the semisupervised scenario in [24], which provides an initially labeled training images, our problem (3) is entirely unsupervised. To solve it, we use initial T corresponding to the quasi-classes obtained in the first two steps to train hX c and hF c . After obtaining these two sets of SVMs in both activation spaces, we update T . Following a similar block coordinate descent procedure as in [24], we iteratively re-train both hX c and hF c and update T until we obtain the desired τ number of samples. 3 Low-density separator networks 3.1 Single-scale layer-wise training We start from how to embed our LDS as a new top layer into a standard CNN structure, leading to single-scale network. To improve the generality of the learned units in layer k, we need to prevent co-adaptation and enforce diversity between these units [6, 19]. We adopt a simple random sampling strategy to train the entire LDS layer. We break the units in layer k into (disjoint) blocks, as shown 5 in Figure 4. We encourage each block of units to explore different regions of the activation space described by a random subset of unlabeled samples. This sampling strategy also makes LDS learning scalable since direct LDS learning from the entire dataset is computationally infeasible. Specifically, from an original selection matrix T0 ∈{0, 1}N×C of all zeros, we first obtain a random sub-matrix T ∈{0, 1}M×C. Using this subset of M samples, we then generate C high-density quasi-classes by solving the problem (3) and learn S corresponding low-density separator weights by solving the problem (2), yielding a block of S units in layer k. We randomly produce J sub-matrices T, repeat the procedure, and obtain S×J units (J blocks) in total. This thus constitutes layer k, the low-density separator layer. The entire single-scale structure is shown in Figure 2a. 3.2 Multi-scale structure For a convolutional layer of size H1×H2×F, where H1 is the height, H2 is the width, and F is the number of filter channels, we first compute a 1×1×F pooled feature by averaging across spatial dimensions as in [10], and then learn LDS in this activation space as before. Note that our approach applies to other types of pooling operation as well. Given the benefit of complementary features, LDS could also be operationalized on several different layers, leading to multi-scale/level representations. We thus modify the multi-scale DAG-CNN architecture [10] by introducing LDS on top of the ReLU layers, leading to multi-scale LDS+CNN, as shown in Figure 2b. We add two additional layers on top of LDS: FCa (with F outputs) that selects discriminative units for target tasks, and FCb (with K outputs) that learns K-way classifier for target tasks. The output of the LDS layers could be used as off-the-shelf multi-scale features. If using LDS weights as initialization, the entire structure in Figure 2b could also be fine-tuned in a similar fashion as DAG-CNN [10]. 4 Experimental evaluation In this section, we explore the use of low-density separator networks (LDS+CNNs) on a number of supervised learning tasks with limited data, including scene classification, fine-grained recognition, and action recognition. We use two powerful CNN models—AlexNet [1] and VGG19 [3] pre-trained on ILSVRC 2012 [25], as our reference networks. We implement the unsupervised meta-training on Yahoo! Flickr Creative Commons100M dataset (YFCC100M) [26], which is the largest single publicly available image and video database. We begin with plugging LDS into a single layer, and then introduce LDS into several top layers, leading to a multi-scale model. We consider using LDS+CNNs as off-the-shelf features in the small sample size regime, as well as through fine-tuning when enough data is available in the target task. Implementation Details. During unsupervised meta-training, we use 99.2 million unlabeled images on YFCC100M [26]. After resizing the smallest side of each image to be 256, we generate the standard 10 crops (4 corners plus one center and their flips) of size 224×224 as implemented in Caffe [32]. For single-scale structures, we learn LDS in the fc7 activation space of dimension 4,096. For multi-scale structures, following [10] we learn LDS in activation spaces of Conv3, Conv4, Conv5, fc6, and fc7 for AlexNet, and we learn LDS in activation spaces of Conv43, Conv44, Conv51, Conv52, and fc6 for VGG19. We use the same sets of parameters to learn LDS in these activation spaces without further tuning. In the LDS layer, each block has S = 10 units, which separate across M = 20,000 randomly sub-sampled data points. Repeating J = 2,000 sub-sampling, we then have 20,000 units in total. Notably, each block of units in the LDS layer can be learned independently, making feasible for parallelization. For learning LDS in Eqn. (2), η and λ1 are set to 1 and λ2 is set to normalize for the size of quasi-classes, which is the same setup and default parameters as in [23]. For generating high-density quasi-classes in Eqn. (3), following [31, 24], we set the minimum and maximum number of selected samples per quasi-classes to be τ0 =6 and τ =56, and produce C =30 quasi-classes in total. We use the same setup and parameters as in [24], where α=1, β =1. While using only the center crops to infer quasi-classes, we use all 10 crops to learn more accurate LDS. Tasks and Datasets. We evaluate on standard benchmark datasets for scene classification: SUN397 [33] and MIT-67 [34], fine-grained recognition: Oxford 102 Flowers [35], and action recognition (compositional semantic recognition): Stanford-40 actions [36]. These datasets are widely used for evaluating the CNN transferability [8], and we consider their diversity and coverage of novel categories. We follow the standard experimental setup (e.g., the train/test splits) for these datasets. 4.1 Learning from few examples The first question to answer is whether the LDS layers improve the transferability of the original pre-trained CNNs and facilitate the recognition of novel categories from few examples. To answer this 6 1 5 10 20 50 10 20 30 40 50 60 70 Number of Training Examples per Category Accuracy (%) SUN−397 MS−LDS+CNN SS−LDS+CNN MS−DAG−CNN SS−CNN Places−CNN 135 10 15 20 25 30 40 50 80 30 40 50 60 70 80 Number of Training Examples per Category Accuracy (%) MIT−67 MS−LDS+CNN SS−LDS+CNN MS−DAG−CNN SS−CNN 1 2 3 4 5 6 7 8 9 10 40 50 60 70 80 90 100 Number of Training Examples per Category Accuracy (%) 102 Flowers MS−LDS+CNN SS−LDS+CNN MS−DAG−CNN SS−CNN 135 10 20 30 40 50 60 70 80 90 100 20 30 40 50 60 70 80 Number of Training Examples per Category Accuracy (%) Stanford−40 MS−LDS+CNN SS−LDS+CNN MS−DAG−CNN SS−CNN Figure 3: Performance comparisons between our single-scale LDS+CNN (SS-LDS+CNN), multiscale LDS+CNN (MS-LDS+CNN) and the pre-trained single-scale CNN (SS-CNN), multi-scale DAG-CNN (MS-DAG-CNN) baselines for scene classification, fine-grained recognition, and action recognition from few labeled examples on four benchmark datasets. VGG19 [3] is used as the CNN model for its demonstrated superior performance. For SUN-397, we also include a publicly available strong baseline, Places-CNN, which trained a CNN (AlexNet architecture) from scratch using a scene-centric database with over 7 million annotated images from 400 scene categories, and which achieved state-of-the-art performance for scene classification [2]. X-axis: number of training examples per class. Y-axis: average multi-class classification accuracy. With improved transferability gained from a large set of unlabeled data, our LDS+CNNs with simple linear SVMs significantly outperform the vanilla pre-trained CNN and powerful DAG-CNN for small sample learning. Type Approach SUN-397 MIT-67 102 Flowers Stanford-40 Weakly-supervised CNNs Flickr-AlexNet 42.7 55.8 74.2 53.0 Flickr-GoogLeNet 44.4 55.6 65.8 52.8 Combined-AlexNet 47.3 58.8 83.3 56.4 Combined-GoogLeNet 55.0 67.9 83.7 69.2 Ours SS-LDS+CNN 55.4 73.6 87.5 70.5 MS-LDS+CNN 59.9 80.2 95.4 72.6 Table 1: Performance comparisons of classification accuracy (%) between our LDS+CNNs and weakly-supervised CNNs [28] on the four datasets when using the entire training sets. In contrast to our approach that uses the Flickr dataset for unsupervised meta-training, Flickr-AlexNet/GoogLeNet train CNNs from scratch on the Flickr dataset by using associated captions as weak supervisory information. Combined-AlexNet/GoogLeNet concatenate features from supervised ImageNet CNNs and weakly-supervised Flickr CNNs. Despite the same amount of data used for pre-training, ours outperform the weakly-supervised CNNs by a significant margin due to their noisy captions and tags. question, we evaluate both LDS+CNN and CNN as off-the-shelf features without fine-tuning on the target datasets. This is the standard way to use pre-trained CNNs [7]. We test how performance varies with the number of training samples per category as in [16]. To compare with the state-of-the-art performance, we use VGG19 in this set of experiments. Following the standard practice, we train simple linear SVMs in one-vs.-all fashion on L2-normalized features [7, 10] in Liblinear [37]. Single-Scale Features. We begin by evaluating single-scale features on theses datasets. For a fair comparison, we first reduce the dimensionality of LDS+CNN from 20,000 to 4,096, the same dimensionality as CNN, followed by linear SVMs. This is achieved by selecting from LDS+CNN the 4,096 most active features according to the standard criterion of multi-class recursive feature elimination (RFE) [38] using the target dataset. We also tested PCA. The performance drops, but it is still significantly better than the pre-trained CNN. Figure 3 summarizes the average performance over 10 random splits on these datasets. When used as off-the-shelf features for small-sample learning, our single-scale LDS+CNN significantly outperforms the vanilla pre-trained CNN, which is already a strong baseline. Our results are particularly impressive for the big performance boost, for example nearly 20% on MIT-67, in the one-shot learning scenario. This verifies the effectiveness of the layer-wise LDS, which leads to a more generic representation for a broad range of novel categories. 7 .
.
.
…
.
.
.
Layer k (LDS) Layer k −1 Unsupervised data A set of quasi-classes A block of units Low-density separators Figure 4: Illustration of learning low-density separators between successive layers on a large amount of unlabeled data. Note the color correspondence between the decision boundaries across the unlabeled data and the connection weights in the network. 40 45 50 55 60 65 70 SS-CNN-OTS SS-CNN-FT MS-DAG-CNN-OTS MS-DAG-CNN-FT SS-LDS+CNN-OTS SS-LDS+CNN-FT MS-LDS+CNN-OTS MS-LDS+CNN-FT Accuracy (%) SUN397 MIT67 Figure 5: Effect of fine-tuning (FT) on SUN-397 (purple bars) and MIT-67 (blue bars). Fine-tuning LDS+CNNs (AlexNet) further improves the performance over the off-the-shelf (OTS) features for novel category recognition. Multi-Scale Features. Given the promise of single-scale LDS+CNN, we now evaluate multi-scale off-the-shelf features. After learning LDS in each activation space separately, we reduce their dimensionality to that of the corresponding activation space via RFE for a fair comparison with DAGCNN [10]. We train linear SVMs on these LDS+CNNs, and then average their predictions. Figure 3 summarizes the average performance over different splits for multi-scale features. Consistent with the single-scale results, our multi-scale LDS+CNN outperforms the powerful multi-scale DAG-CNN. LDS+CNN is especially beneficial to fine-grained recognition, since there is typically limited data per class for fine-grained categories. Figure 3 also validates that multi-scale LDS+CNN allows for transfer at different levels, thus leading to better generalization to novel recognition tasks compared to its single-scale counterpart. In addition, Table 1 further shows that our LDS+CNNs outperform weakly-supervised CNNs [28] that are directly trained on Flickr using external caption information. 4.2 Fine-tuning With more training data available in the target task, our LDS+CNNs could be fine-tuned to further improve the performance. For efficient and easy fine-tuning, we use AlexNet in this set of experiments as in [10]. We evaluate the effect of fine-tuning of our single-scale and multi-scale LDS+CNNs in the scene classification tasks, due to their relatively large number of training samples. We compare against the fine-tuned single-scale CNN and multi-scale DAG-CNN [10], as shown in Figure 5. For completeness, we also include their off-the-shelf performance. As expected, fine-tuned models consistently outperform their off-the-shelf counterparts. Importantly, Figure 5 shows that our approach is not limited to small-sample learning and is still effective even in the many training examples regime. 5 Conclusions Even though current large-scale annotated datasets are comprehensive, they are only a tiny sampling of the full visual world biased to a selection of categories. It is still not clear how to take advantage of truly large sets of unlabeled real-world images, which constitute a much less biased sampling of the visual world. In this work we proposed an approach to leveraging such unsupervised data sources to improve the overall transferability of supervised CNNs and thus to facilitate the recognition of novel categories from few examples. This is achieved by encouraging multiple top layer units to generate diverse sets of low-density separations across the unlabeled data in activation spaces, which decouples these units from ties to a specific set of categories. The resulting modified CNNs (single-scale and multi-scale low-density separator networks) are fairly generic to a wide spectrum of novel categories, leading to significant improvement for scene classification, fine-grained recognition, and action recognition. The specific implementation described here is a first step. While we used certain max-margin optimization to train low-density separators, it would be interesting to integrate into the current CNN backpropagation framework both learning low-density separators and gradually estimating high-density quasi-classes. Acknowledgments. We thank Liangyan Gui, Carl Doersch, and Deva Ramanan for valuable and insightful discussions. This work was supported in part by ONR MURI N000141612007 and U.S. Army Research Laboratory (ARL) under the Collaborative Technology Alliance Program, Cooperative Agreement W911NF-102-0016. We also thank NVIDIA for donating GPUs and AWS Cloud Credits for Research program. 8 References [1] A. Krizhevsky, I. Sutskever, and G. E. Hinton. ImageNet classification with deep convolutional neural networks. In NIPS, 2012. [2] B. Zhou, A. Lapedriza, J. Xiao, A. Torralba, and A. Oliva. Learning deep features for scene recognition using places database. In NIPS, 2014. [3] K. Simonyan and A. Zisserman. Very deep convolutional networks for large-scale image recognition. In ICLR, 2015. [4] D. Held, S. Thrun, and S. Savarese. Robust single-view instance recognition. In ICRA, 2016. [5] Y.-X. Wang and M. Hebert. Model recommendation: Generating object detectors from few samples. In CVPR, 2015. [6] J. Yosinski, J. Clune, Y. Bengio, and H. Lipson. How transferable are features in deep neural networks? In NIPS, 2014. [7] A. S. Razavian, H. Azizpour, J. Sullivan, and S. Carlsson. CNN features off-the-shelf: An astounding baseline for recognition. In CVPR Workshop, 2014. [8] H. Azizpour, A. S. Razavian, J. Sullivan, A. Maki, and S. Carlsson. Factors of transferability for a generic ConvNet representation. TPAMI, 2015. [9] M. Oquab, L. Bottou, I. Laptev, and J. Sivic. Learning and transferring mid-level image representations using convolutional neural networks. In CVPR, 2014. [10] S. Yang and D. Ramanan. Multi-scale recognition with DAG-CNNs. In ICCV, 2015. [11] G. Koch, R. Zemel, and R. Salakhutdinov. Siamese neural networks for one-shot image recognition. In ICML Workshops, 2015. [12] B. M. Lake, R. Salakhutdinov, and J. B. Tenenbaum. Human-level concept learning through probabilistic program induction. Science, 350(6266):1332–1338, 2015. [13] O. Vinyals, C. Blundell, T. Lillicrap, K. Kavukcuoglu, and D. Wierstra. Matching networks for one shot learning. In NIPS, 2016. [14] Y.-X. Wang and M. Hebert. Learning by transferring from unsupervised universal sources. In AAAI, 2016. [15] Z. Li and D. Hoiem. Learning without forgetting. In ECCV, 2016. [16] Y.-X. Wang and M. Hebert. Learning to learn: Model regression networks for easy small sample learning. In ECCV, 2016. [17] L. Bertinetto, J. F. Henriques, J. Valmadre, P. Torr, and A. Vedaldi. Learning feed-forward one-shot learners. In NIPS, 2016. [18] B. Hariharan and R. Girshick. Low-shot visual object recognition. arXiv preprint arXiv:1606.02819, 2016. [19] I. Goodfellow, Y. Bengio, and A. Courville. Deep learning. Book in preparation for MIT Press, 2016. [20] O. Chapelle and A. Zien. Semi-supervised classification by low density separation. In AISTATS, 2005. [21] S. Ben-david, T. Lu, D. Pál, and M. Sotáková. Learning low density separators. In AISTATS, 2009. [22] J. Hoffman, B. Kulis, T. Darrell, and K. Saenko. Discovering latent domains for multisource domain adaptation. In ECCV, 2012. [23] M. Rastegari, A. Farhadi, and D. Forsyth. Attribute discovery via predictable discriminative binary codes. In ECCV, 2012. [24] J. Choi, M. Rastegari, A. Farhadi, and L. S. Davis. Adding unlabeled samples to categories by learned attributes. In CVPR, 2013. [25] O. Russakovsky, J. Deng, H. Su, J. Krause, S. Satheesh, S. Ma, Z. Huang, A. Karpathy, A. Khosla, M. Bernstein, A. C. Berg, and L. Fei-Fei. ImageNet large scale visual recognition challenge. IJCV, 115(3):211–252, 2015. [26] B. Thomee, D. A. Shamma, G. Friedland, B. Elizalde, K. Ni, D. Poland, D. Borth, and L.-J. Li. YFCC100M: The new data in multimedia research. Communications of the ACM, 59(2):64–73, 2016. [27] A. Dosovitskiy, J. T. Springenberg, M. Riedmiller, and T. Brox. Discriminative unsupervised feature learning with convolutional neural networks. In NIPS, 2014. [28] A. Joulin, L. van der Maaten, A. Jabri, and N. Vasilache. Learning visual features from large weakly supervised data. In ECCV, 2016. [29] J. Weston, F. Ratle, H. Mobahi, and R. Collobert. Deep learning via semi-supervised embedding. In ICML, 2008. [30] A. Ahmed, K. Yu, W. Xu, Y. Gong, and E. P. Xing. Training hierarchical feed-forward visual recognition models using transfer learning from pseudo-tasks. In ECCV, 2008. [31] D. Dai and L. Van Gool. Ensemble projection for semi-supervised image classification. In ICCV, 2013. [32] Y. Jia, E. Shelhamer, J. Donahue, S. Karayev, J. Long, R. Girshick, S. Guadarrama, and T. Darrell. Caffe: Convolutional architecture for fast feature embedding. In ACM MM, 2014. [33] J. Xiao, K. A. Ehinger, J. Hays, A. Torralba, and A. Oliva. SUN database: Exploring a large collection of scene categories. IJCV, 119(1):3–22, 2016. [34] A. Torralba and A. Quattoni. Recognizing indoor scenes. In CVPR, 2009. [35] M.-E. Nilsback and A. Zisserman. Automated flower classification over a large number of classes. In ICVGIP, 2008. [36] B. Yao, X. Jiang, A. Khosla, A. L. Lin, L. Guibas, and L. Fei-Fei. Human action recognition by learning bases of action attributes and parts. In ICCV, 2011. [37] R.-E. Fan, K.-W. Chang, C.-J. Hsieh, X.-R. Wang, and C.-J. Lin. LIBLINEAR: A library for large linear classification. JMLR, 9:1871–1874, 2008. [38] A. Bergamo and L. Torresani. Classemes and other classifier-based features for efficient object categorization. TPAMI, 36(10):1988–2001, 2014. 9 | 2016 | 49 |
6,427 | Unsupervised Learning for Physical Interaction through Video Prediction Chelsea Finn∗ UC Berkeley cbfinn@eecs.berkeley.edu Ian Goodfellow OpenAI ian@openai.com Sergey Levine Google Brain UC Berkeley slevine@google.com Abstract A core challenge for an agent learning to interact with the world is to predict how its actions affect objects in its environment. Many existing methods for learning the dynamics of physical interactions require labeled object information. However, to scale real-world interaction learning to a variety of scenes and objects, acquiring labeled data becomes increasingly impractical. To learn about physical object motion without labels, we develop an action-conditioned video prediction model that explicitly models pixel motion, by predicting a distribution over pixel motion from previous frames. Because our model explicitly predicts motion, it is partially invariant to object appearance, enabling it to generalize to previously unseen objects. To explore video prediction for real-world interactive agents, we also introduce a dataset of 59,000 robot interactions involving pushing motions, including a test set with novel objects. In this dataset, accurate prediction of videos conditioned on the robot’s future actions amounts to learning a “visual imagination” of different futures based on different courses of action. Our experiments show that our proposed method produces more accurate video predictions both quantitatively and qualitatively, when compared to prior methods. 1 Introduction Object detection, tracking, and motion prediction are fundamental problems in computer vision, and predicting the effect of physical interactions is a critical challenge for learning agents acting in the world, such as robots, autonomous cars, and drones. Most existing techniques for learning to predict physics rely on large manually labeled datasets (e.g. [18]). However, if interactive agents can use unlabeled raw video data to learn about physical interaction, they can autonomously collect virtually unlimited experience through their own exploration. Learning a representation which can predict future video without labels has applications in action recognition and prediction and, when conditioned on the action of the agent, amounts to learning a predictive model that can then be used for planning and decision making. However, learning to predict physical phenomena poses many challenges, since real-world physical interactions tend to be complex and stochastic, and learning from raw video requires handling the high dimensionality of image pixels and the partial observability of object motion from videos. Prior video prediction methods have typically considered short-range prediction [17], small image patches [22], or synthetic images [20]. Such models follow a paradigm of reconstructing future frames from the internal state of the model. In our approach, we propose a method which does not require the model to store the object and background appearance. Such appearance information is directly available in the previous frame. We develop a predictive model which merges appearance information ∗Work was done while the author was at Google Brain. 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. from previous frames with motion predicted by the model. As a result, the model is better able to predict future video sequences for multiple steps, even involving objects not seen at training time. To merge appearance and predicted motion, we output the motion of pixels relative to the previous image. Applying this motion to the previous image forms the next frame. We present and evaluate three motion prediction modules. The first, which we refer to as dynamic neural advection (DNA), outputs a distribution over locations in the previous frame for each pixel in the new frame. The predicted pixel value is then computed as an expectation under this distribution. A variant on this approach, which we call convolutional dynamic neural advection (CDNA), outputs the parameters of multiple normalized convolution kernels to apply to the previous image to compute new pixel values. The last approach, which we call spatial transformer predictors (STP), outputs the parameters of multiple affine transformations to apply to the previous image, akin to the spatial transformer network previously proposed for supervised learning [11]. In the case of the latter two methods, each predicted transformation is meant to handle separate objects. To combine the predictions into a single image, the model also predicts a compositing mask over each of the transformations. DNA and CDNA are simpler and easier to implement than STP, and while all models achieve comparable performance, the object-centric CDNA and STP models also provide interpretable internal representations. Our main contribution is a method for making long-range predictions in real-world videos by predicting pixel motion. When conditioned on the actions taken by an agent, the model can learn to imagine different futures from different actions. To learn about physical interaction from videos, we need a large dataset with complex object interactions. We collected a dataset of 59,000 robot pushing motions, consisting of 1.5 million frames and the corresponding actions at each time step. Our experiments using this new robotic pushing dataset, and using a human motion video dataset [10], show that models that explicitly transform pixels from previous frames better capture object motion and produce more accurate video predictions compared to prior state-of-the-art methods. The dataset, video results, and code are all available online: sites.google.com/site/robotprediction. 2 Related Work Video prediction: Prior work on video prediction has tackled synthetic videos and short-term prediction in real videos. Yuan et al. [30] used a nearest neighbor approach to construct predictions from similar videos in a dataset. Ranzato et al. proposed a baseline for video prediction inspired by language models [21]. LSTM models have been adapted for video prediction on patches [22], actionconditioned Atari frame predictions [20], and precipitation nowcasting [28]. Mathieu et al. proposed new loss functions for sharper frame predictions [17]. Prior methods generally reconstruct frames from the internal state of the model, and some predict the internal state directly, without producing images [23]. Our method instead transforms pixels from previous frames, explicitly modeling motion and, in the case of the CDNA and STP models, decomposing it over image segments. We found in our experiments that all three of our models produce substantially better predictions by advecting pixels from the previous frame and compositing them onto the new image, rather than constructing images from scratch. This approach differs from recent work on optic flow prediction [25], which predicts where pixels will move to using direct optical flow supervision. Boots et al. predict future images of a robot arm using nonparametric kernel-based methods [4]. In contrast to this work, our approach uses flexible parametric models, and effectively predicts interactions with objects, including objects not seen during training. To our knowledge, no previous video prediction method has been applied to predict real images with novel object interactions beyond two time steps into the future. There have been a number of promising methods for frame prediction developed concurrently to this work [16]. Vondrick et al. [24] combine an adversarial objective with a multiscale, feedforward architecture, and use a foreground/background mask similar to the masking scheme proposed here. De Brabandere et al. [6] propose a method similar to our DNA model, but use a softmax for sharper flow distributions. The probabilistic model proposed by Xue et al. [29] predicts transformations applied to latent feature maps, rather than the image itself, but only demonstrates single frame prediction. Learning physics: Several works have explicitly addressed prediction of physical interactions, including predicting ball motion [5], block falling [2], the effects of forces [19, 18], future human interactions [9], and future car trajectories [26]. These methods require ground truth object pose information, segmentation masks, camera viewpoint, or image patch trackers. In the domain of reinforcement learning, model-based methods have been proposed that learn prediction on images [14, 27], but they have either used synthetic images or instance-level models, and have not demonstrated 2 !le stride 2 stride 2 5x5 conv 1 RGB input 64x64x3 32x32 32 c 5x5 conv LSTM 1 32x32 32 c 5x5 conv LSTM 2 32x32 32 c 5x5 conv LSTM 3 16x16 64 c 5x5 conv LSTM 4 16x16 64 c 5x5 conv LSTM 5 8x8 128 c robot state 5 ac!on 5 8x8 10 c 5x5 conv LSTM 6 16x16 64 c concatenate 5x5 conv LSTM 7 32x32 32 c 1x1 conv 2 64x64 11 c composi!ng masks 64x64 channel soGmax fully connected, reshape & normalize 10 5x5 CDNA kernels convolve 10 64x64x3 transformed images masked composi!ng stride 2 deconv 2 deconv 2 deconv 2 64x64 RGB predic!on Ξ Figure 1: Architecture of the CDNA model, one of the three proposed pixel advection models. We use convolutional LSTMs to process the image, outputting 10 normalized transformation kernels from the smallest middle layer of the network and an 11-channel compositing mask from the last layer (including 1 channel for static background). The kernels are applied to transform the previous image into 10 different transformed images, which are then composited according to the masks. The masks sum to 1 at each pixel due to a channel-wise softmax. Yellow arrows denote skip connections. generalization to novel objects nor accurate prediction on real-world videos. As shown by our comparison to LSTM-based prediction designed for Atari frames [20], models that work well on synthetic domains do not necessarily succeed on real images. Video datasets: Existing video datasets capture YouTube clips [12], human motion [10], synthetic video game frames [20], and driving [8]. However, to investigate learning visual physics prediction, we need data that exhibits rich object motion, collisions, and interaction information. We propose a large new dataset consisting of real-world videos of robot-object interactions, including complex physical phenomena, realistic occlusions, and a clear use-case for interactive robot learning. 3 Motion-Focused Predictive Models In order to learn about object motion while remaining invariant to appearance, we introduce a class of video prediction models that directly use appearance information from previous frames to construct pixel predictions. Our model computes the next frame by first predicting the motions of image segments, then merges these predictions via masking. In this section, we discuss our novel pixel transformation models, and propose how to effectively merge predicted motion of multiple segments into a single next image prediction. The architecture of the CDNA model is shown in Figure 1. Diagrams of the DNA and STP models are in Appendix B. 3.1 Pixel Transformations for Future Video Prediction The core of our models is a motion prediction module that predicts objects’ motion without attempting to reconstruct their appearance. This module is therefore partially invariant to appearance and can generalize effectively to previously unseen objects. We propose three motion prediction modules: Dynamic Neural Advection (DNA): In this approach, we predict a distribution over locations in the previous frame for each pixel in the new frame. The predicted pixel value is computed as an expectation under this distribution. We constrain the pixel movement to a local region, under the regularizing assumption that pixels will not move large distances. This keeps the dimensionality of the prediction low. This approach is the most flexible of the proposed approaches. Formally, we apply the predicted motion transformation ˆm to the previous image prediction ˆIt−1 for every pixel (x, y) to form the next image prediction ˆIt as follows: ˆIt(x, y) = X k∈(−κ,κ) X l∈(−κ,κ) ˆmxy(k, l)ˆIt−1(x −k, y −l) where κ is the spatial extent of the predicted distribution. This can be implemented as a convolution with untied weights. The architecture of this model matches the CDNA model in Figure 1, except that 3 the higher-dimensional transformation parameters ˆm are outputted by the last (conv 2) layer instead of the LSTM 5 layer used for the CDNA model. Convolutional Dynamic Neural Advection (CDNA): Under the assumption that the same mechanisms can be used to predict the motions of different objects in different regions of the image, we consider a more object-centric approach to predicting motion. Instead of predicting a different distribution for each pixel, this model predicts multiple discrete distributions that are each applied to the entire image via a convolution (with tied weights), which computes the expected value of the motion distribution for every pixel. The idea is that pixels on the same rigid object will move together, and therefore can share the same transformation. More formally, one predicted object transformation ˆm applied to the previous image It−1 produces image ˆJt for each pixel (x, y) as follows: ˆJt(x, y) = X k∈(−κ,κ) X l∈(−κ,κ) ˆm(k, l)ˆIt−1(x −k, y −l) where κ is the spatial size of the normalized predicted convolution kernel ˆm. Multiple transformations { ˆm(i)} are applied to the previous image ˆIt−1 to form multiple images { ˆJ(i) t }. These output images are combined into a single prediction ˆIt as described in the next section and show in Figure 1. Spatial Transformer Predictors (STP): In this approach, the model produces multiple sets of parameters for 2D affine image transformations, and applies the transformations using a bilinear sampling kernel [11]. More formally, a set of affine parameters ˆ M produces a warping grid between previous image pixels (xt−1, yt−1) and generated image pixels (xt, yt). xt−1 yt−1 = ˆ M xt yt 1 ! This grid can be applied with a bilinear kernel to form an image ˆJt: ˆJt(xt, yt) = W X k H X l ˆIt−1(k, l) max(0, 1 −|xt−1 −k|) max(0, 1 −|yt−1 −l|) where W and H are the image width and height. While this type of operator has been applied previously only to supervised learning tasks, it is well-suited for video prediction. Multiple transformations { ˆ M (i)} are applied to the previous image ˆIt−1 to form multiple images { ˆJ(i) t }, which are then composited based on the masks. The architecture matches the diagram in Figure 1, but instead of outputting CDNA kernels at the LSTM 5 layer, the model outputs the STP parameters { ˆ M (i)}. All of these models can focus on learning physics rather than object appearance. Our experiments show that these models are better able to generalize to unseen objects compared to models that reconstruct the pixels directly or predict the difference from the previous frame. 3.2 Composing Object Motion Predictions CDNA and STP produce multiple object motion predictions, which need to be combined into a single image. The composition of the predicted images ˆJ(i) t is modulated by a mask Ξ, which defines a weight on each prediction, for each pixel. Thus, ˆIt = P c ˆJ(c) t ◦Ξc , where c denotes the channel of the mask and the element-wise multiplication is over pixels. To obtain the mask, we apply a channel-wise softmax to the final convolutional layer in the model (conv 2 in Figure 1), which ensures that the channels of the mask sum to 1 for each pixel position. In practice, our experiments show that the CDNA and STP models learn to mask out objects that are moving in consistent directions. The benefit of this approach is two-fold: first, predicted motion transformations are reused for multiple pixels in the image, and second, the model naturally extracts a more object centric representation in an unsupervised fashion, a desirable property for an agent learning to interact with objects. The DNA model lacks these two benefits, but instead is more flexible as it can produce independent motions for every pixel in the image. For each model, including DNA, we also include a “background mask” where we allow the models to copy pixels directly from the previous frame. Besides improving performance, this also produces interpretable background masks that we visualize in Section 5. Additionally, to fill in previously occluded regions, which may not be well represented by nearby pixels, we allowed the models to generate pixels from an image, and included it in the final masking step. 4 3.3 Action-conditioned Convolutional LSTMs Most existing physics and video prediction models use feedforward architectures [17, 15] or feedforward encodings of the image [20]. To generate the motion predictions discussed above, we employ stacked convolutional LSTMs [28]. Recurrence through convolutions is a natural fit for multi-step video prediction because it takes advantage of the spatial invariance of image representations, as the laws of physics are mostly consistent across space. As a result, models with convolutional recurrence require significantly fewer parameters and use those parameters more efficiently. The model architecture is displayed in Figure 1 and detailed in Appendix B. In an interactive setting, the agent’s actions and internal state (such as the pose of the robot gripper) influence the next image. We integrate both into our model by spatially tiling the concatenated state and action vector across a feature map, and concatenating the result to the channels of the lowest-dimensional activation map. Note, though, that the agent’s internal state (i.e. the robot gripper pose) is only input into the network at the beginning, and must be predicted from the actions in future timesteps. We trained the networks using an l2 reconstruction loss. Alternative losses, such as those presented in [17] could complement this method. 4 Robotic Pushing Dataset Figure 2: Robot data collection setup (top) and example images captured from the robot’s camera (bottom). One key application of action-conditioned video prediction is to use the learned model for decision making in visionbased robotic control tasks. Unsupervised learning from video can enable agents to learn about the world on their own, without human involvement, a critical requirement for scaling up interactive learning. In order to investigate action-conditioned video prediction for robotic tasks, we need a dataset with real-world physical object interactions. We collected a new dataset using 10 robotic arms, shown in Figure 2, pushing hundreds of objects in bins, amounting to 57,000 interaction sequences with 1.5 million video frames. Two test sets, each with 1,250 recorded motions, were also collected. The first test set used two different subsets of the objects pushed during training. The second test set involved two subsets of objects, none of which were used during training. In addition to RGB images, we also record the corresponding gripper poses, which we refer to as the internal state, and actions, which corresponded to the commanded gripper pose. The dataset is publically available2. Further details on the data collection procedure are provided in Appendix A. 5 Experiments We evaluate our method using the dataset in Section 4, as well as on videos of human motion in the Human3.6M dataset [10]. In both settings, we evaluate our three models described in Section 3, as well as prior models [17, 20]. For CDNA and STP, we used 10 transformers. While we show stills from the predicted videos in the figures, the qualitative results are easiest to compare when the predicted videos can be viewed side-by-side. For this reason, we encourage the reader to examine the video results on the supplemental website2. Code for training the model is also available on the website. Training details: We trained all models using the TensorFlow library [1], optimizing to convergence using ADAM [13] with the suggested hyperparameters. We trained all recurrent models with and without scheduled sampling [3] and report the performance of the model with the best validation error. We found that scheduled sampling improved performance of our models, but did not substantially affect the performance of ablation and baseline models that did not model pixel motion. 2See http://sites.google.com/site/robotprediction 5 GT CDNA FC LSTM FF, ms GT CDNA FC LSTM FF, ms t = 1 5 9 13 17 1 5 9 13 17 Figure 3: Qualitative and quantitative reconstruction performance of our models, compared with [20, 17]. All models were trained for 8-step prediction, except [17], trained for 1-step prediction. 5.1 Action-conditioned prediction for robotic pushing Our primary evaluation is on video prediction using our robotic interaction dataset, conditioned on the future actions taken by the robot. In this setting, we pass in two initial images, as well as the initial robot arm state and actions, and then sequentially roll out the model, passing in the future actions and the model’s image and state prediction from the previous time step. We trained for 8 future time steps for all recurrent models, and test for up to 18 time steps. We held out 5% of the training set for validation. To quantitatively evaluate the predictions, we measure average PSNR and SSIM, as proposed in [17]. Unlike [17], we measure these metrics on the entire image. We evaluate on two test sets described in Section 4, one with objects seen at training time, and one with previously unseen objects. Figure 3 illustrates the performance of our models compared to prior methods. We report the performance of the feedforward multiscale model of [17] using an l1+GDL loss, which was the best performing model in our experiments – full results of the multi-scale models are in Appendix C. Our methods significantly outperform prior video prediction methods on all metrics. The FC LSTM model [20] reconstructs the background and lacks the representational power to reconstruct the objects in the bin. The feedforward multiscale model performs well on 1-step prediction, but performance quickly drops over time, as it is only trained for 1-step prediction. It is worth noting that our models are significantly more parameter efficient: despite being recurrent, they contain 12.5 million parameters, which is slightly less than the feedforward model with 12.6 million parameters and significantly less than the FC LSTM model which has 78 million parameters. We found that none of the models suffered from significant overfitting on this dataset. We also report the baseline performance of simply copying the last observed ground truth frame. In Figure 4, we compare to models with the same stacked convolutional LSTM architecture, but that predict raw pixel values or the difference between previous and current frames. By explicitly modeling pixel motion, our method outperforms these ablations. Note that the model without skip connections is most representative of the model by Xingjian et al. [28]. We show a second ablation in Figure 5, illustrating the benefit of training for longer horizons and from conditioning on the action of the robot. Lastly, we show qualitative results in Figure 6 of changing the action of the arm to examine the model’s predictions about possible futures. For all of the models, the prediction quality degrades over time, as uncertainty increases further into the future. We use a mean-squared error objective, which optimizes for the mean pixel values. The 6 Figure 4: Quantitative comparison to models which reconstruct rather than predict motion. Notice that on the novel objects test set, there is a larger gap between models which predict motion and those which reconstruct appearance. Figure 5: Ablation of DNA involving not including the action, and different prediction horizons during training. model thus encodes uncertainty as blur. Modeling this uncertainty directly through, for example, stochastic neural networks is an interesting direction for future work. Note that prior video prediction methods have largely focused on single-frame prediction, and most have not demonstrated prediction of multiple real-world RGB video frames in sequence. Action-conditioned multi-frame prediction is a crucial ingredient in model-based planning, where the robot could mentally test the outcomes of various actions before picking the best one for a given task. 5.2 Human motion prediction In addition to the action-conditioned prediction, we also evaluate our model on predicting future video without actions. We chose the Human3.6M dataset, which consists of human actors performing various actions in a room. We trained all models on 5 of the human subjects, held out one subject for validation, and held out a different subject for the evaluations presented here. Thus, the models have never seen this particular human subject or any subject wearing the same clothes. We subsampled the video down to 10 fps such that there was noticeable motion in the videos within reasonable time frames. Since the model is no longer conditioned on actions, we fed in 10 video frames and trained the network to produce the next 10 frames, corresponding to 1 second each. Our evaluation measures performance up to 20 timesteps into the future. The results in Figure 7 show that our motion-predictive models quantitatively outperform prior methods, and qualitatively produce plausible motions for at least 10 timesteps, and start to degrade thereafter. We also show the masks predicted internally by the model for masking out the previous 0 action 1x action 1.5x action t = 1 3 5 7 9 1 3 5 7 9 Figure 6: CDNA predictions from the same starting image, but different future actions, with objects not seen in the training set. By row, the images show predicted future with zero action (stationary), the original action, and an action 150% larger than the original. Note how the prediction shows no motion with zero action, and with a larger action, predicts more motion, including object motion. 7 GT STP STP mask t = 1 4 7 10 13 1 4 7 10 13 Figure 7: Quantitative and qualitative results on human motion video predictions with a held-out human subject. All recurrent models were trained for 10 future timesteps. frame, which we refer to as the background mask. These masks illustrate that the model learns to segment the human subject in the image without any explicit supervision. 6 Conclusion & Future Directions In this work, we develop an action-conditioned video prediction model for interaction that incorporates appearance information in previous frames with motion predicted by the model. To study unsupervised learning for interaction, we also present a new video dataset with 59,000 real robot interactions and 1.5 million video frames. Our experiments show that, by learning to transform pixels in the initial frame, our model can produce plausible video sequences more than 10 time steps into the future, which corresponds to about one second. In comparisons to prior methods, our method achieves the best results on a number of previous proposed metrics. Predicting future object motion in the context of a physical interaction is a key building block of an intelligent interactive system. The kind of action-conditioned prediction of future video frames that we demonstrate can allow an interactive agent, such as a robot, to imagine different futures based on the available actions. Such a mechanism can be used to plan for actions to accomplish a particular goal, anticipate possible future problems (e.g. in the context of an autonomous vehicle), and recognize interesting new phenomena in the context of exploration. While our model directly predicts the motion of image pixels and naturally groups together pixels that belong to the same object and move together, it does not explicitly extract an internal object-centric representation (e.g. as in [7]). Learning such a representation would be a promising future direction, particularly for applying efficient reinforcement learning algorithms that might benefit from concise state representations. Acknowledgments We would like to thank Vincent Vanhoucke, Mrinal Kalakrishnan, Jon Barron, Deirdre Quillen, and our anonymous reviewers for helpful feedback and discussions. We would also like to thank Peter Pastor for technical support with the robots. References [1] M. Abadi, A. Agarwal, P. Barham, E. Brevdo, Z. Chen, C. Citro, G. S. Corrado, A. Davis, et al. Tensorflow: Large-scale machine learning on heterogeneous systems, 2015. Software from tensorflow.org, 2015. [2] P. W. Battaglia, J. B. Hamrick, and J. B. Tenenbaum. Simulation as an engine of physical scene understanding. Proceedings of the National Academy of Sciences, 110(45), 2013. 8 [3] S. Bengio, O. Vinyals, N. Jaitly, and N. Shazeer. Scheduled sampling for sequence prediction with recurrent neural networks. In Advances in Neural Information Processing Systems, pages 1171–1179, 2015. [4] B. Boots, A. Byravan, and D. Fox. Learning predictive models of a depth camera & manipulator from raw execution traces. In International Conference on Robotics and Automation (ICRA), 2014. [5] M. A. Brubaker, L. Sigal, and D. J. Fleet. Estimating contact dynamics. In International Conference on Computer Vision (ICCV), 2009. [6] B. De Brabandere, X. Jia, T. Tuytelaars, and L. Van Gool. Dynamic filter networks. In Neural Information Processing Systems (NIPS). 2016. [7] S. Eslami, N. Heess, T. Weber, Y. Tassa, K. Kavukcuoglu, and G. E. Hinton. Attend, infer, repeat: Fast scene understanding with generative models. Neural Information Processing Systems (NIPS), 2016. [8] A. Geiger, P. Lenz, C. Stiller, and R. Urtasun. Vision meets robotics: The KITTI dataset. International Journal of Robotics Research (IJRR), 2013. [9] D.-A. Huang and K. M. Kitani. Action-reaction: Forecasting the dynamics of human interaction. In European Conference on Computer Vision (ECCV). Springer, 2014. [10] C. Ionescu, D. Papava, V. Olaru, and C. Sminchisescu. Human3.6m: Large scale datasets and predictive methods for 3d human sensing in natural environments. PAMI, 36(7), 2014. [11] M. Jaderberg, K. Simonyan, A. Zisserman, et al. Spatial transformer networks. In Neural Information Processing Systems (NIPS), 2015. [12] A. Karpathy, G. Toderici, S. Shetty, T. Leung, R. Sukthankar, and L. Fei-Fei. Large-scale video classification with convolutional neural networks. In Compuer Vision and Pattern Recognition (CVPR), 2014. [13] D. Kinga and J. Ba. Adam: A method for stochastic optimization. International Conference on Learning Representations (ICLR), 2015. [14] S. Lange, M. Riedmiller, and A. Voigtlander. Autonomous reinforcement learning on raw visual input data in a real world application. In International Joint Conference on Neural Networks (IJCNN), 2012. [15] A. Lerer, S. Gross, and R. Fergus. Learning physical intuition of block towers by example. International Conference on Machine Learning (ICML), 2016. [16] W. Lotter, G. Kreiman, and D. Cox. Deep predictive coding networks for video prediction and unsupervised learning. arXiv preprint arXiv:1605.08104, 2016. [17] M. Mathieu, C. Couprie, and Y. LeCun. Deep multi-scale video prediction beyond mean square error. International Conference on Learning Representations (ICLR), 2016. [18] R. Mottaghi, H. Bagherinezhad, M. Rastegari, and A. Farhadi. Newtonian image understanding: Unfolding the dynamics of objects in static images. Computer Vision and Pattern Recognition (CVPR), 2015. [19] R. Mottaghi, M. Rastegari, A. Gupta, and A. Farhadi. "What happens if..." learning to predict the effect of forces in images. European Conference on Computer Vision (ECCV), 2016. [20] J. Oh, X. Guo, H. Lee, R. L. Lewis, and S. Singh. Action-conditional video prediction using deep networks in atari games. In Neural Information Processing Systems (NIPS), 2015. [21] M. Ranzato, A. Szlam, J. Bruna, M. Mathieu, R. Collobert, and S. Chopra. Video (language) modeling: a baseline for generative models of natural videos. arXiv preprint arXiv:1412.6604, 2014. [22] N. Srivastava, E. Mansimov, and R. Salakhutdinov. Unsupervised learning of video representations using lstms. International Conference on Machine Learning (ICML), 2015. [23] C. Vondrick, H. Pirsiavash, and A. Torralba. Anticipating the future by watching unlabeled video. CoRR, abs/1504.08023, 2015. [24] C. Vondrick, H. Pirsiavash, and A. Torralba. Generating videos with scene dynamics. In Neural Information Processing Systems (NIPS). 2016. [25] J. Walker, C. Doersch, A. Gupta, and M. Hebert. An uncertain future: Forecasting from static images using variational autoencoders. In European Conference on Computer Vision (ECCV), 2016. [26] J. Walker, A. Gupta, and M. Hebert. Patch to the future: Unsupervised visual prediction. In Computer Vision and Pattern Recognition (CVPR), 2014. [27] M. Watter, J. Springenberg, J. Boedecker, and M. Riedmiller. Embed to control: A locally linear latent dynamics model for control from raw images. In Neural Information Processing Systems (NIPS), 2015. [28] S. Xingjian, Z. Chen, H. Wang, D. Yeung, W. Wong, and W. Woo. Convolutional LSTM network: A machine learning approach for precipitation nowcasting. In Neural Information Processing Systems, 2015. [29] T. Xue, J. Wu, K. L. Bouman, and W. T. Freeman. Visual dynamics: Probabilistic future frame synthesis via cross convolutional networks. In Neural Information Processing Systems (NIPS). 2016. [30] J. Yuen and A. Torralba. A data-driven approach for event prediction. In European Conference on Computer Vision (ECCV), 2010. 9 | 2016 | 490 |
6,428 | Full-Capacity Unitary Recurrent Neural Networks Scott Wisdom1∗, Thomas Powers1∗, John R. Hershey2, Jonathan Le Roux2, and Les Atlas1 1 Department of Electrical Engineering, University of Washington {swisdom, tcpowers, atlas}@uw.edu 2 Mitsubishi Electric Research Laboratories (MERL) {hershey, leroux}@merl.com Abstract Recurrent neural networks are powerful models for processing sequential data, but they are generally plagued by vanishing and exploding gradient problems. Unitary recurrent neural networks (uRNNs), which use unitary recurrence matrices, have recently been proposed as a means to avoid these issues. However, in previous experiments, the recurrence matrices were restricted to be a product of parameterized unitary matrices, and an open question remains: when does such a parameterization fail to represent all unitary matrices, and how does this restricted representational capacity limit what can be learned? To address this question, we propose full-capacity uRNNs that optimize their recurrence matrix over all unitary matrices, leading to significantly improved performance over uRNNs that use a restricted-capacity recurrence matrix. Our contribution consists of two main components. First, we provide a theoretical argument to determine if a unitary parameterization has restricted capacity. Using this argument, we show that a recently proposed unitary parameterization has restricted capacity for hidden state dimension greater than 7. Second, we show how a complete, full-capacity unitary recurrence matrix can be optimized over the differentiable manifold of unitary matrices. The resulting multiplicative gradient step is very simple and does not require gradient clipping or learning rate adaptation. We confirm the utility of our claims by empirically evaluating our new full-capacity uRNNs on both synthetic and natural data, achieving superior performance compared to both LSTMs and the original restricted-capacity uRNNs. 1 Introduction Deep feed-forward and recurrent neural networks have been shown to be remarkably effective in a wide variety of problems. A primary difficulty in training using gradient-based methods has been the so-called vanishing or exploding gradient problem, in which the instability of the gradients over multiple layers can impede learning [1, 2]. This problem is particularly keen for recurrent networks, since the repeated use of the recurrent weight matrix can magnify any instability. This problem has been addressed in the past by various means, including gradient clipping [3], using orthogonal matrices for initialization of the recurrence matrix [4, 5], or by using pioneering architectures such as long short-term memory (LSTM) recurrent networks [6] or gated recurrent units [7]. Recently, several innovative architectures have been introduced to improve information flow in a network: residual networks, which directly pass information from previous layers up in a feed-forward network [8], and attention networks, which allow a recurrent network to access past activations [9]. The idea of using a unitary recurrent weight matrix was introduced so that the gradients are inherently stable and do not vanish or explode [10]. The resulting unitary recurrent ∗Equal contribution 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. neural network (uRNN) is complex-valued and uses a complex form of the rectified linear activation function. However, this idea was investigated using, as we show, a potentially restricted form of unitary matrices. The two main components of our contribution can be summarized as follows: 1) We provide a theoretical argument to determine the smallest dimension N for which any parameterization of the unitary recurrence matrix does not cover the entire set of all unitary matrices. The argument relies on counting real-valued parameters and using Sard’s theorem to show that the smooth map from these parameters to the unitary manifold is not onto. Thus, we can show that a previously proposed parameterization [10] cannot represent all unitary matrices larger than 7 × 7. Thus, such a parameterization results in what we refer to as a restricted-capacity unitary recurrence matrix. 2) To overcome the limitations of restricted-capacity parameterizations, we propose a new method for stochastic gradient descent for training the unitary recurrence matrix, which constrains the gradient to lie on the differentiable manifold of unitary matrices. This approach allows us to directly optimize a complete, or full-capacity, unitary matrix. Neither restricted-capacity nor full-capacity unitary matrix optimization require gradient clipping. Furthermore, full-capacity optimization still achieves good results without adaptation of the learning rate during training. To test the limitations of a restricted-capacity representation and to confirm that our full-capacity uRNN does have practical implications, we test restricted-capacity and full-capacity uRNNs on both synthetic and natural data tasks. These tasks include synthetic system identification, long-term memorization, frame-to-frame prediction of speech spectra, and pixel-by-pixel classification of handwritten digits. Our proposed full-capacity uRNNs generally achieve equivalent or superior performance on synthetic and natural data compared to both LSTMs [6] and the original restrictedcapacity uRNNs [10]. In the next section, we give an overview of unitary recurrent neural networks. Section 3 presents our first contribution: the theoretical argument to determine if any unitary parameterization has restricted-capacity. Section 4 describes our second contribution, where we show how to optimize a full-capacity unitary matrix. We confirm our results with simulated and natural data in Section 5 and present our conclusions in Section 6. 2 Unitary recurrent neural networks The uRNN proposed by Arjovsky et al. [10] consists of the following nonlinear dynamical system that has real- or complex-valued inputs xt of dimension M, complex-valued hidden states ht of dimension N, and real- or complex-valued outputs yt of dimension L: ht =σb (Wht−1 + Vxt) yt =Uht + c, (1) where yt = Re{Uht + c} if the outputs yt are real-valued. The element-wise nonlinearity σ is [σb(z)]i = ( (|zi| + bi) zi |zi|, if |zi| + bi > 0, 0, otherwise. (2) Note that this non-linearity consists in a soft-thresholding of the magnitude using the bias vector b. Hard-thresholding would set the output of σ to zi if |zi| + bi > 0. The parameters of the uRNN are as follows: W ∈U(N), unitary hidden state transition matrix; V ∈CN×M, input-to-hidden transformation; b ∈RN, nonlinearity bias; U ∈CL×N, hidden-to-output transformation; and c ∈CL, output bias. Arjovsky et al. [10] propose the following parameterization of the unitary matrix W: Wu(θu) = D3R2F−1D2PR1FD1, (3) where D are diagonal unitary matrices, R are Householder reflection matrices [11], F is a discrete Fourier transform (DFT) matrix, and P is a permutation matrix. The resulting matrix Wu is unitary because all its component matrices are unitary. This decomposition is efficient because diagonal, reflection, and permutation matrices are O(N) to compute, and DFTs can be computed efficiently in O(N log N) time using the fast Fourier transform (FFT). The parameter vector θu consists of 7N 2 real-valued parameters: N parameters for each of the 3 diagonal matrices where Di,i = ejθi and 2N parameters for each of the 2 Householder reflection matrices, which are real and imaginary values of the complex reflection vectors ui: Ri = I −2 uiuH i ⟨ui,ui⟩. 3 Estimating the representation capacity of structured unitary matrices In this section, we state and prove a theorem that can be used to determine when any particular unitary parameterization does not have capacity to represent all unitary matrices. As an application of this theorem, we show that the parameterization (3) does not have the capacity to cover all N × N unitary matrices for N > 7. First, we establish an upper bound on the number of real-valued parameters required to represent any N × N unitary matrix. Then, we state and prove our theorem. Lemma 3.1 The set of all unitary matrices is a manifold of dimension N 2. Proof: The set of all unitary matrices is the well-known unitary Lie group U(N) [12, §3.4]. A Lie group identifies group elements with points on a differentiable manifold [12, §2.2]. The dimension of the manifold is equal to the dimension of the Lie algebra u, which is a vector space that is the tangent space at the identity element [12, §4.5]. For U(N), the Lie algebra consists of all skewHermitian matrices A [12, §5.4]. A skew-Hermitian matrix is any A ∈CN×N such that A = −AH, where (·)H is the conjugate transpose. To determine the dimension of U(N), we can determine the dimension of u. Because of the skew-Hermitian constraint, the diagonal elements of A are purely imaginary, which corresponds to N real-valued parameters. Also, since Ai,j = −A∗ j,i, the upper and lower triangular parts of A are parameterized by N(N−1) 2 complex numbers, which corresponds to an additional N 2 −N real parameters. Thus, U(N) is a manifold of dimension N 2. Theorem 3.2 If a family of N × N unitary matrices is parameterized by P real-valued parameters for P < N 2, then it cannot contain all N × N unitary matrices. Proof: We consider a family of unitary matrices that is parameterized by P real-valued parameters through a smooth map g : P(P) →U(N 2) from the space of parameters P(P) to the space of all unitary matrices U(N 2). The space P(P) of parameters is considered as a P-dimensional manifold, while the space U(N 2) of all unitary matrices is an N 2-dimensional manifold according to lemma 3.1. Then, if P < N 2, Sard’s theorem [13] implies that the image g(P) of g is of measure zero in U(N 2), and in particular g is not onto. Since g is not onto, there must exist a unitary matrix W ∈U(N 2) for which there is no corresponding input P ∈P(P) such that W = g(P). Thus, if P is such that P < N 2, the manifold P(P) cannot represent all unitary matrices in U(N 2). We now apply Theorem 3.2 to the parameterization (3). Note that the parameterization (3) has P = 7N real-valued parameters. If we solve for N in 7N < N 2, we get N > 7. Thus, the parameterization (3) cannot represent all unitary matrices for dimension N > 7. 4 Optimizing full-capacity unitary matrices on the Stiefel manifold In this section, we show how to get around the limitations of restricted-capacity parameterizations and directly optimize a full-capacity unitary matrix. We consider the Stiefel manifold of all N × N complex-valued matrices whose columns are N orthonormal vectors in CN [14]. Mathematically, the Stiefel manifold is defined as VN(CN) = W ∈CN×N : WHW = IN×N . (4) For any W ∈VN(CN), any matrix Z in the tangent space TWVN(CN) of the Stiefel manifold satisfies ZHW −WHZ = 0 [14]. The Stiefel manifold becomes a Riemannian manifold when its tangent space is equipped with an inner product. Tagare [14] suggests using the canonical inner product, given by ⟨Z1, Z2⟩c = tr ZH 1 (I −1 2WWH)Z2 . (5) Under this canonical inner product on the tangent space, the gradient in the Stiefel manifold of the loss function f with respect to the matrix W is AW, where A = GHW −WHG is a skew-Hermitian 3 matrix and G with Gi,j = δf δWi,j is the usual gradient of the loss function f with respect to the matrix W [14]. Using these facts, Tagare [14] suggests a descent curve along the Stiefel manifold at training iteration k given by the matrix product of the Cayley transformation of A(k) with the current solution W(k): Y(k)(λ) = I + λ 2 A(k) −1 I −λ 2 A(k) W(k), (6) where λ is a learning rate and A(k) = G(k)HW(k) −W(k)HG(k). Gradient descent proceeds by performing updates W(k+1) = Y(k)(λ). Tagare [14] suggests an Armijo-Wolfe search along the curve to adapt λ, but such a procedure would be expensive for neural network optimization since it requires multiple evaluations of the forward model and gradients. We found that simply using a fixed learning rate λ often works well. Also, RMSprop-style scaling of the gradient G(k) by a running average of the previous gradients’ norms [15] before applying the multiplicative step (6) can improve convergence. The only additional substantial computation required beyond the forward and backward passes of the network is the N × N matrix inverse in (6). 5 Experiments All models are implemented in Theano [16], based on the implementation of restricted-capacity uRNNs by [10], available from https://github.com/amarshah/complex_RNN. All code to replicate our results is available from https://github.com/stwisdom/urnn. All models use RMSprop [15] for optimization, except that full-capacity uRNNs optimize their recurrence matrices with a fixed learning rate using the update step (6) and optional RMSprop-style gradient normalization. 5.1 Synthetic data First, we compare the performance of full-capacity uRNNs to restricted-capacity uRNNs and LSTMs on two tasks with synthetic data. The first task is synthetic system identification, where a uRNN must learn the dynamics of a target uRNN given only samples of the target uRNN’s inputs and outputs. The second task is the copy memory problem, in which the network must recall a sequence of data after a long period of time. 5.1.1 System identification For the task of system identification, we consider the problem of learning the dynamics of a nonlinear dynamical system that has the form (1), given a dataset of inputs and outputs of the system. We will draw a true system Wsys randomly from either a constrained set Wu of restricted-capacity unitary matrices using the parameterization Wu(θu) in (3) or from a wider set Wg of restricted-capacity unitary matrices that are guaranteed to lie outside Wu. We sample from Wg by taking a matrix product of two unitary matrices drawn from Wu. We use a sequence length of T = 150, and we set the input dimension M and output dimension L both equal to the hidden state dimension N. The input-to-hidden transformation V and output-tohidden transformation U are both set to identity, the output bias c is set to 0, the initial state is set to 0, and the hidden bias b is drawn from a uniform distribution in the range [−0.11, −0.09]. The hidden bias has a mean of −0.1 to ensure stability of the system outputs. Inputs are generated by sampling T-length i.i.d. sequences of zero-mean, diagonal and unit covariance circular complexvalued Gaussians of dimension N. The outputs are created by running the system (1) forward on the inputs. We compare a restricted-capacity uRNN using the parameterization from (3) and a full-capacity uRNN using Stiefel manifold optimization with no gradient normalization as described in Section 4. We choose hidden state dimensions N to test critical points predicted by our arguments in Section 3 of Wu(θu) in (3): N ∈{4, 6, 7, 8, 16}. These dimensions are chosen to test below, at, and above the critical dimension of 7. For all experiments, the number of training, validation, and test sequences are 20000, 1000, and 1000, respectively. Mean-squared error (MSE) is used as the loss function. The learning rate is 0.001 with a batch size of 50 for all experiments. Both models use the same matrix drawn from Wu as initialization. To isolate the effect of unitary recurrence matrix capacity, we only optimize W, setting 4 all other parameters to true oracle values. For each method, we report the best test loss over 100 epochs and over 6 random initializations for the optimization. The results are shown in Table 1. “Wsys init.” refers to the initialization of the true system unitary matrix Wsys, which is sampled from either the restricted-capacity set Wu or the wider set Wg. Table 1: Results for system identification in terms of best normalized MSE. Wu is the set of restricted-capacity unitary matrices from (3), and Wg is a wider set of unitary matrices. Wsys init. Capacity N = 4 N = 6 N = 7 N = 8 N = 16 Wu Restricted 4.81e−1 6.75e−3 3.53e−1 3.51e−1 7.30e−1 Wu Full 1.28e−1 3.03e−1 2.16e−1 5.04e−2 1.28e−1 Wg Restricted 3.21e−4 3.36e−1 3.36e−1 2.69e−1 7.60e−1 Wg Full 8.72e−2 3.86e−1 2.62e−1 7.22e−2 1.00e−6 Notice that for N < 7, the restricted-capacity uRNN achieves comparable or better performance than the full-capacity uRNN. At N = 7, the restricted-capacity and full-capacity uRNNs achieve relatively comparable performance, with the full-capacity uRNN achieving slightly lower error. For N > 7, the full-capacity uRNN always achieves better performance versus the restricted-capacity uRNN. This result confirms our theoretical arguments that the restricted-capacity parameterization in (3) lacks the capacity to model all matrices in the unitary group for N > 7 and indicates the advantage of using a full-capacity unitary recurrence matrix. 5.1.2 Copy memory problem The experimental setup follows the copy memory problem from [10], which itself was based on the experiment from [6]. We consider alternative hidden state dimensions and extend the sequence lengths to T = 1000 and T = 2000, which are longer than the maximum length of T = 750 considered in previous literature. In this task, the data is a vector of length T + 20 and consists of elements from 10 categories. The vector begins with a sequence of 10 symbols sampled uniformly from categories 1 to 8. The next T −1 elements of the vector are the ninth ’blank’ category, followed by an element from the tenth category, the ‘delimiter’. The remaining ten elements are ‘blank’. The task is to output T + 10 blank characters followed by the sequence from the beginning of the vector. We use average cross entropy as the training loss function. The baseline solution outputs the blank category for T + 10 time steps and then guesses a random symbol uniformly from the first eight categories. This baseline has an expected average cross entropy of 10 log(8) T +20 . Figure 1: Results of the copy memory problem with sequence lengths of 1000 (left) and 2000 (right). The full-capacity uRNN converges quickly to a perfect solution, while the LSTM and restrictedcapacity uRNN with approximately the same number of parameters are unable to improve past the baseline naive solution. The full-capacity uRNN uses a hidden state size of N = 128 with no gradient normalization. To match the number of parameters (≈22k), we use N = 470 for the restricted-capacity uRNN, and N = 68 for the LSTM. The training set size is 100000 and the test set size is 10000. The results 5 of the T = 1000 experiment can be found on the left half of Figure 1. The full-capacity uRNN converges to a solution with zero average cross entropy after about 2000 training iterations, whereas the restricted-capacity uRNN settles to the baseline solution of 0.020. The results of the T = 2000 experiment can be found on the right half of Figure 1. The full-capacity uRNN hovers around the baseline solution for about 5000 training iterations, after which it drops down to zero average cross entropy. The restricted-capacity again settles down to the baseline solution of 0.010. These results demonstrate that the full-capacity uRNN is very effective for problems requiring very long memory. 5.2 Speech data We now apply restricted-capacity and full-capacity uRNNs to real-world speech data and compare their performance to LSTMs. The main task we consider is predicting the log-magnitude of future frames of a short-time Fourier transform (STFT). The STFT is a commonly used feature domain for speech enhancement, and is defined as the Fourier transform of short windowed frames of the time series. In the STFT domain, a real-valued audio signal is represented as a complex-valued F × T matrix composed of T frames that are each composed of F = Nwin/2 + 1 frequency bins, where Nwin is the duration of the time-domain frame. Most speech processing algorithms use the log-magnitude of the complex STFT values and reconstruct the processed audio signal using the phase of the original observations. The frame prediction task is as follows: given all the log-magnitudes of STFT frames up to time t, predict the log-magnitude of the STFT frame at time t + 1.We use the TIMIT dataset [17]. According to common practice [18], we use a training set with 3690 utterances from 462 speakers, a validation set of 400 utterances, an evaluation set of 192 utterances. Training, validation, and evaluation sets have distinct speakers. Results are reported on the evaluation set using the network parameters that perform best on the validation set in terms of the loss function over three training trials. All TIMIT audio is resampled to 8kHz. The STFT uses a Hann analysis window of 256 samples (32 milliseconds) and a window hop of 128 samples (16 milliseconds). The LSTM requires gradient clipping during optimization, while the restricted-capacity and fullcapacity uRNNs do not. The hidden state dimensions N of the LSTM are chosen to match the number of parameters of the full-capacity uRNN. For the restricted-capacity uRNN, we run models that match either N or number of parameters. For the LSTM and restricted-capacity uRNNs, we use RMSprop [15] with a learning rate of 0.001, momentum 0.9, and averaging parameter 0.1. For the full-capacity uRNN, we also use RMSprop to optimize all network parameters, except for the recurrence matrix, for which we use stochastic gradient descent along the Stiefel manifold using the update (6) with a fixed learning rate of 0.001 and no gradient normalization. Table 2: Log-magnitude STFT prediction results on speech data, evaluated using objective and perceptual metrics (see text for description). Model N # parameters Valid. MSE Eval. MSE SegSNR (dB) STOI PESQ LSTM 84 ≈83k 18.02 18.32 1.95 0.77 1.99 Restricted-capacity uRNN 128 ≈67k 15.03 15.78 3.30 0.83 2.36 Restricted-capacity uRNN 158 ≈83k 15.06 14.87 3.32 0.83 2.33 Full-capacity uRNN 128 ≈83k 14.78 15.24 3.57 0.84 2.40 LSTM 120 ≈135k 16.59 16.98 2.32 0.79 2.14 Restricted-capacity uRNN 192 ≈101k 15.20 15.17 3.31 0.83 2.35 Restricted-capacity uRNN 256 ≈135k 15.27 15.63 3.31 0.83 2.36 Full-capacity uRNN 192 ≈135k 14.56 14.66 3.76 0.84 2.42 LSTM 158 ≈200k 15.49 15.80 2.92 0.81 2.24 Restricted-capacity uRNN 378 ≈200k 15.78 16.14 3.16 0.83 2.35 Full-capacity uRNN 256 ≈200k 14.41 14.45 3.75 0.84 2.38 Results are shown in Table 2, and Figure 2 shows example predictions of the three types of networks. Results in Table 2 are given in terms of the mean-squared error (MSE) loss function and several metrics computed on the time-domain signals, which are reconstructed from the predicted log-magnitude 6 Figure 2: Ground truth and one-frame-ahead predictions of a spectrogram for an example utterance. For each model, hidden state dimension N is chosen for the best validation MSE. Notice that the full-capacity uRNN achieves the best detail in its predictions. and the original phase of the STFT. These time-domain metrics are segmental signal-to-noise ratio (SegSNR), short-time objective intelligibility (STOI), and perceptual evaluation of speech quality (PESQ). SegSNR, computed using [19], uses a voice activity detector to avoid measuring SNR in silent frames. STOI is designed to correlate well with human intelligibility of speech, and takes on values between 0 and 1, with a higher score indicating higher intelligibility [20]. PESQ is the ITU-T standard for telephone voice quality testing [21, 22], and is a popular perceptual quality metric for speech enhancement [23]. PESQ ranges from 1 (bad quality) to 4.5 (no distortion). Note that full-capacity uRNNs generally perform better than restricted-capacity uRNNs with the same number of parameters, and both types of uRNN significantly outperform LSTMs. 5.3 Pixel-by-pixel MNIST As another challenging long-term memory task with natural data, we test the performance of LSTMs and uRNNs on pixel-by-pixel MNIST and permuted pixel-by-pixel MNIST, first proposed by [5] and used by [10] to test restricted-capacity uRNNs. For permuted pixel-by-pixel MNIST, the pixels are shuffled, thereby creating some non-local dependencies between pixels in an image. Since the MNIST images are 28 × 28 pixels, resulting pixel-by-pixel sequences are T = 784 elements long. We use 5000 of the 60000 training examples as a validation set to perform early stopping with a patience of 5. The loss function is cross-entropy. Weights with the best validation loss are used to process the evaluation set. The full-capacity uRNN uses RMSprop-style gradient normalization. Table 3: Results for unpermuted and permuted pixel-by-pixel MNIST. Classification accuracies are reported for trained model weights that achieve the best validation loss. Model N # parameters Validation accurary Evaluation accuracy Unpermuted LSTM 128 ≈68k 98.1 97.8 LSTM 256 ≈270k 98.5 98.2 Restricted-capacity uRNN 512 ≈16k 97.9 97.5 Full-capacity uRNN 116 ≈16k 92.7 92.8 Full-capacity uRNN 512 ≈270k 97.5 96.9 Permuted LSTM 128 ≈68k 91.7 91.3 LSTM 256 ≈270k 92.1 91.7 Restricted-capacity uRNN 512 ≈16k 94.2 93.3 Full-capacity uRNN 116 ≈16k 92.2 92.1 Full-capacity uRNN 512 ≈270k 94.7 94.1 7 Figure 3: Learning curves for unpermuted pixel-by-pixel MNIST (top panel) and permuted pixel-bypixel MNIST (bottom panel). Learning curves are shown in Figure 3, and a summary of classification accuracies is shown in Table 3. For the unpermuted task, the LSTM with N = 256 achieves the best evaluation accuracy of 98.2%. For the permuted task, the full-capacity uRNN with N = 512 achieves the best evaluation accuracy of 94.1%, which is state-of-the-art on this task. Both uRNNs outperform LSTMs on the permuted case, achieving their best performance after fewer traing epochs and using an equal or lesser number of trainable parameters. This performance difference suggests that LSTMs are only able to model local dependencies, while uRNNs have superior long-term memory capabilities. Despite not representing all unitary matrices, the restricted-capacity uRNN with N = 512 still achieves impressive test accuracy of 93.3% with only 1/16 of the trainable parameters, outperforming the full-capacity uRNN with N = 116 that matches number of parameters. This result suggests that further exploration into the potential trade-off between hidden state dimension N and capacity of unitary parameterizations is necessary. 6 Conclusion Unitary recurrent matrices prove to be an effective means of addressing the vanishing and exploding gradient problems. We provided a theoretical argument to quantify the capacity of constrained unitary matrices. We also described a method for directly optimizing a full-capacity unitary matrix by constraining the gradient to lie in the differentiable manifold of unitary matrices. The effect of restricting the capacity of the unitary weight matrix was tested on system identification and memory tasks, in which full-capacity unitary recurrent neural networks (uRNNs) outperformed restrictedcapacity uRNNs from [10] as well as LSTMs. Full-capacity uRNNs also outperformed restrictedcapacity uRNNs on log-magnitude STFT prediction of natural speech signals and classification of permuted pixel-by-pixel images of handwritten digits, and both types of uRNN significantly outperformed LSTMs. In future work, we plan to explore more general forms of restricted-capacity unitary matrices, including constructions based on products of elementary unitary matrices such as Householder operators or Givens operators. Acknowledgments: We thank an anonymous reviewer for suggesting improvements to our proof in Section 3 and Vamsi Potluru for helpful discussions. Scott Wisdom and Thomas Powers were funded by U.S. ONR contract number N00014-12-G-0078, delivery orders 13 and 24. Les Atlas was funded by U.S. ARO grant W911NF-15-1-0450. 8 References [1] Y. Bengio, P. Simard, and P. Frasconi. Learning long-term dependencies with gradient descent is difficult. IEEE Transactions on Neural Networks, 5(2):157–166, 1994. [2] S. Hochreiter, Y. Bengio, P. Frasconi, and J. Schmidhuber. Gradient flow in recurrent nets: the difficulty of learning long-term dependencies. In S. C. Kremer and J. F. Kolen, eds, A field guide to dynamical recurrent neural networks. IEEE Press, 2001. [3] R. Pascanu, T. Mikolov, and Y. Bengio. On the difficulty of training Recurrent Neural Networks. arXiv:1211.5063, Nov. 2012. [4] A. M. Saxe, J. L. McClelland, and S. Ganguli. Exact solutions to the nonlinear dynamics of learning in deep linear neural networks. arXiv:1312.6120, Dec. 2013. [5] Q. V. Le, N. Jaitly, and G. E. Hinton. A simple way to initialize recurrent networks of rectified linear units. arXiv:1504.00941, Apr. 2015. [6] S. Hochreiter and J. Schmidhuber. Long short-term memory. Neural computation, 9(8):1735–1780, 1997. [7] K. Cho, B. van Merriënboer, D. Bahdanau, and Y. Bengio. On the properties of neural machine translation: Encoder-decoder approaches. arXiv:1409.1259, 2014. [8] K. He, X. Zhang, S. Ren, and J. Sun. Deep residual learning for image recognition. arXiv:1512.03385, Dec. 2015. [9] V. Mnih, N. Heess, A. Graves, and K. Kavukcuoglu. Recurrent models of visual attention. In Advances in Neural Information Processing Systems (NIPS), pp. 2204–2212, 2014. [10] M. Arjovsky, A. Shah, and Y. Bengio. Unitary Evolution Recurrent Neural Networks. In International Conference on Machine Learning (ICML), Jun. 2016. [11] A. S. Householder. Unitary triangularization of a nonsymmetric matrix. Journal of the ACM, 5(4):339–342, 1958. [12] R. Gilmore. Lie groups, physics, and geometry: an introduction for physicists, engineers and chemists. Cambridge University Press, 2008. [13] A. Sard. The measure of the critical values of differentiable maps. Bulletin of the American Mathematical Society, 48(12):883–890, 1942. [14] H. D. Tagare. Notes on optimization on Stiefel manifolds. Technical report, Yale University, 2011. [15] T. Tieleman and G. Hinton. Lecture 6.5—RmsProp: Divide the gradient by a running average of its recent magnitude, 2012. COURSERA: Neural Networks for Machine Learning. [16] Theano Development Team. Theano: A Python framework for fast computation of mathematical expressions. arXiv: 1605.02688, May 2016. [17] J. S. Garofolo, L. F. Lamel, W. M. Fisher, J. G. Fiscus, and D. S. Pallett. DARPA TIMIT acoustic-phonetic continous speech corpus. Technical Report NISTIR 4930, National Institute of Standards and Technology, 1993. [18] A. K. Halberstadt. Heterogeneous acoustic measurements and multiple classifiers for speech recognition. PhD thesis, Massachusetts Institute of Technology, 1998. [19] M. Brookes. VOICEBOX: Speech processing toolbox for MATLAB, 2002. [Online]. Available: http://www.ee.ic.ac.uk/hp/staff/dmb/voicebox/voicebox.html. [20] C. Taal, R. Hendriks, R. Heusdens, and J. Jensen. An algorithm for intelligibility prediction of timefrequency weighted noisy speech. IEEE Trans. on Audio, Speech, and Language Processing, 19(7):2125– 2136, Sep. 2011. [21] A. Rix, J. Beerends, M. Hollier, and A. Hekstra. Perceptual evaluation of speech quality (PESQ)-a new method for speech quality assessment of telephone networks and codecs. In Proc. ICASSP, vol. 2, pp. 749–752, 2001. [22] ITU-T P.862. Perceptual evaluation of speech quality (PESQ): An objective method for end-to-end speech quality assessment of narrow-band telephone networks and speech codecs, 2000. [23] P. C. Loizou. Speech Enhancement: Theory and Practice. CRC Press, Boca Raton, FL, Jun. 2007. 9 | 2016 | 491 |
6,429 | Linear-Memory and Decomposition-Invariant Linearly Convergent Conditional Gradient Algorithm for Structured Polytopes Dan Garber Toyota Technological Institute at Chicago dgarber@ttic.edu Ofer Meshi Google meshi@google.com Abstract Recently, several works have shown that natural modifications of the classical conditional gradient method (aka Frank-Wolfe algorithm) for constrained convex optimization, provably converge with a linear rate when: i) the feasible set is a polytope, and ii) the objective is smooth and strongly-convex. However, all of these results suffer from two significant shortcomings: 1. large memory requirement due to the need to store an explicit convex decomposition of the current iterate, and as a consequence, large running-time overhead per iteration 2. the worst case convergence rate depends unfavorably on the dimension In this work we present a new conditional gradient variant and a corresponding analysis that improves on both of the above shortcomings. In particular: 1. both memory and computation overheads are only linear in the dimension 2. in case the optimal solution is sparse, the new convergence rate replaces a factor which is at least linear in the dimension in previous work, with a linear dependence on the number of non-zeros in the optimal solution At the heart of our method and corresponding analysis, is a novel way to compute decomposition-invariant away-steps. While our theoretical guarantees do not apply to any polytope, they apply to several important structured polytopes that capture central concepts such as paths in graphs, perfect matchings in bipartite graphs, marginal distributions that arise in structured prediction tasks, and more. Our theoretical findings are complemented by empirical evidence which shows that our method delivers state-of-the-art performance. 1 Introduction The efficient reduction of a constrained convex optimization problem to a constrained linear optimization problem is an appealing algorithmic concept, in particular for large-scale problems. The reason is that for many feasible sets of interest, the problem of minimizing a linear function over the set admits much more efficient methods than its non-linear convex counterpart. Prime examples for this phenomenon include various structured polytopes that arise in combinatorial optimization, such as the path polytope of a graph (aka the unit flow polytope), the perfect matching polytope of a bipartite graph, and the base polyhedron of a matroid, for which we have highly efficient combinatorial algorithms for linear minimization that rely heavily on the specific rich structure of the polytope [21]. At the same time, minimizing a non-linear convex function over these sets usually requires the use of generic interior point solvers that are oblivious to the specific combinatorial structure of the underlying set, and as a result, are often much less efficient. Indeed, it is for this reason, that the 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. conditional gradient (CG) method (aka Frank-Wolfe algorithm), a method for constrained convex optimization that is based on solving linear subproblems over the feasible domain, has regained much interest in recent years in the machine learning, signal processing and optimization communities. It has been recently shown that the method delivers state-of-the-art performance on many problems of interest, see for instance [14, 17, 4, 10, 11, 22, 19, 25, 12, 15]. As part of the regained interest in the conditional gradient method, there is also a recent effort to understand the convergence rates and associated complexities of conditional gradient-based methods, which are in general far less understood than other first-order methods, e.g., the projected gradient method. It is known, already from the first introduction of the method by Frank and Wolfe in the 1950’s [5] that the method converges with a rate of roughly O(1/t) for minimizing a smooth convex function over a convex and compact set. However, it is not clear if this convergence rate improves under an additional standard strong-convexity assumption. In fact, certain lower bounds, such as in [18, 8], suggest that such improvement, even if possible, should come with a worse dependence on the problem’s parameters (e.g., the dimension). Nevertheless, over the past years, various works tried to design natural variants of the CG method that converge provably faster under the strong convexity assumption, without dramatically increasing the per-iteration complexity of the method. For instance, GuéLat and Marcotte [9] showed that a CG variant which uses the concept of away-steps converges exponentially fast in case the objective function is strongly convex, the feasible set is a polytope, and the optimal solution is located in the interior of the set. A similar result was presented by Beck and Teboulle [3] who considered a specific problem they refer to as the convex feasibility problem over an arbitrary convex set. They also obtained a linear convergence rate under the assumption that an optimal solution that is far enough from the boundary of the set exists. In both of these works, the exponent depends on the distance of the optimal solution from the boundary of the set, which in general can be arbitrarily small. Later, Ahipasaoglu et al. [1] showed that in the specific case of minimizing a smooth and strongly convex function over the unit simplex, a variant of the CG method which also uses away-steps, converges with a linear rate. Unfortunately, it is not clear from their analysis how this rate depends on natural parameters of the problem such as the dimension and the condition number of the objective function. Recently, Garber and Hazan presented a linearly-converging CG variant for polytopes without any restrictions on the location of the optimum [8]. In a later work, Lacoste-Julien and Jaggi [16] gave a refined affine-invariant analysis of an algorithm presented in [9] which also uses away steps, and showed that it also converges exponentially fast in the same setting as the Garber-Hazan result. More recently, Beck and Shtern [2] gave a different, duality-based, analysis for the algorithm of [9], and showed that it can be applied to a wider class of functions than purely strongly convex functions. However, the explicit dependency of their convergence rate on the dimension is suboptimal, compared to [8, 16]. Aside from the polytope case, Garber and Hazan [7] have shown that in case the feasible set is strongly-convex and the objective function satisfies certain strong convexity-like proprieties, then the standard CG method converges with an accelerated rate of O(1/t2). Finally, in [6] Garber showed a similar improvement (roughly quadratic) for the spectrahedron – the set of unit trace positive semidefinite matrices. Despite the exponential improvement in convergence rate for polytopes obtained in recent results, they all suffer from two major drawbacks. First, while in terms of the number of calls per-iteration to the linear optimization oracle, these methods match the standard CG method, i.e., a single call per iteration, the overhead of other operations both in terms of running time and memory requirements is significantly worse. The reason is that in order to apply the so-called away-steps, which all methods use, they require to maintain at all times an explicit decomposition of the current iterate into vertices of the polytope. In the worst case, maintaining such a decomposition and computing the away-steps require both memory and per-iteration runtime overheads that are at least quadratic in the dimension. This is much worse than the standard CG method, whose memory and runtime overheads are only linear in the dimension. Second, the convergence rate of all previous linearly convergent CG methods depends explicitly on the dimension. While it is known that this dependency is unavoidable in certain cases, e.g., when the optimal solution is, informally speaking, dense (see for instance the lower bound in [8]), it is not clear that such an unfavorable dependence is mandatory when the optimum is sparse. In this paper, we revisit the application of CG variants to smooth and strongly-convex optimization over polytopes. We introduce a new variant which overcomes both of the above shortcomings from which all previous linearly-converging variants suffer. The main novelty of our method, which is the key to its improved performance, is that unlike previous variants, it is decomposition-invariant, i.e., it 2 Paper #iterations to ✏err. #LOO calls runtime memory Frank & Wolfe [5] βD2/✏ 1 n n Garber & Hazan [8] nD2 log(1/✏) 1 n min(n, t) n min(n, t) Lacoste-Julien & Jaggi [16] nD2 log(1/✏) 1 n min(n, t) n min(n, t) Beck & Shtern [2] n2D2 log(1/✏) 1 n min(n, t) n min(n, t) This paper card(x⇤)D2 log(1/✏) 2 n n Table 1: Comparison with previous work. We define := β/↵, we let n denote the dimension and D denote the Euclidean diameter of the polytope. The third column gives the number of calls to the linear optimization oracle per iteration, the fourth column gives the additional arithmetic complexity at iteration t, and the fifth column gives the worst case memory requirement at iteration t. The bounds for the algorithms of [8, 16, 2], which are independent of t, assume an algorithmic version of Carathéodory’s theorem, as fully detailed in [2]. The bound on number of iterations of [16] depends on the squared inverse pyramidal width of P, which is difficult to evaluate, however, this quantity is at least proportional to n. does not require to maintain an explicit convex decomposition of the current iterate. This principle proves to be crucial both for eliminating the memory and runtime overheads, as well as to obtaining shaper convergence rates for instances that admit a sparse optimal solution. A detailed comparison of our method to previous art is shown in Table 1. We also provide in Section 5 empirical evidence that the proposed method delivers state-of-the-art performance on several tasks of interest. While our method is less general than previous ones, i.e., our theoretical guarantees do not hold for arbitrary polytopes, they readily apply to many structured polytopes that capture important concepts such as paths in graphs, perfect matchings in bipartite graphs, Markov random fields, and more. 2 Preliminaries Throughout this work we let k · k denote the standard Euclidean norm. Given a point x 2 Rn, we let card(x) denote the number of non-zero entries in x. Definition 1. We say that a function f(x) : Rn ! R is ↵-strongly convex w.r.t. a norm k · k, if for all x, y 2 Rn it holds that f(y) ≥f(x) + rf(x) · (y −x) + ↵ 2 kx −yk2. Definition 2. We say that a function f(x) : Rn ! R is β-smooth w.r.t. a norm k · k, if for all x, y 2 Rn it holds that f(y) f(x) + rf(x) · (y −x) + β 2 kx −yk2. The first-order optimality condition implies that for a ↵-strongly convex f, if x⇤is the unique minimizer of f over a convex and compact set K ⇢Rn, then for all x 2 K it holds that f(x) −f(x⇤) ≥↵ 2 kx −x⇤k2. (1) 2.1 Setting In this work we consider the optimization problem minx2P f(x), where we assume that: • f(x) is ↵-strongly convex and β-smooth with respect to the Euclidean norm. • P is a polytope which satisfies the following two properties: 1. P can be described algebraically as P = {x 2 Rn | x ≥0, Ax = b} . 2. All vertices of P lie on the hypercube {0, 1}n. We let x⇤denote the (unique) minimizer of f over P, and we let D denote the Euclidean diameter of P, namely, D = maxx,y2P kx −yk. We let V denote the set of vertices of P, where according to our assumptions, it holds that V ✓{0, 1}n. While the polytopes that satisfy the above assumptions are not completely general, these assumptions already capture several important concepts such as paths in graphs, perfect-matchings, Markov 3 random fields, and more. Indeed, a surprisingly large number of applications from machine learning, signal processing and other domains are formulated as optimization problems in this category (e.g., [13, 15, 16]). We give detailed examples of such polytopes in Section A in the appendix. Importantly, the above assumptions allow us to get rid of the dependency of the convergence rate on certain geometric parameters (such as , ⇠in [8] or the pyramidal width in [16]), which can be polynomial in the dimension, and hence result in an impractical convergence rate. Finally, for many of these polytopes, the vertices are sparse, i.e., for any vertex v 2 V, card(v) << n. In this case, when the optimum x⇤can be decomposed as a convex combination of only a few vertices (and thus, sparse by itself), we get a sharper convergence rate that depends on the sparsity of x⇤and not explicitly on the dimension, as in previous work. We believe that our theoretical guarantees could be well extended to more general polytopes, as suggested in Section C in the appendix; we leave this extension for future work. 3 Our Approach In order to better communicate our ideas, we begin by first briefly introducing the standard conditional gradient method and its accelerated away-steps-based variants. We discuss both the blessings and shortcomings of these away-steps-based variants in Subsection 3.1. Then, in Subsection 3.2, we present our new method, a decomposition-invariant away-steps-based conditional gradient algorithm, and discuss how it addresses the shortcomings of previous variants. 3.1 The conditional gradient method and acceleration via away-steps The standard conditional gradient algorithm is given below (Algorithm 1). It is well known that when setting the step-size ⌘t in an appropriate way, the worst case convergence rate of the method is O(βD2/t) [13]. This convergence rate is tight for the method in general, see for instance [18]. Algorithm 1 Conditional Gradient 1: let x1 be some vertex in V 2: for t = 1... do 3: vt arg minv2V v · rf(xt) 4: choose a step-size ⌘t 2 (0, 1] 5: xt+1 xt + ⌘t(vt −xt) 6: end for Algorithm 2 Pairwise Conditional Gradient 1: let x1 be some vertex in V 2: for t = 1... do 3: let Pkt i=1 λ(i) t v(i) t be an explicitly maintained convex decomposition of xt 4: v+ t arg minv2V v · rf(xt) 5: jt arg minj2[kt] v(j) t · (−rf(xt)) 6: choose a step-size ⌘t 2 (0, λ(jt) t ] 7: xt+1 xt + ⌘t(v+ t −v(jt) t ) 8: update the convex decomposition of xt+1 9: end for Consider the iterate of Algorithm 1 on iteration t, and let xt = Pk i=1 λivi be its convex decomposition into vertices of the polytope P. Note that Algorithm 1 implicitly discounts each coefficient λi by a factor (1 −⌘t), in favor of the new added vertex vt. A different approach is not to decrease all vertices in the decomposition of xt uniformly, but to more-aggressively decrease vertices that are worse than others with respect to some measure, such as their product with the gradient direction. This key principle proves to be crucial to breaking the 1/t rate of the standard method, and to achieve a linear convergence rate under certain strong-convexity assumptions, as described in the recent works [8, 16, 2]. For instance, in [8] it has been shown, via the introduction of the concept of a Local Linear Optimization Oracle, that using such a non-uniform reweighing rule, in fact approximates a certain proximal problem, that together with the shrinking effect of strong convexity, as captured by Eq. (1), yields a linear convergence rate. We refer to these methods as away-step-based CG methods. As a concrete example, which will also serve as a basis for our new method, we describe the pairwise variant recently studied in [16], which applies this principle in Algorithm 2.1 Note that Algorithm 2 decreases the weight of exactly one vertex in the decomposition: that with the largest product with the gradient. 1While the convergence rate of this pairwise variant, established in [16], is significantly worse than other away-step-based variants, here we show that a proper analysis yields state-of-the-art performance guarantees. 4 It is important to note that since previous away-step-based CG variants do not decrease the coefficients in the convex decomposition of the current iterate uniformly, they all require to explicitly store and maintain a convex decomposition of the current iterate. This issue raises two main disadvantages: Superlinear memory and running-time overheads Storing a decomposition of the current iterate as a convex combination of vertices generally requires O(n2) memory in the worst case. While the away-step-based variants increase the size of the decomposition by at most a single vertex per iteration, they also typically exhibit linear convergence after performing at least ⌦(n) steps [8, 16, 2], and thus, this O(n2) estimate still holds. Moreover, since these methods require i) to find the worst vertex in the decomposition, in terms of dot-product with current gradient direction, and ii) to update this decomposition at each iteration (even when using sophisticated update techniques such as in [2]), then the worst case per-iteration overhead in terms of computation is also ⌦(n2). Decomposition-specific performance The choice of away-step depends on the specific decomposition that is maintained by the algorithm. Since the feasible point xt may admit several different convex decompositions, committing to one such decomposition, might result in sub-optimal away-steps. As observable in Table 1, for certain problems in which the optimal solution is sparse, all analyses of previous away-steps-based variants are significantly suboptimal, since they all depend explicitly on the dimension. This seems to be an unavoidable side-effect of being decomposition-dependent. On the other hand, the fact that our new approach is decomposition-invariant allows us to obtain sharper convergence rates for such instances. 3.2 A new decomposition-invariant pairwise conditional gradient method Our main observation is that in many cases of interest, given a feasible iterate xt, one can in fact compute an optimal away-step from xt without relying on any single specific decomposition. This observation allows us to overcome both of the main disadvantages of previous away-step-based CG variants. Our algorithm, which we refer to as a decomposition-invariant pairwise conditional gradient (DICG), is given below in Algorithm 3. Algorithm 3 Decomposition-invariant Pairwise Conditional Gradient 1: input: sequence of step-sizes {⌘t}t≥1 2: let x0 be an arbitrary point in P 3: x1 arg minv2V v · rf(x0) 4: for t = 1... do 5: v+ t arg minv2V v · rf(xt) 6: define the vector ˜rf(xt) 2 Rn as follows: [ ˜rf(xt)]i := ⇢ [rf(xt)]i if xt(i) > 0 −1 if xt(i) = 0 7: v− t arg minv2V v · (−˜rf(xt)) 8: choose a new step-size ˜⌘t using one of the following two options: Option 1: predefined step-size let δt be the smallest natural number such that 2−δt ⌘t, and set a new step-size ˜⌘t 2−δt Option 2: line-search γt maxγ2[0,1]{xt + γ(v+ t −v− t ) ≥0}, ˜⌘t min⌘2(0,γt] f(xt + ⌘(v+ t −v− t )) 9: xt+1 xt + ˜⌘t(v+ t −v− t ) 10: end for The following observation shows the optimality of away-steps taken by Algorithm 3. Observation 1 (optimal away-steps in Algorithm 3). Consider an iteration t of Algorithm 3 and suppose that the iterate xt is feasible. Let xt = Pk i=1 λivi for some integer k, be an irreducible way of writing xt as a convex sum of vertices of P, i.e., λi > 0 for all i 2 [k]. Then it holds that 8i 2 [k] : vi · rf(xt) v− t · rf(xt), and γt ≥min{xt(i) | i 2 [n], xt(i) > 0}. Proof. Let xt = Pk i=1 λivi be a convex decomposition of xt into vertices of P, for some integer k, where each λi is positive. Note that it must hold that for any j 2 [n] and any i 2 [k], xt(j) = 0 ) vi(j) = 0, since by our assumption V ⇢Rn +. The observation then follows directly from the definition of v− t . We next state the main theorem of this paper, which bounds the convergence rate of Algorithm 3. The proof is provided in Section B.3 in the appendix. 5 Theorem 1. Let M1 = p ↵/(8card(x⇤)) and M2 = βD2/2. Consider running Algorithm 3 with Option 1 as the step-size, and suppose that 8t ≥1 : ⌘t = # M1/(2pM2) $ # 1 −M 2 1 /(4M2) $ t−1 2 . Then, the iterates of Algorithm 3 are always feasible, and 8t ≥1: f(xt) −f(x⇤) βD2 2 exp ✓ − ↵ 8βD2card(x⇤)t ◆ . We now turn to make several remarks regarding Algorithm 3 and Theorem 1: The so-called dual gap, defined as gt := (xt −v+ t ) · rf(xt), which serves as a certificate for the sub-optimality of the iterates of Algorithm 3, also converges with a linear rate, as we prove in Section B.4 in the appendix. Note that despite the different parameters of the problem at hand (e.g., ↵, β, D, card(x⇤)), running the algorithm with Option 1 for choosing the step-size, for which the guarantee of Theorem 1 holds, requires knowing a single parameter, i.e., M1/pM2. In particular, it is an easy consequence that running the algorithm with an estimate M 2 [0.5M1/pM2, M1/pM2], will only affect the leading constant in the convergence rate listed in the theorem. Hence, M1/pM2 could be efficiently estimated via a logarithmic-scale search. Theorem 1 improves significantly over the convergence rate established for the pairwise conditional gradient variant in [16]. In particular, the number of iterations to reach an ✏error in the analysis of [16] depends linearly on |V|!, where |V| is the number of vertices of P. 4 Analysis Throughout this section we let ht denote the approximation error of Algorithm 3 on iteration t, for any t ≥1, i.e., ht = f(xt) −f(x⇤). 4.1 Feasibility of the iterates generated by Algorithm 3 We start by proving that the iterates of Algorithm 3 are always feasible. While feasibility is straightforward when using the the line-search option to set the step-size (Option 2), it is less obvious when using Option 1. We will make use of the following observation, which is a simple consequence of the optimal choice of v− t and our assumptions on P. A proof is given in Section B.1 in the appendix. Observation 2. Suppose that on some iteration t of Algorithm 3, the iterate xt is feasible, and that the step-size is chosen using Option 1. Then, if for all i 2 [n] for which xt(i) 6= 0 it holds that xt(i) ≥˜⌘t, the following iterate xt+1 is also feasible. Lemma 1 (feasibility of iterates under Option 1). Suppose that the sequence of step-sizes {⌘t}t≥1 is monotonically non-increasing, and contained in the interval [0, 1]. Then, the iterates generated by Algorithm 3 using Option 1 for setting the step-size, are always feasible. Proof. We are going to prove by induction that on each iteration t there exists a non-negative integervalued vector st 2 Nn, such that for any i 2 [n], it holds that xt(i) = 2−δtst(i). The lemma then follows since, by definition, ˜⌘t = 2−δt, and by applying Observation 2. The base case t = 1 holds since x1 is a vertex of P and thus for any i 2 [n] we have that x1(i) 2 {0, 1} (recall that V ⇢{0, 1}n). On the other hand, since ⌘1 1, it follows that δ1 ≥0. Thus, there indeed exists a non-negative integer-valued vector s1, such that x1 = 2−δ1s1. Suppose now that the induction holds for some t ≥1. Since by definition of v− t , subtracting ˜⌘tv− t from xt can only decrease positive entries in xt (see proof of Observation 2), and both v− t , v+ t are vertices of P (and thus in {0, 1}n), and ˜⌘t = 2−δt, it follows that each entry i in xt+1 is given by: xt+1(i) = 2−δt 8 < : st(i) if st(i) ≥1 & v− t (i) = v+ t (i) = 1 or v− t (i) = v+ t (i) = 0 st(i) −1 if st(i) ≥1 & v− t (i) = 1 & v+ t (i) = 0 st(i) + 1 if v− t (i) = 0 & v+ t (i) = 1 Thus, xt+1 can also be written in the form 2−δt˜st+1 for some ˜st+1 2 Nn. By definition of δt and the monotonicity of {⌘t}t≥1, we have that 2−δt 2−δt+1 is a positive integer. Thus, setting st+1 = 2−δt 2−δt+1 ˜st+1, the induction holds also for t + 1. 6 4.2 Bounding the per-iteration error-reduction of Algorithm 3 The following technical lemma is the key to deriving the linear convergence rate of our method, and in particular, to deriving the improved dependence on the sparsity of x⇤, instead of the dimension. At a high-level, the lemma translates the `2 distance between two feasible points into a `1 distance in a simplex defined over the set of vertices of the polytope. Lemma 2. Let x, y 2 P. There exists a way to write x as a convex combination of vertices of P, x = Pk i=1 λivi for some integer k, such that y can be written as y = Pk i=1(λi−∆i)vi+(Pk i=1 ∆i)z with ∆i 2 [0, λi] 8i 2 [k],z 2 P, and Pk i=1 ∆i p card(y)kx −yk. The proof is given in Section B.2 in the appendix. The next lemma bounds the per-iteration improvement of Algorithm 3 and is the key step to proving Theorem 1. We defer the rest of the proof of Theorem 1 to Section B.3 in the appendix. Lemma 3. Consider the iterates of Algorithm 3, when the step-sizes are chosen using Option 1. Let M1 = p ↵/(8card(x⇤)) and M2 = βD2/2. For any t ≥1 it holds that ht+1 ht −⌘tM1h1/2 t + ⌘2 t M2. Proof. Define ∆t = p 2card(x⇤)ht/↵, and note that from Eq. (1) we have that ∆t ≥ p card(x⇤)kxt −x⇤k. As a first step, we are going to show that the point yt := xt + ∆t(v+ t −v− t ) satisfies: yt · rf(xt) x⇤· rf(xt). From Lemma 2 it follows that we can write x as a convex combination xt = Pk i=1 λivi and write x⇤as x⇤= Pk i=1(λi −∆i)vi + Pk i=1 ∆iz, where ∆i 2 [0, λi], z 2 P, and Pk i=1 ∆i ∆t. It holds that (yt −xt) · rf(xt) = ∆t(v+ t −v− t ) · rf(xt) Xk i=1 ∆i(v+ t −v− t ) · rf(xt) Xk i=1 ∆i(z −vi) · rf(xt) = (x⇤−xt) · rf(xt), where the first inequality follows since (v+ t −v− t ) · rf(xt) 0, and the second inequality follows from the optimality of v+ t and v− t (Observation 1). Rearranging, we have that indeed # xt + ∆t(v+ t −v− t ) $ · rf(xt) x⇤· rf(xt). (2) Observe now that from the definition of ˜⌘t it follows for any t ≥1 that ⌘t 2 ˜⌘t ⌘t. Using the smoothness of f(x) we have that ht+1 = f(xt + ˜⌘t(v+ t −v− t )) −f(x⇤) ht + ˜⌘t(v+ t −v− t ) · rf(xt) + ˜⌘2 t β 2 kv+ t −v− t k2 ht + ˜⌘t(v+ t −v− t ) · rf(xt) + ˜⌘2 t βD2 2 ht + ⌘t 2 (v+ t −v− t ) · rf(xt) + ⌘2 t βD2 2 = ht + ⌘t 2∆t & (xt + ∆t(v+ t −v− t ) −xt ' · rf(xt) + ⌘2 t βD2 2 ht + ⌘t 2∆t (x⇤−xt) · rf(xt) + ⌘2 t βD2 2 ht −⌘t 2∆t ht + ⌘2 t βD2 2 , where the third inequality follows since (v+ t −v− t ) · rf(xt) 0, the forth inequality follows from Eq. (2), and the last inequality follows from convexity of f(x). Finally, plugging the value of ∆t completes the proof. 5 Experiments In this section we illustrate the performance of our algorithm in numerical experiments. We use the two experimental settings from [16], which include a constrained Lasso problem and a video co-localization problem. In addition, we test our algorithm on a learning problem related to an optical character recognition (OCR) task from [23]. In each setting we compare the performance of our algorithm (DICG) to standard conditional gradient (CG), as well as to the fast away (ACG) and pairwise (PCG) variants [16]. For the baselines in the first two settings we use the publicly available code from [16], to which we add our own implementation of Algorithm 3. Similarly, for the OCR problem we extend code from [20], kindly provided by the authors. For all algorithms we use line-search to set the step size. 7 Lasso Video co-localization OCR 0 200 400 600 800 1000 10 −5 10 0 10 5 Iteration Gap CG ACG PCG DICG 0 500 1000 1500 2000 10 −8 10 −6 10 −4 10 −2 Iteration Gap CG ACG PCG DICG 0 500 1000 1500 2000 10 −3 10 −2 10 −1 Effective passes Gap CG ACG PCG DICG 0 2 4 6 8 10 10 −5 10 0 10 5 Time (sec) Gap CG ACG PCG DICG 0 5 10 15 20 25 30 10 −8 10 −6 10 −4 10 −2 Time (sec) Gap CG ACG PCG DICG Time (hr) 0 1 2 3 4 5 6 Gap 10-3 10-2 CG ACG PCG DICG Figure 1: Duality gap gt vs. iterations (top) and time (bottom) in various settings. Lasso In the first example the goal is to solve the problem: minx2M k ¯Ax −¯bk2, where M is a scaled `1 ball. Notice that the constraints M do not match the required structure of P, however, with a simple change of variables we can obtain an equivalent optimization problem over the simplex. We generate the random matrix ¯A and vector ¯b as in [16]. In Figure 1 (left, top) we observe that our algorithm (DICG) converges similarly to the pairwise variant PCG and faster than the other baselines. This is expected since the away direction v−in DICG (Algorithm 3) is equivalent to the away direction in PCG (Algorithm 2) in the case of simplex constraints. Video co-localization The second example is a quadratic program over the flow polytope, originally proposed in [15]. This is an instance of P that is mentioned in Section A in the appendix. As can be seen in Figure 1 (middle, top), in this setting our proposed algorithm significantly outperforms the baselines, as a result of finding a better away direction v−. Figure 1 (middle, bottom) shows convergence on a time scale, where the difference between the algorithms is even larger. One reason for this difference is the costly search over the history of vertices maintained by the baseline algorithms. Specifically, the number of stored vertices grows fast with the number of iterations and reaches 1222 for away steps and 1438 for pairwise steps (out of 2000 iterations). OCR We next conduct experiments on a structured SVM learning problem resulting from an OCR task. The constraints in this setting are the marginal polytope corresponding to a chain graph over the letters of a word (see [23]), and the objective function is quadratic. Notice that the marginal polytope has a concise characterization in this case and also satisfies our assumptions (see Section A in the appendix for more details). For this problem we actually run Algorithm 3 in a block-coordinate fashion, where blocks correspond to training examples in the dual SVM formulation [17, 20]. In Figure 1 (right, top) we see that our DICG algorithm is comparable to the PCG algorithm and faster than the other baselines on the iteration scale. Figure 1 (right, bottom) demonstrates that in terms of actual running time we get a noticeable speedup compared to all baselines. We point out that for this OCR problem, both ACG and PCG each require about 5GB of memory to store the explicit decomposition in the implementation of [20]. In comparison, our algorithm requires 220MB of memory to store the current iterate, and the other variables in the code require 430MB (common to all algorithms), so using DICG results in significant memory savings. 6 Extensions Our results are readily extendable in two important directions. First, we can relax the strong convexity requirement of f(x) and handle a broader class of functions, namely the class considered in [2]. Second, we extend the line-search variant of Algorithm 3 to handle arbitrary polytopes, but without convergence guarantees, which is left as future work. Both extensions are brought in full detail in Section C in the appendix. 8 References [1] S. Damla Ahipasaoglu, Peng Sun, and Michael J. Todd. Linear convergence of a modified frank-wolfe algorithm for computing minimum-volume enclosing ellipsoids. Optimization Methods and Software, 23(1):5–19, 2008. [2] Amir Beck and Shimrit Shtern. Linearly convergent away-step conditional gradient for non-strongly convex functions. arXiv preprint arXiv:1504.05002, 2015. [3] Amir Beck and Marc Teboulle. A conditional gradient method with linear rate of convergence for solving convex linear systems. Math. Meth. of OR, 59(2):235–247, 2004. [4] Miroslav Dudík, Zaïd Harchaoui, and Jérôme Malick. Lifted coordinate descent for learning with tracenorm regularization. Journal of Machine Learning Research - Proceedings Track, 22:327–336, 2012. [5] M. Frank and P. Wolfe. An algorithm for quadratic programming. Naval Research Logistics Quarterly, 3:149–154, 1956. [6] Dan Garber. Faster projection-free convex optimization over the spectrahedron. arXiv preprint arXiv:1605.06203, 2016. [7] Dan Garber and Elad Hazan. Faster rates for the frank-wolfe method over strongly-convex sets. In Proceedings of the 32nd International Conference on Machine Learning, ICML 2015, Lille, France, 6-11 July 2015, pages 541–549, 2015. [8] Dan Garber and Elad Hazan. A linearly convergent variant of the conditional gradient algorithm under strong convexity, with applications to online and stochastic optimization. SIAM Journal on Optimization, 26(3):1493–1528, 2016. [9] Jacques GuéLat and Patrice Marcotte. Some comments on Wolfe’s ‘away step’. Mathematical Programming, 35(1), 1986. [10] Zaïd Harchaoui, Matthijs Douze, Mattis Paulin, Miroslav Dudík, and Jérôme Malick. Large-scale image classification with trace-norm regularization. In IEEE Conference on Computer Vision and Pattern Recognition, CVPR, 2012. [11] Elad Hazan and Satyen Kale. Projection-free online learning. In Proceedings of the 29th International Conference on Machine Learning, ICML, 2012. [12] Elad Hazan and Haipeng Luo. Variance-reduced and projection-free stochastic optimization. CoRR, abs/1602.02101, 2016. [13] Martin Jaggi. Revisiting frank-wolfe: Projection-free sparse convex optimization. In Proceedings of the 30th International Conference on Machine Learning, ICML, 2013. [14] Martin Jaggi and Marek Sulovský. A simple algorithm for nuclear norm regularized problems. In Proceedings of the 27th International Conference on Machine Learning, ICML, 2010. [15] Armand Joulin, Kevin Tang, and Li Fei-Fei. Efficient image and video co-localization with Frank-Wolfe algorithm. In Computer Vision–ECCV 2014, pages 253–268. Springer, 2014. [16] Simon Lacoste-Julien and Martin Jaggi. On the global linear convergence of Frank-Wolfe optimization variants. In Advances in Neural Information Processing Systems, pages 496–504, 2015. [17] Simon Lacoste-Julien, Martin Jaggi, Mark W. Schmidt, and Patrick Pletscher. Block-coordinate frankwolfe optimization for structural svms. In Proceedings of the 30th International Conference on Machine Learning, ICML, 2013. [18] Guanghui Lan. The complexity of large-scale convex programming under a linear optimization oracle. CoRR, abs/1309.5550, 2013. [19] Sören Laue. A hybrid algorithm for convex semidefinite optimization. In Proceedings of the 29th International Conference on Machine Learning, ICML, 2012. [20] Anton Osokin, Jean-Baptiste Alayrac, Puneet K. Dokania, and Simon Lacoste-Julien. Minding the gaps for block frank-wolfe optimization of structured svm. In International Conference on Machine Learning (ICML), 2016. [21] A. Schrijver. Combinatorial Optimization - Polyhedra and Efficiency. Springer, 2003. [22] Shai Shalev-Shwartz, Alon Gonen, and Ohad Shamir. Large-scale convex minimization with a low-rank constraint. In Proceedings of the 28th International Conference on Machine Learning, ICML, 2011. [23] B. Taskar, C. Guestrin, and D. Koller. Max-margin Markov networks. In Advances in Neural Information Processing Systems. MIT Press, 2003. [24] M. Wainwright and M. I. Jordan. Graphical Models, Exponential Families, and Variational Inference. Now Publishers Inc., Hanover, MA, USA, 2008. [25] Yiming Ying and Peng Li. Distance metric learning with eigenvalue optimization. J. Mach. Learn. Res., 13(1):1–26, January 2012. 9 | 2016 | 492 |
6,430 | Combining Adversarial Guarantees and Stochastic Fast Rates in Online Learning Wouter M. Koolen Centrum Wiskunde & Informatica Science Park 123, 1098 XG Amsterdam, the Netherlands wmkoolen@cwi.nl Peter Grünwald CWI and Leiden University pdg@cwi.nl Tim van Erven Leiden University Niels Bohrweg 1, 2333 CA Leiden, the Netherlands tim@timvanerven.nl Abstract We consider online learning algorithms that guarantee worst-case regret rates in adversarial environments (so they can be deployed safely and will perform robustly), yet adapt optimally to favorable stochastic environments (so they will perform well in a variety of settings of practical importance). We quantify the friendliness of stochastic environments by means of the well-known Bernstein (a.k.a. generalized Tsybakov margin) condition. For two recent algorithms (Squint for the Hedge setting and MetaGrad for online convex optimization) we show that the particular form of their data-dependent individual-sequence regret guarantees implies that they adapt automatically to the Bernstein parameters of the stochastic environment. We prove that these algorithms attain fast rates in their respective settings both in expectation and with high probability. 1 Introduction We consider online sequential decision problems. We focus on full information settings, encompassing such interaction protocols as online prediction, classification and regression, prediction with expert advice or the Hedge setting, and online convex optimization (see Cesa-Bianchi and Lugosi 2006). The goal of the learner is to choose a sequence of actions with small regret, i.e. such that his cumulative loss is not much larger than the loss of the best fixed action in hindsight. This has to hold even in the worst case, where the environment is controlled by an adversary. After three decades of research there exist many algorithms and analysis techniques for a variety of such settings. For many settings, adversarial regret lower bounds of order √ T are known, along with matching individual sequence algorithms [Shalev-Shwartz, 2011]. A more recent line of development is to design adaptive algorithms with regret guarantees that scale with some more refined measure of the complexity of the problem. For the Hedge setting, results of this type have been obtained, amongst others, by Cesa-Bianchi et al. [2007], De Rooij et al. [2014], Gaillard et al. [2014], Sani et al. [2014], Even-Dar et al. [2008], Koolen et al. [2014], Koolen and Van Erven [2015], Luo and Schapire [2015], Wintenberger [2015]. Interestingly, the price for such adaptivity (i.e. the worsening of the worst-case regret bound) is typically extremely small (i.e. a constant factor in the regret bound). For online convex optimization (OCO), many different types of adaptivity have been explored, including by Crammer et al. [2009], Duchi et al. [2011], McMahan and Streeter [2010], Hazan and Kale [2010], Chiang et al. [2012], Steinhardt and Liang [2014], Orabona et al. [2015], Van Erven and Koolen [2016]. Here we are interested in the question of whether such adaptive results are strong enough to lead to improved rates in the stochastic case when the data follow a “friendly” distribution. In specific cases it has been shown that fancy guarantees do imply significantly reduced regret. For example Gaillard et al. [2014] present a generic argument showing that a certain kind of second-order regret guarantees 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. implies constant expected regret (the fastest possible rate) for i.i.d. losses drawn from a distribution with a gap (between expected loss of the best and all other actions). In this paper we significantly extend this result. We show that a variety of individual-sequence second-order regret guarantees imply fast regret rates for distributions under much milder stochastic assumptions. In particular, we will look at the Bernstein condition (see Bartlett and Mendelson 2006), which is the key to fast rates in the batch setting. This condition provides a parametrised interpolation (expressed in terms of the Bernstein exponent κ ∈[0,1]) between the friendly gap case (κ = 1) and the stochastic worst case (κ = 0). We show that appropriate second-order guarantees automatically lead to adaptation to these parameters, for both the Hedge setting and for OCO. In the Hedge setting, we build on the guarantees available for the Squint algorithm [Koolen and Van Erven, 2015] and for OCO we rely on guarantees achieved by MetaGrad [Van Erven and Koolen, 2016]. In both cases we obtain regret rates of order T 1−κ 2−κ (Theorem 2). These rates include the slow worst-case √ T regime for κ = 0 and the fastest (doubly) logarithmic regime for κ = 1. We show all this, not just in expectation (which is relatively easy), but also with high probability (which is much harder). Our proofs make use of a a convenient novel notation (ESI, for exponential stochastic inequality) which allows us to prove such results simultaneously, and which is of independent interest (Definition 5). Our proofs use that, for bounded losses, the Bernstein condition is equivalent to the ESI-Bernstein condition, which we introduce. The next section introduces the two settings we consider and the individual sequence guarantees we will use in each. It also reviews the stochastic criteria for fast rates and presents our main result. In Section 3 we consider a variety of examples illustrating the breadth of cases that we cover. In Section 4 we introduce ESI and give a high-level overview of our proof. 2 Setup and Main Result 2.1 Hedge Setting We start with arguably the simplest setting of online prediction, the Hedge setting popularized by Freund and Schapire [1997]. To be able to illustrate the full reach of our stochastic assumption we will use a minor extension to countably infinitely many actions k ∈N = {1,2,...}, customarily called experts. The protocol is as follows. Each round t the learner plays a probability mass function wt = (w1 t ,w2 t ,...) on experts. Then the environment reveals the losses ℓt = (ℓ1 t,ℓ2 t,...) of the experts, where each ℓk t ∈[0,1]. The learner incurs loss ⟨wt,ℓt⟩= ∑k wk t ℓk t . The regret after T rounds compared to expert k is given by Rk T ∶= T ∑ t=1 (⟨wt,ℓt⟩−ℓk t ). The goal of the learner is to keep the regret small compared to any expert k. We will make use of Squint by Koolen and Van Erven [2015], a self-tuning algorithm for playing wt. Koolen and Van Erven [2015, Theorem 4] show that Squint with prior probability mass function π = (π1,π2,...) guarantees Rk T ≤ √ V k T Kk T + Kk T where Kk T = O(−lnπk + lnlnT) for any expert k. (1) Here V k T ∶= ∑T t=1 (⟨wt,ℓt⟩−ℓk t ) 2 is a second-order term that depends on the algorithm’s own predictions wt. It is well-known that with K experts the worst-case lower bound is Θ( √ T lnK) [Cesa-Bianchi and Lugosi, 2006, Theorem 3.7]. Taking a fat-tailed prior π, for example πk = 1 k(k+1), and using V k T ≤T, the above bound implies Rk T ≤O ( √ T(lnk + lnlnT)), matching the lower bound in some sense for all k simultaneously. The question we study in this paper is what becomes of the regret when the sequence of losses ℓ1,ℓ2,... is drawn from some distribution P, not necessarily i.i.d. But before we expand on such stochastic cases, let us first introduce another setting. 2.2 Online Convex Optimization (OCO) We now turn to our second setting called online convex optimization [Shalev-Shwartz, 2011]. Here the set of actions is a compact convex set U ⊆Rd. Each round t the learner plays a point wt ∈U. 2 Then the environment reveals a convex loss function ℓt ∶U →R. The loss of the learner is ℓt(wt). The regret after T rounds compared to u ∈U is given by Ru T ∶= T ∑ t=1 (ℓt(wt) −ℓt(u)). The goal is small regret compared to any point u ∈U. A common tool in the analysis of algorithms is the linear upper bound on the regret obtained from convexity of ℓt (at non-differentiable points we may take any sub-gradient) Ru T ≤˜Ru T ∶= T ∑ t=1 ⟨wt −u,∇ℓt(wt)⟩. We will make use of (the full matrix version of) MetaGrad by Van Erven and Koolen [2016]. In their Theorem 8, they show that, simultaneously, ˜Ru T ≤O (DG √ T) and ˜Ru T ≤ √ V u T KT + DGKT where KT = O(dlnT) for any u ∈U, (2) where D bounds the two-norm diameter of U, G bounds ∥∇ℓt(wt)∥2 the two-norm of the gradients and V u T ∶= ∑T t=1⟨wt −u,∇ℓt(wt)⟩2. The first bound matches the worst-case lower bound. The second bound (2) may be a factor √KT worse, as V u T ≤G2D2T by Cauchy-Schwarz. Yet in this paper we will show fast rates in certain stochastic settings arising from (2). To simplify notation we will assume from now on that DG = 1 (this can always be achieved by scaling the loss). To talk about stochastic settings we will assume that the sequence ℓt of loss functions (and hence the gradients ∇ℓt(wt)) are drawn from a distribution P, not necessarily i.i.d. This includes the common case of linear regression and classification where ℓt(u) = loss(⟨u,xt⟩,yt) with (xt,yt) sampled i.i.d. and loss a fixed one-dimensional convex loss function (e.g. square loss, absolute loss, log loss, hinge loss, ...). 2.3 Parametrised Family of Stochastic Assumptions We now recall the Bernstein [Bartlett and Mendelson, 2006] stochastic condition. The idea behind this assumption is to control the variance of the excess loss of the actions in the neighborhood of the best action. We do not require that the losses are i.i.d., nor that the Bayes act is in the model. For the Hedge setting it suffices if there is a fixed expert k∗that is always best, i.e. E[ℓk∗ t ∣Gt−1] = infk E[ℓk t ∣Gt−1] almost surely for all t. (Here we denote by Gt−1 the sigma algebra generated by ℓ1,...,ℓt−1, and the almost surely quantification refers to the distribution of ℓ1,...,ℓt−1.) Similarly, for OCO we assume there is a fixed point u∗∈U attaining minu∈U E[ℓt(u)∣Gt−1] at every round t. In either case there may be multiple candidate k∗or u∗. In the succeeding we assume that one is selected. Note that for i.i.d. losses the existence of a minimiser is not such a strong assumption (if the loss functions ℓt are continuous, it is even automatic in the OCO case due to compactness of U), while it is very strong beyond i.i.d. Yet it is not impossible (and actually interesting) as we will show by example in Section 3. Based on the loss minimiser, we define the excess losses, a family of random variables indexed by time t ∈N and expert/point k ∈N/u ∈U as follows xk t ∶= ℓk t −ℓk∗ t (Hedge) and xu t ∶= ⟨u −u∗,∇ℓt(u)⟩ (OCO). (3) Note that for the Hedge setting we work with the loss directly. For OCO instead we talk about the linear upper bound on the excess loss, for this is the quantity that needs to be controlled to make use of the MetaGrad bound (2). With these variables in place, from this point on the story is the same for Hedge and for OCO. So let us write F for either the set N of experts or the set U of points, and f ∗ for k∗resp. u∗, and let us consider the family {xf t ∣f ∈F,t ∈N}. We call f ∈F predictors. With this notation the Bernstein condition is the following. Condition 1. Fix B ≥0 and κ ∈[0,1]. The family (3) satisfies the (B,κ)-Bernstein condition if E[(xf t )2∣Gt−1] ≤B E[xf t ∣Gt−1] κ almost surely for all f ∈F and rounds t ∈N. 3 The point of this stochastic condition is that it implies that the variance in the excess loss gets smaller the closer a predictor gets to the optimum in terms of expected excess loss. Some authors refer to the κ = 1 case as the Massart condition. Van Erven et al. [2015] have shown that the Bernstein condition is equivalent to the central condition, a fast-rate type of condition that has been frequently used (without an explicit name) in density estimation under misspecification. Two more equivalent conditions appear in our proof sketch Section 4. We compare all four formulations in Appendix B. 2.4 Main Result In the stochastic case we evaluate the performance of algorithms by Rf ∗ T , i.e. the regret compared to the predictor f ∗with minimal expected loss. The expectation E[Rf ∗ T ] is sometimes called the pseudo-regret. The following result shows that second-order methods automatically adapt to the Bernstein condition. (Proof sketch in Section 4.) Theorem 2. In any stochastic setting satisfying the (B,κ)-Bernstein Condition 1, the guarantees (1) for Squint and (2) for MetaGrad imply fast rates for the respective algorithms both in expectation and with high probability. That is, E[Rf ∗ T ] = O (K 1 2−κ T T 1−κ 2−κ ), and for any δ > 0, with probability at least 1 −δ, Rf ∗ T = O ((KT −lnδ) 1 2−κ T 1−κ 2−κ ), where for Squint KT ∶= Kf ∗ T from (1) and for MetaGrad KT is as in (2). We see that Squint and MetaGrad adapt automatically to the Bernstein parameters of the distribution, without any tuning. Theorem 2 only uses the form of the second-order bounds and does not depend on the details of the algorithms, so it also applies to any other method with a second-order regret bound. In particular it holds for Adapt-ML-Prod by Gaillard et al. [2014], which guarantees (1) with KT = O(ln∣F∣+lnlnT) for finite sets of experts. Here we focus on Squint as it also applies to infinite sets. Appendix D provides an extension of Theorem 2 that allows using Squint with uncountable F. Crucially, the bound provided by Theorem 2 is natural, and, in general, the best one can expect. This can be seen from considering the statistical learning setting, which is a special case of our setup. Here (xt,yt) are i.i.d. ∼P and F is a set of functions from X to a set of predictions A, with ℓf t ∶= ℓ(yt,f(xt)) for some loss function ℓ∶Y × A →[0,1] such as squared, 0/1, or absolute loss. In this setting one usually considers excess risk, which is the expected loss difference between the learned ˆf and the optimal f ∗. The minimax expected (over training sample (xt,yt)) risk relative to f ∗is of order T −1/2 (see e.g. Massart and Nédélec [2006], Audibert [2009]). To get better risk rates, one has to impose further assumptions on P. A standard assumption made in such cases is a Bernstein condition with exponent κ > 0; see e.g. Koltchinskii [2006], Bartlett and Mendelson [2006], Audibert [2004] or Audibert [2009]; see Van Erven et al. [2015] for how it generalizes the Tsybakov margin and other conditions. If F is sufficiently ‘simple’, e.g. a class with logarithmic entropy numbers (see Appendix D), or, in classification, a VC class, then, if a κ-Bernstein condition holds, ERM (empirical risk minimization) achieves, in expectation, a better excess risk bound of order O((log T) ⋅T − 1 2−κ ). The bound interpolates between T −1/2 for κ = 0 and T −1 for κ = 1 (Massart condition). Results of Tsybakov [2004], Massart and Nédélec [2006], Audibert [2009] suggest that this rate can, in general, not be improved upon, and exactly this rate is achieved by ERM and various other algorithms in various settings by e.g. Tsybakov [2004], Audibert [2004, 2009], Bartlett et al. [2006]. By summing from t = 1 to T and using ERM at each t to classify the next data point (so that ERM becomes FTL, follow-the-leader), this suggests that we can achieve a cumulative expected regret E[Rf ∗ T ] of order O((log T) ⋅T 1−κ 2−κ ). Theorem 2 shows that this is, indeed, also the rate that Squint attains in such cases if F is countable and the optimal f ∗has positive prior mass πf ∗> 0 (more on this condition below)— we thus see that Squint obtains exactly the rates one would expect from a statistical 4 learning/classification perspective, and the minimax excess risk results in that setting suggests that these cumulative regret rates cannot be improved in general. It was shown earlier by Audibert [2004] that, when equipped with an oracle to tune the learning rate η as a function of t, the rates O ((log T) ⋅T 1−κ 2−κ ) can also be achieved by Hedge, but the exact tuning depends on the unknown κ. Grünwald [2012] provides a means to tune η automatically in terms of the data, but his method — like ERM and all algorithms in the references above — may achieve linear regret in worst-case settings, whereas Squint keeps the O( √ T) guarantee for such cases. Theorem 2 only gives the desired rate for Squint with infinite F if F is countable and πf ∗> 0. The combination of these two assumptions is strong or at least unnatural, and OCO cannot be readily used in all such cases either, so in Appendix D we therefore show how to extend Theorem 2 to the case of uncountably infinite F, which can have πf ∗= 0, as long as F admits sufficiently small entropy numbers. Incidentally, this also allows us to show that Squint achieves regret rate O ((log T) ⋅T 1−κ 2−κ ) when F = ⋃i=1,2,... Fi is a countably infinite union of Fi with appropriate entropy numbers; in such cases there can be, at every sample size, a classifier ˆf ∈F with 0 empirical error, so that ERM/FTL will always over-fit and cannot be used even if the Bernstein condition holds; Squint allows for aggregation of such models. In the remainder of the main text, we concentrate on applications for which Theorem 2 can be used directly, without extensions. 3 Examples We give examples motivating and illustrating the Bernstein condition for the Hedge and OCO settings. Our examples in the Hedge setting will illustrate Bernstein with κ < 1 and non i.i.d. distributions. Our OCO examples were chosen to be natural and illustrate fast rates without curvature. 3.1 Hedge Setting: Gap implies Bernstein with κ = 1 In the Hedge setting, we say that a distribution P (not necessarily i.i.d.) of expert losses {ℓk t ∣t,k ∈N} has gap α > 0 if there is an expert k∗such that E[ℓk∗ t ∣Gt−1] + α ≤ inf k≠k∗E[ℓk t ∣Gt−1] almost surely for each round t ∈N. It is clear that the condition can only hold for k∗the minimiser of the expected loss. Lemma 3. A distribution with gap α is ( 1 α,1)-Bernstein. Proof. For all k ≠k∗and t, we have E[(xk t )2∣Gt−1] ≤1 = 1 αα ≤1 α E[xk t ∣Gt−1] . By Theorem 2 we get the Rk∗ T = O(KT ) = O(lnlnT) rate. Gaillard et al. [2014] show constant regret for finitely many experts and i.i.d. losses with a gap. Our alternative proof above shows that neither finiteness nor i.i.d. are essential for fast rates in this case. 3.2 Hedge Setting: Any (1,κ)-Bernstein The next example illustrates that we can sometimes get the fast rates without a gap. And it also shows that we can get any intermediate rate: we construct an example satisfying the Bernstein condition for any κ ∈[0,1] of our choosing (such examples occur naturally in classification settings such as those considered in the example in Appendix D). Fix κ ∈[0,1]. Each expert k = 1,2,... is parametrised by a real number δk ∈[0,1/2]. The only assumption we make is that δk = 0 for some k, and infk{δk ∣δk > 0} = 0. For a concrete example let us choose δ1 = 0 and δk = 1/k for k = 2,3,... Expert δk has loss 1/2 ± δk with probability 1±δ2/κ−1 k 2 independently between experts and rounds. Expert δk has mean loss 1 2 + δ2/κ k , and so δ1 = 0 is best, with loss deterministically equal to 1/2. The squared excess loss of δk is δ2 k. So we have the Bernstein condition with exponent κ (but no κ′ > κ) and constant 1, and the associated regret rate by Theorem 2. 5 Note that for κ = 0 (the hard case) all experts have mean loss equal to 1 2. So no matter which k∗ we designate as the best expert our pseudo-regret E[Rk∗ T ] is zero. Yet the experts do not agree, as their losses deviate from 1 2 independently at random. Hence, by the central limit theorem, with high probability our regret Rk∗ T is of order √ T. On the other side of the spectrum, for κ = 1 (the best case), we do not find a gap. We still have experts arbitrary close to the best expert in mean, but their expected excess loss squared equals their expected excess loss. ERM/FTL (and hence all approaches based on it, such as [Bartlett and Mendelson, 2006]) may fail completely on this type of examples. The clearest case is when {k ∣δk > ϵ} is infinite for some ϵ > 0. Then at any t there will be experts that, by chance, incurred their lower loss every round. Picking any of them will result in expected instantaneous regret at least ϵ2/κ, leading to linear regret overall. The requirement δk = 0 for some k is essential. If instead δk > 0 for all k then there is no best expert in the class. Theorem 19 in Appendix D shows how to deal with this case. 3.3 Hedge Setting: Markov Chains Suppose we model a binary sequence z1,z2,...,zT with m-th order Markov chains. As experts we consider all possible functions f∶{0,1}m →{0,1} that map a history of length m to a prediction for the next outcome, and the loss of expert f is the 0/1-loss: ℓf t = ∣f(zt−m,...,zt−1) −zt∣. (We initialize z1−m = ... = z0 = 0.) A uniform prior on this finite set of 22m experts results in worst-case regret of order √ T2m. Then, if the data are actually generated by an m-th order Markov chain with transition probabilities P(zt = 1 ∣(zt−m,...,zt−1) = a) = pa, we have f ∗(a) = 1{pa ≥1 2} and E[(xf t )2∣(zt−m,...,zt−1) = a] = 1, E[xf t ∣(zt−m,...,zt−1) = a] = 2∣pa −1 2∣ for any f such that f(a) ≠f ∗(a). So the Bernstein condition holds with κ = 1 and B = 1 2 mina ∣pa−1 2 ∣. 3.4 OCO: Hinge Loss on the Unit Ball Let (x1,y1),(x2,y2),... be classification data, with yt ∈{−1,+1} and xt ∈Rd, and consider the hinge loss ℓt(u) = max{0,1 −yt⟨xt,u⟩}. Now suppose, for simplicity, that both xt and u come from the d-dimensional unit Euclidean ball, such that ⟨xt,u⟩∈[−1,+1] and hence the hinge is never active, i.e. ℓt(u) = 1 −yt⟨xt,u⟩. Then, if the data turn out to be i.i.d. observations from a fixed distribution P, the Bernstein condition holds with κ = 1 (the proof can be found in Appendix C): Lemma 4 (Unregularized Hinge Loss Example). Consider the hinge loss setting above, where ∣⟨xt,u⟩∣≤1. If the data are i.i.d., then the (B,κ)-Bernstein condition is satisfied with κ = 1 and B = 2λmax ∥µ∥, where λmax is the maximum eigenvalue of E[xx⊺] and µ = E[yx], provided that ∥µ∥> 0. In particular, if xt is uniformly distributed on the sphere and yt = sign(⟨¯u,xt⟩) is the noiseless classification of xt according to the hyper-plane with normal vector ¯u, then B ≤ c √ d for some absolute constant c > 0. The excluded case ∥µ∥= 0 only happens in the degenerate case that there is nothing to learn, because µ = 0 implies that the expected hinge loss is 1, its maximal value, for all u. 3.5 OCO: Absolute Loss Let U = [0,1] be the unit interval. Consider the absolute loss ℓt(u) = ∣u −xt∣where xt ∈[0,1] are drawn i.i.d. from P. Let u∗∈arg minu E∣u −x∣minimize the expected loss. In this case we may simplify ⟨w −u∗,∇ℓ(w)⟩= (w −u∗)sign(w −x). To satisfy the Bernstein condition, we therefore want B such that, for all w ∈[0,1], E[((w −u∗)sign(w −x)) 2] ≤B E[(w −u∗)sign(w −x)]κ . That is, ∣w −u∗∣2−κ ≤B2κ∣P(x ≤w) −1 2∣κ. 6 For instance, if the distribution of x has a strictly positive density p(x) ≥m > 0, then u∗is the median and ∣P(x ≤w) −1 2∣= ∣P(x ≤w) −P(x ≤u∗)∣≥m∣w −u∗∣, so the condition holds with κ = 1 and B = 1 2m. Alternatively, for a discrete distribution on two points a and b with probabilities p and 1 −p, the condition holds with κ = 1 and B = 1 ∣2p−1∣, provided that p ≠1 2, as can be seen by bounding ∣w −u∗∣≤1 and ∣P(x ≤w) −1 2∣≥∣p −1 2∣. 4 Proof Ideas This section builds up to prove our main result Theorem 2. We first introduce the handy ESIabbreviation that allows us to reason simultaneously in expectation and with high probability. We then provide two alternative characterizations of the Bernstein condition that are equivalent for bounded losses. Finally, we show how one of these, ESI-Bernstein, combines with individualsequence second-order regret bounds to give rise to Theorem 2. 4.1 Notation: Exponential Stochastic Inequality (ESI, pronounce easy) Definition 5. A random variable X is exponentially stochastically negative, denoted X ⊴0, if E[eX] ≤1. For any η ≥0, we write X ⊴η 0 if ηX ⊴0. For any pair of random variables X and Y , the exponential stochastic inequality (ESI) X ⊴η Y is defined as expressing X −Y ⊴η 0; X ⊴Y is defined as X ⊴1 Y . Lemma 6. Exponential stochastic negativity/inequality has the following useful properties: 1. (Negativity). Let X ⊴0. As the notation suggests X is negative in expectation and with high probability. That is E[X] ≤0 and P{X ≥−lnδ} ≤δ for all δ > 0. 2. (Convex combination). Let {Xf}f∈F be a family of random variables and let w be a probability distribution on F. If Xf ⊴0 for all f then Ef∼w[Xf] ⊴0. 3. (Chain rule). Let X1,X2,... be adapted to filtration G1 ⊆G2 ... (i.e. Xt is Gt-measurable for each t). If Xt∣Gt−1 ⊴0 almost surely for all t, then ∑T t=1 Xt ⊴0 for all T ≥0. Proof. Negativity: By Jensen’s inequality E[X] ≤lnE[eX] ≤0, whereas by Markov’s inequality P{X ≥−lnδ} = P{eX ≥1 δ } ≤δ E[eX] ≤δ. Convex combination: By Jensen’s inequality E[eEf∼w[Xf ]] ≤Ef∼w E[eXf ] ≤1. Chain rule: By induction. The base case T = 0 holds trivially. For T > 0 we have E[e∑T t=1 Xt] = E[e∑T −1 t=1 Xt E[eXT ∣GT −1]] ≤E[e∑T −1 t=1 Xt] ≤1. 4.2 The Bernstein Condition and Second-order Bounds Our main result Theorem 2, bounds the regret Rf ∗ T compared to the stochastically optimal predictor f ∗when the sequence of losses ℓ1,ℓ2,... comes from a Bernstein distribution P. For simplicity we only consider the OCO setting in this sketch. Full details are in Theorem 11. Our starting point will be the individual-sequence second-order bound (2), which implies Rf ∗ T ≤˜Rf ∗ T = O( √ V f ∗ T KT ). The crucial technical contribution of this paper is to establish that for Bernstein distributions V f ∗ T is bounded in terms of ˜Rf ∗ T with high probability. Combination with the individual-sequence bound then gives that ˜Rf ∗ T is bounded in terms of a function of itself. And solving the inequality for ˜Rf ∗ T establishes the fast rates for Rf ∗ T . To get a first intuition as to why V f ∗ T would be bounded in terms of ˜Rf ∗ T , we look at their relation in expectation. Recall that V f ∗ T = ∑T t=1(xft t )2 and ˜Rf ∗ T = ∑T t=1 xft t where ft is the prediction of the algorithm in round t. We will bound (xft t )2 in terms of xft t separately for each round t. The Bernstein Condition 1 for κ = 1 directly yields E[V f ∗ T ] = T ∑ t=1 E[(xft t )2] ≤B T ∑ t=1 E[xft t ] = B E[ ˜Rf ∗ T ]. (4) 7 For κ < 1 the final step of interchanging expectation and sums does not work directly, but we may use zκ = κκ(1 −κ)1−κ infϵ>0 {ϵκ−1z + ϵκ} for z ≥0 to rewrite the Bernstein condition as the following set of linear inequalities: Condition 7. The excess loss family (3) satisfies the linearized κ-Bernstein condition if there are constants c1,c2 > 0 such that we have: c1 ⋅ϵ1−κ ⋅E[(xf t )2∣Gt−1] −E[xf t ∣Gt−1] ≤c2 ⋅ϵ a.s. for all ϵ > 0, f ∈F and t ∈N. This gives the following generalization of (4): c1 ⋅ϵ1−κ E[V f ∗ T ] ≤E[ ˜Rf ∗ T ] + c2 ⋅T ⋅ϵ. (5) Together with the individual sequence regret bound and optimization of ϵ this can be used to derive the in-expectation part of Theorem 2. Getting the in-probability part is more difficult, however, and requires relating V f ∗ T and ˜Rf ∗ T in probability instead of in expectation. Our main technical contribution does exactly this, by showing that the Bernstein condition is in fact equivalent to the following exponential strengthening of Condition 7: Condition 8. The family (3) satisfies the κ-ESI-Bernstein condition if there are c1,c2 > 0 such that: (c1 ⋅ϵ1−κ ⋅(xf t )2 −xf t ) ∣Gt−1 ⊴ϵ1−κ c2 ⋅ϵ a.s. for all ϵ > 0, f ∈F and t ∈N. Condition 8 implies Condition 7 by Jensen’s inequality (see Lemma 6 part 1). The surprising converse is proved in Lemma 9 in the appendix. By telescoping over rounds using the chain rule from Lemma 6, we see that ESI-Bernstein implies the following substantial strengthening of (5): c1 ⋅ϵ1−κ ⋅V f ∗ T −˜Rf ∗ T ⊴ϵ1−κ c2 ⋅T ⋅ϵ a.s. for all ϵ > 0, T ∈N. (6) Now the second-order regret bound (2) can be rewritten, using 2 √ ab = infγ γa + b/γ, as: for every γ > 0 ∶2 ˜Rf ∗ T ≤2 √ V f ∗ T ⋅KT + 2KT ≤γ ⋅V f ∗ T + KT γ + 2KT . Plugging in γ = c1ϵ1−κ we can chain this inequality with (6) to give, for all ϵ > 0, 2 ˜Rf ∗ T ⊴ϵ1−κ ˜Rf ∗ T + c2 ⋅T ⋅ϵ + KT c1 ⋅ϵ1−κ + 2KT , (7) and both parts of Theorem 2 now follow by rearranging, plugging in the minimiser ϵ ≍K 1 2−κ T T 1−κ 2−κ , and using Lemma 6 part 1. Acknowledgments Koolen acknowledges support by the Netherlands Organization for Scientific Research (NWO, Veni grant 639.021.439). References J-Y. Audibert. PAC-Bayesian statistical learning theory. PhD thesis, Université Paris VI, 2004. J-Y. Audibert. Fast learning rates in statistical inference through aggregation. Ann. Stat., 37(4), 2009. P. Bartlett and S. Mendelson. Empirical minimization. Probab. Theory Rel., 135(3):311–334, 2006. P. Bartlett, M. Jordan, and J. McAuliffe. Convexity, classification, and risk bounds. J. Am. Stat. Assoc., 101 (473):138–156, 2006. N. Cesa-Bianchi and G. Lugosi. Prediction, learning, and games. Cambridge University Press, 2006. N. Cesa-Bianchi, Y. Mansour, and G. Stoltz. Improved second-order bounds for prediction with expert advice. Machine Learning, 66(2/3):321–352, 2007. C. Chiang, T. Yang, C. Le, M. Mahdavi, C. Lu, R. Jin, and S. Zhu. Online optimization with gradual variations. In Proc. 25th Conf. on Learning Theory (COLT), 2012. K. Crammer, A. Kulesza, and M. Dredze. Adaptive regularization of weight vectors. In NIPS 22, 2009. 8 J. Duchi, E. Hazan, and Y. Singer. Adaptive subgradient methods for online learning and stochastic optimization. Journal of Machine Learning Research, 12:2121–2159, 2011. T. van Erven and W. Koolen. MetaGrad: Multiple learning rates in online learning. In Advances in Neural Information Processing Systems 29, 2016. T. van Erven, P. Grünwald, N. Mehta, M. Reid, and R. Williamson. Fast rates in statistical and online learning. Journal of Machine Learning Research, 16:1793–1861, 2015. E. Even-Dar, M. Kearns, Y. Mansour, and J. Wortman. Regret to the best vs. regret to the average. Machine Learning, 72(1-2), 2008. Y. Freund and R. Schapire. A decision-theoretic generalization of on-line learning and an application to boosting. Journal of Computer and System Sciences, 55:119–139, 1997. P. Gaillard and S. Gerchinovitz. A chaining algorithm for online nonparametric regression. In Proc. 28th Conf. on Learning Theory (COLT), 2015. P. Gaillard, G. Stoltz, and T. van Erven. A second-order bound with excess losses. In Proc. 27th COLT, 2014. P. Grünwald. The safe Bayesian: learning the learning rate via the mixability gap. In ALT ’12. Springer, 2012. E. Hazan and S. Kale. Extracting certainty from uncertainty: Regret bounded by variation in costs. Machine learning, 80(2-3):165–188, 2010. V. Koltchinskii. Local Rademacher complexities and oracle inequalities in risk minimization. Ann. Stat., 34(6): 2593–2656, 2006. W. Koolen. The relative entropy bound for Squint. Blog entry on blog.wouterkoolen.info/, August 2015. W. Koolen and T. van Erven. Second-order quantile methods for experts and combinatorial games. In Proc. 28th Conf. on Learning Theory (COLT), pages 1155–1175, 2015. W. Koolen, T. van Erven, and P. Grünwald. Learning the learning rate for prediction with expert advice. In Advances in Neural Information Processing Systems 27, pages 2294–2302, 2014. H. Luo and R. Schapire. Achieving all with no parameters: Adaptive normalhedge. In Proc. 28th COLT, 2015. P. Massart and É. Nédélec. Risk bounds for statistical learning. Ann. Stat., 34(5):2326–2366, 2006. B. McMahan and M. Streeter. Adaptive bound optimization for online convex optimization. In Proc. 23rd Conf. on Learning Theory (COLT), pages 244–256, 2010. N. Mehta and R. Williamson. From stochastic mixability to fast rates. In NIPS 27, 2014. F. Orabona, K. Crammer, and N. Cesa-Bianchi. A generalized online mirror descent with applications to classification and regression. Machine Learning, 99(3):411–435, 2015. A. Rakhlin and K. Sridharan. Online nonparametric regression. In Proc. 27th COLT, 2014. S. de Rooij, T. van Erven, P. Grünwald, and W. Koolen. Follow the leader if you can, Hedge if you must. Journal of Machine Learning Research, 15:1281–1316, April 2014. A. Sani, G. Neu, and A. Lazaric. Exploiting easy data in online optimization. In NIPS 27, 2014. S. Shalev-Shwartz. Online learning and online convex optimization. Foundations and Trends in Machine Learning, 4(2):107–194, 2011. J. Steinhardt and P. Liang. Adaptivity and optimism: An improved exponentiated gradient algorithm. In Proc. 31th Int. Conf. on Machine Learning (ICML), pages 1593–1601, 2014. A. Tsybakov. Optimal aggregation of classifiers in statistical learning. Ann. Stat., 32:135–166, 2004. O. Wintenberger. Optimal learning with Bernstein Online Aggregation. ArXiv:1404.1356, 2015. 9 | 2016 | 493 |
6,431 | A Comprehensive Linear Speedup Analysis for Asynchronous Stochastic Parallel Optimization from Zeroth-Order to First-Order Xiangru Lian*, Huan Zhang†, Cho-Jui Hsieh‡, Yijun Huang*, and Ji Liu* ∗Department of Computer Science, University of Rochester, USA † Department of Electrical and Computer Engineering, University of California, Davis, USA ‡ Department of Computer Science, University of California, Davis, USA xiangru@yandex.com, victzhang@gmail.com, chohsieh@ucdavis.edu, huangyj0@gmail.com, ji.liu.uwisc@gmail.com Abstract Asynchronous parallel optimization received substantial successes and extensive attention recently. One of core theoretical questions is how much speedup (or benefit) the asynchronous parallelization can bring to us. This paper provides a comprehensive and generic analysis to study the speedup property for a broad range of asynchronous parallel stochastic algorithms from the zeroth order to the first order methods. Our result recovers or improves existing analysis on special cases, provides more insights for understanding the asynchronous parallel behaviors, and suggests a novel asynchronous parallel zeroth order method for the first time. Our experiments provide novel applications of the proposed asynchronous parallel zeroth order method on hyper parameter tuning and model blending problems. 1 Introduction Asynchronous parallel optimization received substantial successes and extensive attention recently, for example, [5, 25, 31, 33, 34, 37]. It has been used to solve various machine learning problems, such as deep learning [4, 7, 26, 36], matrix completion [25, 28, 34], SVM [15], linear systems [3, 21], PCA [10], and linear programming [32]. Its main advantage over the synchronous parallel optimization is avoiding the synchronization cost, so it minimizes the system overheads and maximizes the efficiency of all computation workers. One of core theoretical questions is how much speedup (or benefit) the asynchronous parallelization can bring to us, that is, how much time can we save by employing more computation resources? More precisely, people are interested in the running time speedup (RTS) with T workers: RTS(T) = running time using a single worker running time using T workers . Since in the asynchronous parallelism all workers keep busy, RTS can be measured roughly by the computational complexity speedup (CCS) with T workers1 CCS(T) = total computational complexity using a single worker total computational complexity using T workers × T. In this paper, we are mainly interested in the conditions to ensure the linear speedup property. More specifically, what is the upper bound on T to ensure CCS(T) = Θ(T)? Existing studies on special cases, such as asynchronous stochastic gradient descent (ASGD) and asynchronous stochastic coordinate descent (ASCD), have revealed some clues for what factors can 1For simplicity, we assume that the communication cost is not dominant throughout this paper. 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. Table 1: Asynchronous parallel algorithms. “I” and “C” in “model” stand for inconsistent and consistent read model respectively, which will be explained later. “Base alg.” is short for base algorithm. Asyn. alg. base alg. problem type upper bound of T model ASGD [25] SGD smooth, strongly convex O(N 1/4) C ASGD [1] SGD smooth, convex O(K1/4 min{σ3/2, σ1/2}) C ASGD[11] SGD composite, convex O(K1/4σ1/2) C ASGD [18] SGD smooth, nonconvex O(N 1/4K1/2σ) I ASGD [18] SGD smooth, nonconvex O(K1/2σ) C ARK [21] SGD Ax = b O(N) C ASCD [20] SCD smooth, convex, unconstrained O(N 1/2) C ASCD [20] SCD smooth, convex, constrained O(N 1/4) C ASCD [19] SCD composite, convex O(N 1/4) I ASCD [3] SCD 1 2xT Ax −bT x O(N) C ASCD [3] SCD 1 2xT Ax −bT x O(N 1/2) I ASCD [15] SCD 1 2xT Ax −bT x , constrained O(N 1/2) I ASZD zeroth order SGD & SCD smooth, nonconvex O( √ N 3/2 + KN 1/2σ2) I ASGD SGD smooth, nonconvex O( √ N 3/2 + KN 1/2σ2) I ASGD SGD smooth, nonconvex O( √ Kσ2 + 1) C ASCD SCD smooth, nonconvex O(N 3/4) I affect the upper bound of T. For example, Agarwal and Duchi [1] showed the upper bound depends on the variance of the stochastic gradient in ASGD; Niu et al. [25] showed that the upper bound depends on the data sparsity and the dimension of the problem in ASGD; and Avron et al. [3], Liu and Wright [19] found that the upper bound depends on the problem dimension as well as the diagonal dominance of the Hessian matrix of the objective. However, it still lacks a comprehensive and generic analysis to comprehend all pieces and show how these factors jointly affect the speedup property. This paper provides a comprehensive and generic analysis to study the speedup property for a broad range of asynchronous parallel stochastic algorithms from the zeroth order to the first order methods. To avoid unnecessary complication and cover practical problems and algorithms, we consider the following nonconvex stochastic optimization problem: minx∈RN f(x) := Eξ(F(x; ξ)), (1) where ξ ∈Ξ is a random variable, and both F(·; ξ) : RN →R and f(·) : RN →R are smooth but not necessarily convex functions. This objective function covers a large scope of machine learning problems including deep learning. F(·; ξ)’s are called component functions in this paper. The most common specification is that Ξ is an index set of all training samples Ξ = {1, 2, · · · , n} and F(x; ξ) is the loss function with respect to the training sample indexed by ξ. We highlight the main contributions of this paper in the following: • We provide a generic analysis for convergence and speedup, which covers many existing algorithms including ASCD, ASGD ( implementation on parameter server), ASGD (implementation on multicore systems), and others as its special cases. • Our generic analysis can recover or improve the existing results on special cases. • Our generic analysis suggests a novel asynchronous stochastic zeroth-order gradient descent (ASZD) algorithm and provides the analysis for its convergence rate and speedup property. To the best of our knowledge, this is the first asynchronous parallel zeroth order algorithm. • The experiment includes a novel application of the proposed ASZD method on model blending and hyper parameter tuning for big data optimization. 1.1 Related Works We first review first-order asynchronous parallel stochastic algorithms. Table 1 summarizes existing linear speedup results for asynchronous parallel optimization algorithms mostly related to this paper. The last block of Table 1 shows the results in this paper. Reddi et al. [29] proved the convergence of asynchronous variance reduced stochastic gradient (SVRG) method and its speedup in sparse setting. Mania et al. [22] provides a general perspective (or starting point) to analyze for asynchronous stochastic algorithms, including HOGWILD!, asynchronous SCD and asynchronous sparse SVRG. The fundamental difference in our work lies on that we apply different analysis and our result can be 2 directly applied to various special cases, while theirs cannot. In addition, there is a line of research studying the asynchronous ADMM type methods, which is not in the scope of this paper. We encourage readers to refer to recent literatures, for example, Hong [14], Zhang and Kwok [35]. We end this section by reviewing the zeroth-order stochastic methods. We use N to denote the dimension of the problem, K to denote the iteration number, and σ to the variance of stochastic gradient. Nesterov and Spokoiny [24] proved a convergence rate of O(N/ √ K) for zeroth-order SGD applied to convex optimization. Based on [24], Ghadimi and Lan [12] proved a convergence rate of O( √ N/K) rate for zeroth-order SGD on nonconvex smooth problems. Jamieson et al. [16] shows a lower bound O(1/ √ K) for any zeroth-order method with inaccurate evaluation. Duchi et al. [9] proved a O(N 1/4/K + 1/ √ K) rate for zeroth order SGD on convex objectives but with some very different assumptions compared to our paper. Agarwal et al. [2] proved a regret of O(poly(N) √ K) for zeroth-order bandit algorithm on convex objectives. For more comprehensive review of asynchronous algorithms, please refer to the long version of this paper on arXiv:1606.00498. 1.2 Notation • ei ∈RN denotes the ith natural unit basis vector. • E(·) means taking the expectation with respect to all random variables, while Ea(·) denotes the expectation with respect to a random variable a. • ∇f(x) ∈RN is the gradient of f(x) with respect to x. Let S be a subset of {1, · · · , N}. ∇Sf(x) ∈RN is the projection of ∇f(x) onto the index set S, that is, setting components of ∇f(x) outside of S to be zero. We use ∇if(x) ∈RN to denote ∇{i}f(x) for short. • f ∗denotes the optimal objective value in (1). 2 Algorithm Algorithm 1 Generic Asynchronous Stochastic Algorithm (GASA) Require: x0, K, Y, (µ1, µ2, . . . , µN), {γk}k=0,...,K−1 ▷ γk is the step length for kth iteration Ensure: {xk}K k=0 1: for k = 0, . . . , K −1 do 2: Randomly select a component function index ξk and a set of coordinate indices Sk, where |Sk| = Y ; 3: xk+1 = xk −γkGSk(ˆxk; ξk); 4: end for We illustrate the asynchronous parallelism by assuming a centralized network: a central node and multiple child nodes (workers). The central node maintains the optimization variable x. It could be a parameter server if implemented on a computer cluster [17]; it could be a shared memory if implemented on a multicore machine. Given a base algorithm A, all child nodes run algorithm A independently and concurrently: read x from the central node (we call the result of this read ˆx, and it is mathematically defined later in (4)), calculate locally using the ˆx, and modify x on the central node. There is no need to synchronize child nodes. Therefore, all child nodes stay busy and consequently their efficiency gets maximized. In other words, we have CCS(T) ≈RTS(T). Note that due to the asynchronous parallel mechanism the variable x in the central node is not updated exactly following the protocol of Algorithm A, since when a child node returns its computation result, the x in the central node might have been changed by other child nodes. Thus a new analysis is required. A fundamental question would be under what conditions a linear speedup can be guaranteed. In other words, under what conditions CCS(T) = Θ(T) or equivalently RTS(T) = Θ(T)? To provide a comprehensive analysis, we consider a generic algorithm A – the zeroth order hybrid of SCD and SGD: iteratively sample a component function2 indexed by ξ and a coordinate block S⊆{1, 2, · · · , N}, where |S| = Y for some constant Y and update x with x ←x −γGS(x; ξ) (2) where GS(x; ξ) is an approximation to the block coordinate stochastic gradient NY −1∇SF(x; ξ): GS(x; ξ) := ∑ i∈S N 2Y µi (F(x + µiei; ξ) −F(x −µiei; ξ))ei, S ⊆{1, 2, . . . , N}. (3) In the definition of GS(x; ξ), µi is the approximation parameter for the ith coordinate. (µ1, µ2, . . . , µN) is predefined in practice. We only use the function value (the zeroth order information) to estimate GS(x; ξ). It is easy to see that the closer to 0 the µi’s are, the closer GS(x; ξ) and NY −1∇Sf(x; ξ) will be. In particular, limµi→0,∀i GS(x; ξ) = NY −1∇Sf(x; ξ). 2The algorithm and theoretical analysis followed can be easily extended to the minibatch version. 3 Applying the asynchronous parallelism, we propose a generic asynchronous stochastic algorithm in Algorithm 1. This algorithm essentially characterizes how the value of x is updated in the central node. γk is the predefined steplength (or learning rate). K is the total number of iterations (note that this iteration number is counted by the the central node, that is, any update on x no matter from which child node will increase this counter.) As we mentioned, the key difference of the asynchronous algorithm from the protocol of Algorithm A in Eq. (2) is that ˆxk may be not equal to xk. In asynchronous parallelism, there are two different ways to model the value of ˆxk: • Consistent read: ˆxk is some early existed state of x in the central node, that is, ˆxk = xk−τk for some τk ≥0. This happens if reading x and writing x on the central node by any child node are atomic operations, for instance, the implementation on a parameter server [17]. • Inconsistent read: ˆxk could be more complicated when the atomic read on x cannot be guaranteed, which could happen, for example, in the implementation on the multi-core system. It means that while one child is reading x in the central node, other child nodes may be performing modifications on x at the same time. Therefore, different coordinates of x read by any child node may have different ages. In other words, ˆxk may not be any existed state of x in the central node. Readers who want to learn more details about consistent read and inconsistent read can refer to [3, 18, 19]. To cover both cases, we note that ˆxk can be represented in the following generic form: ˆxk = xk −∑ j∈J(k)(xj+1 −xj), (4) where J(k) ⊂{k−1, k−2, . . . , k−T} is a subset of the indices of early iterations, and T is the upper bound for staleness. This expression is also considered in [3, 18, 19, 27]. Note that the practical value of T is usually proportional to the number of involved nodes (or workers). Therefore, the total number of workers and the upper bound of the staleness are treated as the same in the following discussion and this notation T is abused for simplicity. 3 Theoretical Analysis Before we show the main results of this paper, let us first make some global assumptions commonly used for the analysis of stochastic algorithms.3 Bounded Variance of Stochastic Gradient Eξ(∥∇F(x; ξ) −∇f(x)∥2) ≤σ2, ∀x. Lipschitzian Gradient The gradient of both the objective and its component functions are Lipschitzian:4 max{∥∇f(x) −∇f(y)∥, ∥∇F(x; ξ) −∇F(y; ξ)∥} ≤L∥x −y∥ ∀x, ∀y, ∀ξ. (5) Under the Lipschitzian gradient assumption, define two more constants Ls and Lmax. Let s be any positive integer bounded by N. Define Ls to be the minimal constant satisfying the following inequality: ∀ξ, ∀x, αiei∀S ⊂{1, 2, ..., N} with |S| ≤s for any z = ∑ i∈S we have: max {∥∇f(x) −∇f (x + z)∥, ∥∇F(x; ξ) −∇F (x + z; ξ)∥} ≤Ls ∥z∥ Define L(i) for i ∈{1, 2, . . . , N} as the minimum constant that satisfies: max{∥∇if(x) −∇if(x + αei)∥, ∥∇iF(x; ξ) −∇iF(x + αei; ξ)∥} ≤L(i)|α|. ∀ξ, ∀x. (6) Define Lmax := maxi∈{1,...,N} L(i). It can be seen that Lmax ≤Ls ≤L. Independence All random variables ξk, Sk for k = 0, 1, · · · , K are independent to each other. Bounded Age Let T be the global bound for delay: J(k)⊆{k −1, . . . , k −T}, ∀k, so |J(k)| ≤T. We define the following global quantities for short notations: ω := (∑N i=1 L2 (i)µ2 i ) /N, α1 := 4 + 4 ( TY + Y 3/2T 2/ √ N ) L2 T /(L2 Y N), α2 := Y/((f(x0) −f ∗)LY N), α3 := (K(Nω + σ2)α2 + 4)L2 Y /L2 T . (7) Next we show our main result in the following theorem: 3Some underlying assumptions such as reading and writing a float number are omitted here. As pointed in [25], these behaviors are guaranteed by most modern architectures. 4Note that the Lipschitz assumption on the component function F(x; ξ)’s can be eliminated when it comes to first order methods (i.e., ω →0) in our following theorems. 4 Theorem 1 (Generic Convergence Rate for GASA). Choose the steplength γk to be a constant γ in Algorithm 1 γ−1 k = γ−1 = 2LY NY −1 (√ α2 1/(K(Nω + σ2)α2 + α1) + √ K(Nω + σ2)α2 ) , ∀k and suppose the age T is bounded by T ≤ √ N 2Y 1/2 (√ 1 + 4Y −1/2N 1/2α3 −1 ) . We have the following convergence rate: ∑K k=0 E∥∇f(xk)∥2 K ⩽ 20 Kα2 + 1 Kα2 ( L2 T L2 Y √ 1 + 4Y −1/2N 1/2α3 −1 √ NY −1 + 11 √ Nω + σ2√ Kα2 ) + Nω. (8) Roughly speaking, the first term on the RHS of (8) is related to SCD; the second term is related to “stochastic” gradient descent; and the last term is due to the zeroth-order approximation. Although this result looks complicated (or may be less elegant), it is capable to capture many important subtle structures, which can be seen by the subsequent discussion. We will show how to recover and improve existing results as well as prove the convergence for new algorithms using Theorem 1. To make the results more interpretable, we use the big-O notation to avoid explicitly writing down all the constant factors, including all L’s, f(x0), and f ∗in the following corollaries. 3.1 Asynchronous Stochastic Coordinate Descent (ASCD) We apply Theorem 1 to study the asynchronous SCD algorithm by taking Y = 1 and σ = 0. Sk = {ik} only contains a single randomly sampled coordinate, and ω = 0 (or equivalently µi = 0, ∀i). The essential updating rule on x is xk+1 = xk −γk∇ikf(ˆxk). Corollary 2 (ASCD). Let ω = 0, σ = 0, and Y = 1 in Algorithm 1 and Theorem 1. If T ⩽ O(N 3/4), (9) the following convergence rate holds: (∑K k=0 E∥∇f(xk)∥2) /K ⩽O(N/K). (10) The proved convergence rate O(N/K) is consistent with the existing analysis of SCD [30] or ASCD for smooth optimization [20]. However, our requirement in (9) to ensure the linear speedup property is better than the one in [20], by improving it from T ≤O(N 1/2) to T ≤O(N 3/4). Mania et al. [22] analyzed ASCD for strongly convex objectives and proved a linear speedup smaller than O(N 1/6), which is also more restrictive than ours. 3.2 Asynchronous Stochastic Gradient Descent (ASGD) ASGD has been widely used to solve deep learning [7, 26, 36], NLP [4, 13], and many other important machine learning problems [25]. There are two typical implementations of ASGD. The first type is to implement on the computer cluster with a parameter sever [1, 17]. The parameter server serves as the central node. It can ensure the atomic read or write of the whole vector x and leads to the following updating rule for x (setting Y = N and µi = 0, ∀i in Algorithm 1): xk+1 = xk −γk∇F(ˆxk; ξk). (11) Note that a single iteration is defined as modifying the whole vector. The other type is to implement on a single computer with multiple cores. In this case, the central node corresponds to the shared memory. Multiple cores (or threads) can access it simultaneously. However, in this model atomic read and write of x cannot be guaranteed. Therefore, for the purpose of analysis, each update on a single coordinate accounts for an iteration. It turns out to be the following updating rule (setting Sk = {ik}, that is, Y = 1, and µi = 0, ∀i in Algorithm 1): xk+1 = xk −γk∇ikF(ˆxk; ξk). (12) Readers can refer to [3, 18, 25] for more details and illustrations for these two implementations. Corollary 3 (ASGD in (11)). Let ω = 0 (or µi = 0, ∀i equivalently) and Y = N in Algorithm 1 and Theorem 1. If T ⩽O (√ Kσ2 + 1 ) , (13) then the following convergence rate holds: (∑K k=0 E∥∇f(xk)∥2) /K ⩽O ( σ/ √ K + 1/K ) . (14) 5 First note that the convergence rate in (14) is tight since it is consistent with the serial (nonparallel) version of SGD [23]. We compare this linear speedup property indicated by (13) with results in [1], [11], and [18]. To ensure such rate, Agarwal and Duchi [1] need T to be bounded by T ≤ O(K1/4 min{σ3/2, √σ}), which is inferior to our result in (13). Feyzmahdavian et al. [11] need T to be bounded by σ1/2K1/4 to achieve the same rate, which is also inferior to our result. Our requirement is consistent with the one in [18]. To the best of our knowledge, it is the best result so far. Corollary 4 (ASGD in (12)). Let ω = 0 (or equivalently, µi = 0, ∀i) and Y = 1 in Algorithm 1 and Theorem 1. If T ⩽O (√ N 3/2 + KN 1/2σ2 ) , (15) then the following convergence rate holds (∑K k=0 E∥∇f(xk)∥2) /K ⩽O (√ N/Kσ + N/K ) . (16) The additional factor N in (16) (comparing to (14)) arises from the different way of counting the iteration. This additional factor also appears in [25] and [18]. We first compare our result with [18], which requires T to be bounded by O( √ KN 1/2σ2). We can see that our requirement in (16) allows a larger value for T, especially when σ is small such that N 3/2 dominates KN 1/2σ2. Next we compare with [25], which assumes that the objective function is strongly convex. Although this is sort of comparing “apple” with “orange”, it is still meaningful if one believes that the strong convexity would not affect the linear speedup property, which is implied by [22]. In [25], the linear speedup is guaranteed if T ≤O(N 1/4) under the assumption that the sparsity of the stochastic gradient is bounded by O(1). In comparison, we do not require the assumption of sparsity for stochastic gradient and have a better dependence on N. Moreover, beyond the improvement over existing analysis in [22] and [18], our analysis provides some interesting insights for asynchronous parallelism. Niu et al. [25] essentially suggests a large problem dimension N is beneficial to the linear speedup, while Lian et al. [18] and many others (for example, Agarwal and Duchi [1], Feyzmahdavian et al. [11]) suggest that a large stochastic variance σ (this often implies the number of samples is large) is beneficial to the linear speedup. Our analysis shows the combo effect of N and σ and shows how they improve the linear speedup jointly. 3.3 Asynchronous Stochastic Zeroth-order Descent (ASZD) We end this section by applying Theorem 1 to generate a novel asynchronous zeroth-order stochastic descent algorithm, by setting the block size Y = 1 (or equivalently Sk = {ik}) in GSk(ˆxk; ξk) GSk(ˆxk; ξk) = G{ik}(ˆxk; ξk) = (F(ˆxk + µikeik; ξk) −F(ˆxk −µikeik; ξk))/(2µik)eik. (17) To the best of our knowledge, this is the first asynchronous algorithm for zeroth-order optimization. Corollary 5 (ASZD). Set Y = 1 and all µi’s to be a constant µ in Algorithm 1. Suppose that µ satisfies µ ⩽O ( 1/ √ K + min {√σ(NK)−1/4, σ/ √ N }) , (18) and T satisfies T ⩽O (√ N 3/2 + KN 1/2σ2 ) . (19) We have the following convergence rate (∑K k=0 E∥∇f(xk)∥2) /K ⩽O ( N/K + √ N/Kσ ) . (20) We firstly note that the convergence rate in (20) is consistent with the rate for the serial (nonparallel) zeroth-order stochastic gradient method in [12]. Then we evaluate this result from two perspectives. First, we consider T = 1, which leads to the serial (non-parallel) zeroth-order stochastic descent. Our result implies a better dependence on µ, comparing with [12].5 To obtain such convergence rate 5Acute readers may notice that our way in (17) to estimate the stochastic gradient is different from the one used in [12]. Our method only estimates a single coordinate gradient of a sampled component function, while Ghadimi and Lan [12] estimate the whole gradient of the sampled component function. Our estimation is more accurate but less aggressive. The proved convergence rate actually improves a small constant in [12]. 6 in (20), Ghadimi and Lan [12] require µ ⩽O ( 1/(N √ K) ) , while our requirement in (18) is much less restrictive. An important insight in our requirement is to suggest the dependence on the variance σ: if the variance σ is large, µ is allowed to be a much larger value. This insight meets the common sense: a large variance means that the stochastic gradient may largely deviate from the true gradient, so we are allowed to choose a large µ to obtain a less exact estimation for the stochastic gradient without affecting the convergence rate. From the practical view of point, it always tends to choose a large value for µ. Recall the zeroth-order method uses the function difference at two different points (e.g., x + µei and x −µei) to estimate the differential. In a practical system (e.g., a concrete control system), there usually exists some system noise while querying the function values. If two points are too close (in other words µ is too small), the obtained function difference is dominated by noise and does not really reflect the function differential. Second, we consider the case T ≥1, which leads to the asynchronous zeroth-order stochastic descent. To the best of our knowledge, this is the first such algorithm. The upper bound for T in (19) essentially indicates the requirement for the linear speedup property. The linear speedup property here also shows that even if Kσ2 is much smaller than 1, we still have O(N 3/4) linear speedup, which shows a fundamental understanding of asynchronous stochastic algorithms that N and σ can improve the linear speedup jointly. 4 Experiment Since the ASCD and various ASGDs have been extensively validated in recent papers. We conduct two experiments to validate the proposed ASZD on in this section. The first part applies ASZD to estimate the parameters for a synthetic black box system. The second part applies ASZD to the model combination for Yahoo Music Recommendation Competition. 4.1 Parameter Optimization for A Black Box We use a deep neural network to simulate a black box system. The optimization variables are the weights associated with a neural network. We choose 5 layers (400/100/50/20/10 nodes) for the neural network with 46380 weights (or parameters) totally. The weights are randomly generated from i.i.d. Gaussian distribution. The output vector is constructed by applying the network to the input vector plus some Gaussian random noise. We use this network to generate 463800 samples. These synthetic samples are used to optimize the weights for the black box. (We pretend not to know the structure and weights of this neural network because it is a black box.) To optimize (estimate) the parameters for this black box, we apply the proposed ASZD method. The experiment is conducted on the machine (Intel Xeon architecture), which has 4 sockets and 10 cores for each socket. We run Algorithm 1 on various numbers of cores from 1 to 32 and the steplength is chosen as γ = 0.1, which is based on the best performance of Algorithm 1 running on 1 core to achieve the precision 10−1 for the objective value. Table 2: CCR and RTS of ASZD for different # of threads (synthetic data). thr-# 1 4 8 12 16 20 24 28 32 CCS 1 3.87 7.91 9.97 14.74 17.86 21.76 26.44 30.86 RTS 1 3.32 6.74 8.48 12.49 15.08 18.52 22.49 26.12 The speedup is reported in Table 2. We observe that the iteration speedup is almost linear while the running time speedup is slightly worse than the iteration speedup. We also draw Figure 1 (see the supplement) to show the curve of the objective value against the number of iterations and running time respectively. 4.2 Asynchronous Parallel Model Combination for Yahoo Music Recommendation Competition In KDD-Cup 2011, teams were challenged to predict user ratings in music given the Yahoo! Music data set [8]. The evaluation criterion is the Root Mean Squared Error (RMSE) of the test data set: RMSE = √∑ (u,i)∈T1(rui −ˆrui)2/|T1|, (21) where (u, i) ∈T1 are all user ratings in Track 1 test data set (6,005,940 ratings), rui is the true rating for user u and item i, and ˆrui is the predicted rating. The winning team from NTU created more than 200 models using different machine learning algorithms [6], including Matrix Factorization, k-NN, Restricted Boltzmann Machines, etc. They blend these models using Neural Network and Binned Linear Regression on the validation data set (4,003,960 ratings) to create a model ensemble to achieve better RMSE. 7 We were able to obtain the predicted ratings of N = 237 individual models on the KDD-Cup test data set from the NTU KDD-Cup team, which is a matrix X with 6,005,940 rows (corresponding to the 6,005,940 test data set samples) and 237 columns. Each element Xij indicates the j-th model’s predicted rating on the i-th Yahoo! Music test data sample. In our experiments, we try to linearly blend the 237 models using information from the test data set. Thus, our variable to optimize is a vector x ∈RN as coefficients of the predicted ratings for each model. To ensure that our linear blending does not over-fit, we further split X randomly into two equal parts, calling them the “validation” set (denoted as A ∈Rn×N) for model blending and the true test set. We define our objective function as RMSE2 of the blended output on the validation set: f(x) = ∥Ax −r∥2/n where r is the corresponding true ratings in the validation set and Ax is the predicted ratings after blending. We assume that we cannot see the entries of r directly, and thus cannot compute the gradient of f(x). In our experiment, we treat f(x) as a blackbox, and the only information we can get from it is its value given a model blending coefficients x. This is similar to submitting a model for KDD-Cup and obtain a leader-board RMSE of the test set; we do not know the actual values of the test set. Then, we apply our ASZD algorithm to minimize f(x) with zero-order information only. Table 3: Comparing RMSEs on test data set with KDD-Cup winner teams NTU (1st) Commendo (2nd) InnerPeace (3rd) Our result RMSE 21.0004 21.0545 21.2335 21.1241 We implement our algorithm using Julia on a 10-core Xeon E7-4680 machine an run our algorithm for the same number of iterations, with different number of threads, and measured the running time speedup (RTS) in Figure 4 (see supplement). Similar to our experiment on neural network blackbox, our algorithm has a almost linear speedup. For completeness, Figure 2 in supplement shows the square root of objective function value (RMSE) against the number of iterations and running time. After about 150 seconds, our algorithm running with 10 threads achieves a RMSE of 21.1241 on our test set. Our results are comparable to KDD-Cup winners, as shown in Table 3. Since our goal is to show the performance of our algorithm, we assume we can “submit” our solution x for unlimited times, which is unreal in a real contest like KDD-Cup. However, even with very few iterations, our algorithm does converge fast to a reasonable small RMSE, as shown in Figure 3. 5 Conclusion In this paper, we provide a generic linear speedup analysis for the zeroth-order and first-order asynchronous parallel algorithms. Our generic analysis can recover or improve the existing results on special cases, such as ASCD, ASGD (parameter implementation), ASGD (multicore implementation). Our generic analysis also suggests a novel ASZD algorithm with guaranteed convergence rate and speedup property. To the best of our knowledge, this is the first asynchronous parallel zeroth order algorithm. The experiment includes a novel application of the proposed ASZD method on model blending and hyper parameter tuning for big data optimization. Acknowledgements This project is in part supported by the NSF grant CNS-1548078. We especially thank Chen-Tse Tsai for providing the code and data for the Yahoo Music Competition. References [1] A. Agarwal and J. C. Duchi. Distributed delayed stochastic optimization. NIPS, 2011. [2] A. Agarwal, D. P. Foster, D. J. Hsu, S. M. Kakade, and A. Rakhlin. Stochastic convex optimization with bandit feedback. In NIPS, pages 1035–1043, 2011. [3] H. Avron, A. Druinsky, and A. Gupta. Revisiting asynchronous linear solvers: Provable convergence rate through randomization. Journal of the ACM (JACM), 62(6):51, 2015. [4] Y. Bengio, R. Ducharme, P. Vincent, and C. Janvin. A neural probabilistic language model. The Journal of Machine Learning Research, 3:1137–1155, 2003. [5] S. Chaturapruek, J. C. Duchi, and C. Ré. Asynchronous stochastic convex optimization: the noise is in the noise and SGD don’t care. In NIPS, pages 1531–1539, 2015. [6] P.-L. Chen, C.-T. Tsai, Y.-N. Chen, K.-C. Chou, C.-L. Li, C.-H. Tsai, K.-W. Wu, Y.-C. Chou, C.-Y. Li, W.-S. Lin, et al. A linear ensemble of individual and blended models for music rating prediction. In KDDCup, 2012. [7] J. Dean, G. Corrado, R. Monga, K. Chen, M. Devin, M. Mao, A. Senior, P. Tucker, K. Yang, Q. V. Le, et al. Large scale distributed deep networks. NIPS, 2012. 8 [8] G. Dror, N. Koenigstein, Y. Koren, and M. Weimer. The Yahoo! Music dataset and KDD-Cup’11. In KDDCup, pages 8–18, 2012. [9] J. C. Duchi, P. L. Bartlett, and M. J. Wainwright. Randomized smoothing for stochastic optimization. SIAM Journal on Optimization, 22(2):674–701, 2012. [10] J. Fellus, D. Picard, and P. H. Gosselin. Asynchronous gossip principal components analysis. Neurocomputing, 2015. doi: 10.1016/j.neucom.2014.11.076. [11] H. R. Feyzmahdavian, A. Aytekin, and M. Johansson. An asynchronous mini-batch algorithm for regularized stochastic optimization. arXiv, 2015. [12] S. Ghadimi and G. Lan. Stochastic first-and zeroth-order methods for nonconvex stochastic programming. SIAM Journal on Optimization, 23(4):2341–2368, 2013. [13] K. Gimpel, D. Das, and N. A. Smith. Distributed asynchronous online learning for natural language processing. In CoNLL, pages 213–222, 2010. [14] M. Hong. A distributed, asynchronous and incremental algorithm for nonconvex optimization: An ADMM based approach. arXiv:1412.6058, 2014. [15] C. Hsieh, H. Yu, and I. S. Dhillon. PASSCoDe: Parallel ASynchronous Stochastic dual Co-ordinate Descent. In ICML, pages 2370–2379, 2015. [16] K. G. Jamieson, R. Nowak, and B. Recht. Query complexity of derivative-free optimization. In NIPS, 2012. [17] M. Li, D. G. Andersen, J. W. Park, A. J. Smola, A. Ahmed, V. Josifovski, J. Long, E. J. Shekita, and B.-Y. Su. Scaling distributed machine learning with the parameter server. OSDI, 2014. [18] X. Lian, Y. Huang, Y. Li, and J. Liu. Asynchronous parallel stochastic gradient for nonconvex optimization. In NIPS, pages 2719–2727, 2015. [19] J. Liu and S. J. Wright. Asynchronous stochastic coordinate descent: Parallelism and convergence properties. arXiv:1403.3862, 2014. [20] J. Liu, S. J. Wright, C. Ré, V. Bittorf, and S. Sridhar. An asynchronous parallel stochastic coordinate descent algorithm. ICML, 2014. [21] J. Liu, S. J. Wright, and S. Sridhar. An asynchronous parallel randomized kaczmarz algorithm. arXiv, 2014. [22] H. Mania, X. Pan, D. Papailiopoulos, B. Recht, K. Ramchandran, and M. I. Jordan. Perturbed iterate analysis for asynchronous stochastic optimization. arXiv:1507.06970, 2015. [23] A. Nemirovski, A. Juditsky, G. Lan, and A. Shapiro. Robust stochastic approximation approach to stochastic programming. SIAM Journal on Optimization, 19(4):1574–1609, 2009. [24] Y. Nesterov and V. Spokoiny. Random gradient-free minimization of convex functions. Foundations of Computational Mathematics, pages 1–40, 2011. [25] F. Niu, B. Recht, C. Re, and S. Wright. Hogwild: A lock-free approach to parallelizing stochastic gradient descent. NIPS, 2011. [26] T. Paine, H. Jin, J. Yang, Z. Lin, and T. Huang. Gpu asynchronous stochastic gradient descent to speed up neural network training. NIPS, 2013. [27] Z. Peng, Y. Xu, M. Yan, and W. Yin. Arock: an algorithmic framework for asynchronous parallel coordinate updates. arXiv, 2015. [28] F. Petroni and L. Querzoni. Gasgd: stochastic gradient descent for distributed asynchronous matrix completion via graph partitioning. ACM Conference on Recommender systems, 2014. [29] S. J. Reddi, A. Hefny, S. Sra, B. Póczos, and A. J. Smola. On variance reduction in stochastic gradient descent and its asynchronous variants. In NIPS, pages 2629–2637, 2015. [30] P. Richtárik and M. Takáˇc. Iteration complexity of randomized block-coordinate descent methods for minimizing a composite function. Mathematical Programming, 144(1-2):1–38, 2014. [31] C. D. Sa, C. Zhang, K. Olukotun, C. Ré, and C. Ré. Taming the wild: A unified analysis of hogwild-style algorithms. In NIPS, pages 2674–2682, 2015. [32] S. Sridhar, S. Wright, C. Re, J. Liu, V. Bittorf, and C. Zhang. An approximate, efficient LP solver for lp rounding. NIPS, 2013. [33] J. Wei, W. Dai, A. Kumar, X. Zheng, Q. Ho, and E. P. Xing. Consistent bounded-asynchronous parameter servers for distributed ml. arXiv:1312.7869, 2013. [34] H. Yun, H.-F. Yu, C.-J. Hsieh, S. Vishwanathan, and I. Dhillon. Nomad: Non-locking, stochastic multimachine algorithm for asynchronous and decentralized matrix completion. arXiv:1312.0193, 2013. [35] R. Zhang and J. Kwok. Asynchronous distributed ADMM for consensus optimization. ICML, 2014. [36] S. Zhang, A. Choromanska, and Y. LeCun. Deep learning with elastic averaging SGD. arXiv, 2014. [37] S. Zhao and W. Li. Fast asynchronous parallel stochastic gradient descent: A lock-free approach with convergence guarantee. In AAAI, pages 2379–2385, 2016. 9 | 2016 | 494 |
6,432 | Noise-Tolerant Life-Long Matrix Completion via Adaptive Sampling Maria-Florina Balcan Machine Learning Department Carnegie Mellon University, USA ninamf@cs.cmu.edu Hongyang Zhang Machine Learning Department Carnegie Mellon University, USA hongyanz@cs.cmu.edu Abstract We study the problem of recovering an incomplete m × n matrix of rank r with columns arriving online over time. This is known as the problem of life-long matrix completion, and is widely applied to recommendation system, computer vision, system identification, etc. The challenge is to design provable algorithms tolerant to a large amount of noises, with small sample complexity. In this work, we give algorithms achieving strong guarantee under two realistic noise models. In bounded deterministic noise, an adversary can add any bounded yet unstructured noise to each column. For this problem, we present an algorithm that returns a matrix of a small error, with sample complexity almost as small as the best prior results in the noiseless case. For sparse random noise, where the corrupted columns are sparse and drawn randomly, we give an algorithm that exactly recovers an µ0-incoherent matrix by probability at least 1 −δ with sample complexity as small as O (µ0rn log(r/δ)). This result advances the state-of-the-art work and matches the lower bound in a worst case. We also study the scenario where the hidden matrix lies on a mixture of subspaces and show that the sample complexity can be even smaller. Our proposed algorithms perform well experimentally in both synthetic and real-world datasets. 1 Introduction Life-long learning is an emerging object of study in machine learning, statistics, and many other domains [2, 11]. In machine learning, study of such a framework has led to significant advances in learning systems that continually learn many tasks over time and improve their ability to learn as they do so, like humans [15]. A natural approach to achieve this goal is to exploit information from previously-learned tasks under the belief that some commonalities exist across the tasks [2, 24]. The focus of this work is to apply this idea of life-long learning to the matrix completion problem. That is, given columns of a matrix that arrive online over time with missing entries, how to approximately/exactly recover the underlying matrix by exploiting the low-rank commonality across each column. Our study is motivated by several promising applications where life-long matrix completion is applicable. In recommendation systems, the column of the hidden matrix consists of ratings by multiple users to a specific movie/news; The news or movies are updated online over time but usually only a few ratings are submitted by those users. In computer vision, inferring camera motion from a sequence of online arriving images with missing pixels has received significant attention in recent years, known as the structure-from-motion problem; Recovering those missing pixels from those partial measurements is an important preprocessing step. Other examples where our technique is applicable include system identification, multi-class learning, global positioning of sensors, etc. Despite a large amount of applications of life-long matrix completion, many fundamental questions remain unresolved. One of the long-standing challenges is designing noise-tolerant, life-long 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. algorithms that can recover the unknown target matrix with small error. In the absence of noise, this problem is not easy because the overall structure of the low rankness is unavailable in each round. This problem is even more challenging in the context of noise, where an adversary can add any bounded yet unstructured noise to those observations and the error propagates as the algorithm proceeds. This is known as bounded deterministic noise. Another type of noise model that receives great attention is sparse random noise, where the noise is sparse compared to the number of columns and is drawn i.i.d. from a non-degenerate distribution. Our Contributions: This paper tackles the problem of noise-tolerant, life-long matrix completion and advances the state-of-the-art results under the two realistic noise models. • Under bounded deterministic noise, we design and analyze an algorithm that is robust to noise, with only a small output error (See Figure 3). The sample complexity is almost as small as the best prior results in the noiseless case, provided that the noise level is small. • Under sparse random noise, we give sample complexity that guarantees an exact recovery of the hidden matrix with high probability. The sample complexity advances the state-of-the-art results (See Figure 3) and matches the lower bound in the worst case of this scenario. • We extend our result of sparse random noise to the setting where the columns of the hidden matrix lie on a mixture of subspaces, and show that smaller sample complexity suffices to exactly recover the hidden matrix in this more benign setting. • We also show that our proposed algorithms perform well experimentally in both synthetic and real-world datasets. 2 Preliminaries Before proceeding, we define some notations and clarify problem setup in this section. Notations: We will use bold capital letter to represent matrix, bold lower-case letter to represent vector, and lower-case letter to represent scalar. Specifically, we denote by M ∈Rm×n the noisy observation matrix in hindsight. We denote by L the underlying clean matrix, and by E the noise. We will frequently use M:t ∈Rm×1 to indicate the t-th column of matrix M, and similarly Mt: ∈R1×n the t-th row. For any set of indices Ω, MΩ: ∈R|Ω|×n represents subsampling the rows of M at coordinates Ω. Without confusion, denote by U the column space spanned by the matrix L. Denote by eU the noisy version of U, i.e., the subspace corrupted by the noise, and by bU our estimated subspace. The superscript k of eUk means that eUk has k columns in the current round. PU is frequently used to represent the orthogonal projection operator onto subspace U. We use θ(a, b) to denote the angle between vectors a and b. For a vector u and a subspace V, define θ(u, V) = minv∈V θ(u, v). We define the angle between two subspaces U and V as θ(U, V) = maxu∈U θ(u, V). For norms, denote by ∥v∥2 the vector ℓ2 norm of v. For matrix, ∥M∥2 F = P ij M2 ij and ∥M∥∞,2 = maxi ∥Mi:∥2, i.e., the maximum vector ℓ2 norm across rows. The operator norm is induced by the matrix Frobenius norm, which is defined as ∥P∥= max∥M∥F ≤1 ∥PM∥F . If P can be represented as a matrix, ∥P∥ also denotes the maximum singular value. 2.1 Problem Setup In the setting of life-long matrix completion, we assume that each column of the underlying matrix L is normalized1 and arrives online over time. We are not allowed to get access to the next column until we perform the completion for the current one. This is in sharp contrast to the offline setting where all columns come at one time and so we are able to immediately exploit the low-rank structure to do the completion. In hindsight, we assume the underlying matrix is of rank r. This assumption enables us to represent L as L = US, where U is the dictionary (a.k.a. basis matrix) of size m × r with each column representing a latent metafeature, and S is a matrix of size r × n containing the weights of linear combination for each column L:t. The overall subspace structure is captured by U and the finer grouping structure, e.g., the mixture of multiple subspaces, is captured by the sparsity of S. Our goal is to approximately/exactly recover the subspace U and the matrix L from a small fraction of the entries, possibly corrupted by noise, although these entries can be selected sequentially in a feedback-driven way. Noise Models: We study two types of realistic noise models, one of which is the deterministic noise. In this setting, we assume that the ℓ2 norm of noise on each column is bounded by ϵnoise. Beyond 1Without loss of generality, we assume ∥L:t∥2 = 1 for all t, although our result can be easily extended to the general case. 2 that, no other assumptions are made on the nature of noise. The challenge under this noise model is to design an online algorithm limiting the possible error propagation during the completion procedure. Another noise model we study is the sparse random noise, where we assume that the noise vectors are drawn i.i.d. from any non-degenerate distribution. Additionally, we assume the noise is sparse, i.e., only a few columns of L are corrupted by noise. Our goal is to exactly recover the underlying matrix L with sample complexity as small as possible. Incoherence: Apart from the sample budget and noise level, another quantity governing the difficulty of the completion problem is the coherence parameter on the row/column space. Intuitively, the completion should perform better when the information spreads evenly throughout the matrix. To quantify this term, for subspace U of dimension r in Rm, we define µ(U) = m r max i∈[m] ∥PUei∥2 2, (1) where ei is the i-th column of the identity matrix. Indeed, without (1) there is an identifiability issue in the matrix completion problem [7, 8, 27]. As an extreme example, let L be a matrix with only one non-zero entry. Such a matrix cannot be exactly recovered unless we see the non-zero element. As in [19], to mitigate the issue, in this paper we assume incoherence µ0 = µ(U) on the column space of the underlying matrix. This is in contrast to the classical results of Candès et al. [7, 8], in which one requires incoherence µ0 = max{µ(U), µ(V)} on both the column and the row subspaces. Sampling Model: Instead of sampling the entries passively by uniform distribution, our sampling oracle allows adaptively measuring entries in each round. Specifically, for any arriving column we are allowed to have two types of sampling phases: we can either uniformly take the samples of the entries, as the passive sampling oracle, or choose to request all entries of the column in an adaptive manner. This is a natural extension of the classical passive sampling scheme with wide applications. For example, in network tomography, a network operator is interested in inferring latencies between hosts while injecting few packets into the network. The operator is in control of the network, thus can adaptively sample the matrix of pair-wise latencies. In particular, the operator can request full columns of the matrix by measuring one host to all others. In gene expression analysis, we are interested in recovering a matrix of expression levels for various genes across a number of conditions. The high-throughput microarrays provide expression levels of all genes of interest across operating conditions, corresponding to revealing entire columns of the matrix. 3 Main Results In this section, we formalize our life-long matrix completion algorithm, develop our main theoretical contributions, and compare our results with the prior work. 3.1 Bounded Deterministic Noise To proceed, our algorithm streams the columns of noisy M into memory and iteratively updates the estimate for the column space of L. In particular, the algorithm maintains an estimate bU of subspace U, and when processing an arriving column M:t, requests only a few entries of M:t and a few rows of bU to estimate the distance between L:t and U. If the value of the estimator is greater than a given threshold ηk, the algorithm requests the remaining entries of M:t and adds the new direction M:t to the subspace estimate; Otherwise, finds a best approximation of M:t by a linear combination of columns of bU. The pseudocode of the procedure is displayed in Algorithm 1. We note that our algorithm is similar to the algorithm of [19] for the problem of offline matrix completion without noise. However, our setting, with the presence of noise (which might conceivably propagate through the course of the algorithm), makes our analysis significantly more subtle. The key ingredient of the algorithm is to estimate the distance between the noiseless column L:t and the clean subspace Uk with only a few measurements with noise. To estimate this quantity, we downsample both M:t and bUk to MΩt and bUk Ω:, respectively. We then project MΩt onto subspace bUk Ω: and use the projection residual ∥MΩt −P b Uk Ω:MΩt∥2 as our estimator. A subtle and critical aspect of the algorithm is the choice of the threshold ηk for this estimator. In the noiseless setting, we can simply set ηk = 0 if the sampling number |Ω| is large enough — in the order of O(µ0r log2 r), because O(µ0r log2 r) noiseless measurements already contain enough information for testing whether a specific column lies in a given subspace [19]. In the noisy setting, however, the 3 Algorithm 1 Noise-Tolerant Life-Long Matrix Completion under Bounded Deterministic Noise Input: Columns of matrices arriving over time. Initialize: Let the basis matrix bU0 = ∅. Randomly draw entries Ω⊂[m] of size d uniformly with replacement. 1: For t from 1 to n, do 2: (a) If ∥MΩt −P b Uk Ω:MΩt∥2 > ηk 3: i. Fully measure M:t and add it to the basis matrix bUk. Orthogonalize bUk. 4: ii. Randomly draw entries Ω⊂[m] of size d uniformly with replacement. 5: iii. k := k + 1. 6: (b) Otherwise c M:t := bUk bUk† Ω:MΩt. 7: End For Output: Estimated range space bUK and the underlying matrix c M with column c M:t. challenge is that both M:t and bUk are corrupted by noise, and the error propagates as the algorithm proceeds. Thus instead of setting the threshold as 0 always, our theory suggests setting ηk proportional to the noise level √ϵnoise. Indeed, the threshold ηk balances the trade-off between the estimation error and the sample complexity: a) if ηk is too large, most of the columns are represented by the noisy dictionary and therefore the error propagates too quickly; b) In contrast, if ηk is too small, we observe too many columns in full and so the sample complexity increases. Our goal in this paper is to capture this trade-off, providing a global upper bound on the estimation error of the life-long arriving columns while keeping the sample complexity as small as possible. 3.1.1 Recovery Guarantee Our analysis leads to the following guarantee on the performance of Algorithm 1. Theorem 1 (Robust Recovery under Deterministic Noise). Let r be the rank of the underlying matrix L with µ0-incoherent column space. Suppose that the ℓ2 norm of noise in each column is upper bounded by ϵnoise. Set the parameters d ≥c(µ0r + mkϵnoise) log2(2n/δ)) and ηk = C p dkϵnoise/m for global constants c and C. Then with probability at least 1 −δ, Algorithm 1 outputs bUK with K ≤r and outputs c M with ℓ2 error ∥c M:t −L:t∥2 ≤O m d √kϵnoise 2 uniformly for all t, where k ≤r is the number of base vectors when processing the t-th column. Proof Sketch. We firstly show that our estimated subspace in each round is accurate. The key ingredient of our proof is a result pertaining the angle between the underlying subspace and the noisy one. Ideally, the column space spanned by the noisy dictionary cannot be too far to the underlying subspace if the noise level is small. This is true only if the angle between the newly added vector and the column space of the current dictionary is large, as shown by the following lemma. Lemma 2. Let Uk = span{u1, u2, ..., uk} and eUk = span{eu1, eu2, ..., euk} be two subspaces such that θ(ui, eui) ≤ϵnoise for all i ∈[k]. Let γk = √20kϵnoise and θ(eui, eUi−1) ≥γi for i = 2, ..., k. Then θ(Uk, eUk) ≤γk/2. We then prove the correctness of our test in Step 2. Lemma 2 guarantees that the underlying subspace Uk and our estimated one eUk cannot be too distinct. So by algorithm, projecting any vector on the subspace spanned by eUk does not make too many mistakes, i.e., θ(M:t, eUk) ≈θ(M:t, Uk). On the other hand, by standard concentration argument our test statistic ∥MΩt −P e Uk Ω:MΩt∥2 is close to d m∥M:t −P e UkM:t∥2. Note that the latter term is determined by the angle of θ(M:t, eUk). Therefore, our test statistic in Step 2 is indeed an effective measure of θ(M:t, eUk), or θ(L:t, eUk) since L:t ≈M:t, as proven by the following novel result. Lemma 3. Let ϵk = 2γk, γk = √20kϵnoise, and k ≤r. Suppose that we observe a set of coordinates Ω⊂[m] of size d uniformly at random with replacement, where d ≥c0(µ0r + mkϵnoise) log2(2/δ). If θ(L:t, eUk) ≤ϵk, then with probability at least 1 −4δ, we have ∥MΩt −P e Uk Ω:MΩt∥2 ≤ C p dkϵnoise/m. Inversely, if θ(L:t, eUk) ≥cϵk, then with probability at least 1 −4δ, we have ∥MΩt −P e Uk Ω:MΩt∥2 ≥C p dkϵnoise/m, where c0, c and C are absolute constants. 2By our proof, the constant factor is 9. 4 Finally, as both our dictionary and our statistic are accurate, the output error cannot be too large. A simple deduction on the union bound over all columns leads to Theorem 1. Theorem 1 implies a result in the noiseless setting when ϵnoise goes to zero. Indeed, with the sample size growing in the order of O(µ0nr log2 n), Algorithm 1 outputs a solution that is exact with probability at least 1 − 1 n10 . To the best of our knowledge, this is the best sample complexity in the existing literature for noiseless matrix completion without additional side information [19, 22]. For the noisy setting, Algorithm 1 enjoys the same sample complexity O(µ0nr log2 n) as the noiseless case, if ϵnoise ≤Θ(µ0r/(mk)). In addition, Algorithm 1 inherits the benefits of adaptive sampling scheme. The vast majority results in the passive sampling scenarios require both the row and column incoherence for exact/robust recovery [22]. In contrast, via adaptive sampling we can relax the incoherence assumption on the row space of the underlying matrix and are therefore more applicable. We compare our result with several related lines of research in the prior work. While lots of online matrix completion algorithms have been proposed recently, they either lack of solid theoretical guarantee [17], or require strong assumptions for the streaming data [19, 21, 13, 18]. Specifically, Krishnamurthy et al. [18] proposed an algorithm that requires column subset selection in the noisy case, which might be impractical in the online setting as we cannot measure columns that do not arrive. Focusing on a similar online matrix completion problem, Lois et al. [21] assumed that a) there is a good initial estimate for the column space; b) the column space changes slowly; c) the base vectors of the column space are dense; d) the support of the measurements changes by at least a certain amount. In contrast, our assumptions are much simpler and more realistic. We mention another related line of research — matched subspace detection. The goal of matched subspace detection is to decide whether an incomplete signal/vector lies within a given subspace [5, 4]. It is highly related to the procedure of our algorithm in each round, where we aim at determining whether an arriving vector belongs to a given subspace based on partial and noisy observations. Prior work targeting on this problem formalizes the task as a hypothesis testing problem. So they assume a specific random distribution on the noise, e.g., Gaussian, and choose ηk by fixing the probability of false alarm in the hypothesis testing [5, 23]. Compared with this, our result does not have any assumption on the noise structure/distribution. 3.2 Sparse Random Noise In this section, we discuss life-long matrix completion on a simpler noise model but with a stronger recovery guarantee. We assume that noise is sparse, meaning that the total number of noisy columns is small compared to the total number of columns n. The noisy columns may arrive at any time, and each noisy column is assumed to be drawn i.i.d. from a non-degenerate distribution. Our goal is to exactly recover the underlying matrix and identify the noise with high probability. We use an algorithm similar to Algorithm 1 to attack the problem, with ηk = 0. The challenge is that here we frequently add noise vectors to the dictionary and so we need to distinguish the noise from the clean column and remove them out of the dictionary at the end of the algorithm. To resolve the issue, we additionally record the support of the representation coefficients in each round when we represent the arriving vector by the linear combinations of the columns in the dictionary matrix. On one hand, the noise vectors in the dictionary fail to represent any column, because they are random. So if the representation coefficient corresponding to a column in the dictionary is 0 always, it is convincing to identify the column as a noise. On the other hand, to avoid recognizing a true base vector as a noise, we make a mild assumption that the underlying column space is identifiable. Typically, that means for each direction in the underlying subspace, there are at least two clean data points having non-zero projection on that direction. We argue that the assumption is indispensable, since without it there is an identifiability issue between the clean data and the noise. As an extreme example, we cannot identify the black point in Figures 1 as the clean data or as noise if we make no assumption on the underlying subspace. To mitigate the problem, we assume that for each i ∈[r] and a subspace Ur with orthonormal basis, there are at least two columns L:ai and L:bi of L such that [Ur]T :iL:ai ̸= 0 and [Ur]T :iL:bi ̸= 0. The detailed algorithm can be found in the supplementary material. 3.2.1 Upper Bound We now provide upper and lower bound on the sample complexity of above algorithm for the exact recovery of underlying matrix. Our upper bound matches the lower bound up to a constant factor. We then analyze a more benign setting, namely, the data lie on a mixture of low-rank subspaces with 5 Table 1: Comparisons of our sample complexity with the best prior results in the noise-free setting. Passive Sampling Adaptive Sampling Complexity O µ0nr log2(n/δ) [22] O µ0nr log2(r/δ) [19] O (µ0nr log(r/δ)) (Ours) Lower bound O (µ0nr log(n/δ))[10] O (µ0nr log(r/δ)) (Ours) dimensionality τ ≪r. Our analysis leads to the following guarantee on the performance of above algorithm. The proof is in the supplementary material. Theorem 4 (Exact Recovery under Random Noise). Let r be the rank of the underlying matrix L with µ0-incoherent column space. Suppose that the noise Es0 of size m × s0 are drawn from any non-degenerate distribution, and that the underlying subspace Ur is identifiable. Then our algorithm exactly recovers the underlying matrix L, the column space Ur, and the outlier Es0 with probability at least 1 −δ, provided that d ≥cµ0r log (r/δ) and s0 ≤d −r −1. The total sample complexity is thus cµ0rn log (r/δ), where c is a universal constant. Underlying Subspace (a) Identifiable Subspace Underlying Subspace (b) Unidentifiable Subspace Figure 1: Identifiability. Theorem 4 implies an immediate result in the noise-free setting as ϵnoise goes to zero. In particular, O (µ0nr log(r/δ)) measurements are sufficient so that our algorithm outputs a solution that is exact with probability at least 1 −δ. This sample complexity improves over existing results of O µ0nr log2(n/δ) [22] and O µ0nr3/2 log(r/δ) [18], and over O µ0nr log2(r/δ) of Theorem 1 when ϵnoise = 0. Indeed, our sample complexity O (µ0nr log(r/δ)) matches the lower bound, as shown by Theorem 5 (See Table 1 for comparisons of sample complexity). We notice another paper of Gittens [14] which showed that Nsytr¨om method recovers a positive-semidefinite matrix of rank r from uniformly sampling O(µ0r log(r/δ)) columns. While this result matches our sample complexity, the assumptions of positive-semidefiniteness and of subsampling the columns are impractical in the online setting. We compare Theorem 4 with prior methods on decomposing an incomplete matrix as the sum of a low-rank term and a column-sparse term. Probably one of the best known algorithms is Robust PCA via Outlier Pursuit [25, 28, 27, 26]. Outlier Pursuit converts this problem to a convex program: min L,E ∥L∥∗+ λ∥E∥2,1, s.t. PΩM = PΩ(L + E), (2) where ∥· ∥∗captures the low-rankness of the underlying subspace and ∥· ∥2,1 captures the columnsparsity of the noise. Recent papers on Outlier Pursuit [26] prove that the solution to (2) exactly recovers the underlying subspace, provided that d ≥c1µ2 0r2 log3 n and s0 ≤c2d4n/(µ5 0r5m3 log6 n) for constants c1 and c2. Our result definitely outperforms the existing result in term of the sample complexity d, while our dependence of s0 is not always better (although in some cases better) when n is large. Note that while Outlier Pursuit loads all columns simultaneously and so can exploit the global low-rank structure, our algorithm is online and therefore cannot tolerate too much noise. 3.2.2 Lower Bound We now establish a lower bound on the sample complexity. Our lower bound shows that in our adaptive sampling setting, one needs at least Ω(µ0rn log (r/δ)) many samples in order to uniquely identify a certain matrix in the worst case. This lower bound matches our analysis of upper bound in Section 3.2.1. Theorem 5 (Lower Bound on Sample Complexity). Let 0 < δ < 1/2, and Ω∼Uniform(d) be the index of the row sampling ⊆[m]. Suppose that Ur is µ0-incoherent. If the total sampling number dn < cµ0rn log (r/δ) for a constant c, then with probability at least 1 −δ, there is an example of M such that under the sampling model of Section 2.1 (i.e., when a column arrives the choices are either (a) randomly sample or (b) view the entire column), there exist infinitely many matrices L′ of rank r obeying µ0-incoherent condition on column space such that L′ Ω: = LΩ:. The proof can be found in the supplementary material. We mention several lower bounds on the sample complexity for passive matrix completion. The first is the paper of Candès and Tao [10], that 6 gives a lower bound of Ω(µ0nr log(n/δ)) if the matrix has both incoherent rows and columns. Taking a weaker assumption, Krishnamurthy and Singh [18, 19] showed that if the row space is coherent, any passive sampling scheme followed by any recovery algorithm must have Ω(mn) measurements. In contrast, Theorem 5 demonstrates that in the absence of row-space incoherence, exact recovery of the matrix is possible with only Ω(µ0nr log(r/δ)) samples, if the sampling scheme is adaptive. 3.2.3 Extension to Mixture of Subspaces Hidden Layer Output Layer Underlying Space (a) Single Subspace Subspace 1 Subspace 2 Hidden Layer Output Layer (b) Mixture of Subspaces Figure 2: Subspace structure. Theorem 5 gives a lower bound on sample complexity in the worst case. In this section, we explore the possibility of further reducing the sample complexity with more complex common structure. We assume that the underlying subspace is a mixture of h independent subspaces3 [20], each of which is of dimension at most τ ≪r. Such an assumption naturally models settings in which there are really h different categories of movies/news while they share a certain commonality across categories. We can view this setting as a network with two layers: The first layer captures the overall subspace with r metafeatures; The second layer is an output layer, consisting of metafeatures each of which is a linear combination of only τ metafeatures in the first layer. See Figures 2 for visualization. Our argument shows that the sparse connections between the two layers significantly improve the sample complexity. Algorithmically, given a new column, we uniformly sample ˜O(τ log r) entries as our observations. We try to represent those elements by a sparse linear combination of only τ columns in the basis matrix, whose rows are truncated to those sampled indices; If we fail, we measure the column in full, add that column into the dictionary, and repeat the procedure for the next arriving column. See supplementary material for the detailed algorithm. Regarding computational considerations, learning a τ-sparse representation of a given vector w.r.t. a known dictionary can be done in polynomial time if the dictionary matrix satisfies the restricted isometry property [9], or trivially if τ is a constant [2]. This can be done by applying ℓ1 minimization or brute-force algorithm, respectively. Indeed, many real datasets match the constant-τ assumption, e.g., face image [6] (each person lies on a subspace of dimension τ = 9), 3D motion trajectory [12] (each object lies on a subspace of dimension τ = 4), handwritten digits [16] (each script lies on a subspace of dimension τ = 12), etc. So our algorithm is applicable for all these settings. Theoretically, the following theorem provides a strong guarantee for our algorithm. The proof can be found in the supplementary material. Theorem 6 (Mixture of Subspaces). Let r be the rank of the underlying matrix L. Suppose that the columns of L lie on a mixture of identifiable and independent subspaces, each of which is of dimension at most τ. Denote by µτ the maximal incoherence over all τ-combinations of L. Let the noise model be that of Theorem 4. Then our algorithm exactly recovers the underlying matrix L, the column space Ur, and the outlier Es0 with probability at least 1 −δ, provided that d ≥cµττ 2 log (r/δ) for some global constant c and s0 ≤d −τ −1. The total sample complexity is thus cµττ 2n log (r/δ). As a concrete example, if the incoherence parameter µτ is a global constant and the dimension τ of each subspace is far less than r, the sample complexity of O(µτnτ 2 log(r/δ)) is significantly better than the complexity of O(µ0nr log(r/δ)) for the structure of a single subspace in Theorem 4. This argument shows that the sparse connections between the two layers improve the sample complexity. 4 Experimental Results Bounded Deterministic Noise: We verify the estimated error of our algorithm in Theorem 1 under bounded deterministic noise. Our synthetic data are generated as follows. We construct 5 base vectors {ui}5 i=1 by sampling their entries from N(0, 1). The underlying matrix L is then generated by L = h u11T 200, P2 i=1 ui1T 200, P3 i=1 ui1T 200, P4 i=1 ui1T 200, P5 i=1 ui1T 1,200 i ∈R100×2,000, each column of which is normalized to the unit ℓ2 norm. Finally, we add bounded yet unstructured noise to each column, with noise level ϵnoise = 0.6. We randomly pick 20% entries to be unobserved. The left figure in Figure 3 shows the comparison between our estimated error4 and the true error by our 3h linear subspaces are independent if the dimensionality of their sum is equal to the sum of their dimensions. 4The estimated error is up to a constant factor. 7 Column Index 0 200 400 600 800 1000 1200 1400 1600 1800 2000 Error 0 0.2 0.4 0.6 0.8 1 1.2 1.4 1.6 1.8 2 Error by Algorithm Estimated Error 50#500 Rank/m 0.2 0.4 0.6 0.8 1 Observations/m 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1 100#1000 Rank/m 0.2 0.4 0.6 0.8 1 Observations/m 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1 Figure 3: Left Figure: Approximate recovery under bounded deterministic noise with estimated error. Right Two Figures: Exact recovery under sparse random noise with varying rank and sample size. White Region: Nuclear norm minimization (passive sampling) succeeds. White and Gray Regions: Our algorithm (adaptive sampling) succeeds. Black Region: Our algorithm fails. It shows that the success region of our algorithm strictly contains that of the passive sampling method. algorithm. The result demonstrates that empirically, our estimated error successfully predicts the trend of the true algorithmic error. Sparse Random Noise: We then verify the exact recoverability of our algorithm under sparse random noise. The synthetic data are generated as follows. We construct the underlying matrix L = XY as a product of m × r and r × n i.i.d. N(0, 1) matrices. The sparse random noise is drawn from standard Gaussian distribution such that s0 ≤d −r −1. For each size of problem (50 × 500 and 100× 1, 000), we test with different rank ratios r/m and measurement ratios d/m. The experiment is run by 10 times. We define that the algorithm succeeds if ∥bL −L∥F ≤10−6, rank(bL) = r, and the recovered support of the noise is exact for at least one experiment. The right two figures in Figure 3 plots the fraction of correct recoveries: white denotes perfect recovery by nuclear norm minimization approach (2); white+gray represents perfect recovery by our algorithm; black indicates failure for both methods. It shows that the success region of our algorithm strictly contains that of the prior approach. Moreover, the phase transition of our algorithm is nearly a linear function w.r.t r and d. This is consistent with our prediction d = Ω(µ0r log(r/δ)) when δ is small, e.g., poly(1/n). Mixture of Subspaces: To test the performance of our algorithm for the mixture of subspaces, we conduct an experiment on the Hopkins 155 dataset. The Hopkins 155 database is composed of 155 matrices/tasks, each of which consists of multiple data points drawn from two or three motion objects. The trajectory of each object lie in a subspace. We input the data matrix to our algorithm with varying sample sizes. Table 2 records the average relative error ∥bL −L∥F /∥L∥F of 10 trials for the first five tasks in the dataset. It shows that our algorithm is able to recover the target matrix with high accuracy. Another experiment comparing the sample complexity of single subspace v.s. mixture of subspaces can be found in the supplementary material. Table 2: Life-long Matrix Completion on the first 5 tasks in Hopkins 155 database. #Task Motion Number d = 0.8m d = 0.85m d = 0.9m d = 0.95m #1 2 9.4 × 10−3 6.0 × 10−3 3.4 × 10−3 2.6 × 10−3 #2 3 5.9 × 10−3 4.4 × 10−3 2.4 × 10−3 1.9 × 10−3 #3 2 6.3 × 10−3 4.8 × 10−3 2.8 × 10−3 7.2 × 10−4 #4 2 7.1 × 10−3 6.8 × 10−3 6.1 × 10−3 1.5 × 10−3 #5 2 8.7 × 10−3 5.8 × 10−3 3.1 × 10−3 1.2 × 10−3 5 Conclusions In this paper, we study life-long matrix completion that aims at online recovering an m × n matrix of rank r under two realistic noise models — bounded deterministic noise and sparse random noise. Our result advances the state-of-the-art work and matches the lower bound under sparse random noise. In a more benign setting where the columns of the underlying matrix lie on a mixture of subspaces, we show that a smaller sample complexity is possible to exactly recover the target matrix. It would be interesting to extend our results to other realistic noise models, including random classification noise or malicious noise previously studied in the context of supervised classification [1, 3] Acknowledgements. This work was supported in part by grants NSF-CCF 1535967, NSF CCF1422910, NSF CCF-1451177, a Sloan Fellowship, and a Microsoft Research Fellowship. 8 References [1] P. Awasthi, M. F. Balcan, and P. M. Long. The power of localization for efficiently learning linear separators with noise. In ACM Symposium on Theory of Computing, pages 449–458. ACM, 2014. [2] M.-F. Balcan, A. Blum, and S. Vempala. Efficient representations for life-long learning and autoencoding. In Annual Conference on Learning Theory, 2015. [3] M.-F. F. Balcan and V. Feldman. Statistical active learning algorithms. In Advances in Neural Information Processing Systems, pages 1295–1303, 2013. [4] L. Balzano, R. Nowak, and B. Recht. Online identification and tracking of subspaces from highly incomplete information. In Annual Allerton Conference on Communication, Control, and Computing, pages 704–711, 2010. [5] L. Balzano, B. Recht, and R. Nowak. High-dimensional matched subspace detection when data are missing. In IEEE International Symposium on Information Theory, pages 1638–1642, 2010. [6] R. Basri and D. W. Jacobs. Lambertian reflectance and linear subspaces. IEEE Transactions on Pattern Analysis and Machine Intelligence, 25(2):218–233, 2003. [7] E. J. Candès and Y. Plan. Matrix completion with noise. Proceedings of the IEEE, 98(6):925– 936, 2010. [8] E. J. Candès and B. Recht. Exact matrix completion via convex optimization. Foundations of Computational Mathematics, 9(6):717–772, 2009. [9] E. J. Candès, J. Romberg, and T. Tao. Robust uncertainty principles: Exact signal reconstruction from highly incomplete frequency information. IEEE Transactions on Information Theory, 52(2):489–509, 2006. [10] E. J. Candès and T. Tao. The power of convex relaxation: Near-optimal matrix completion. IEEE Transactions on Information Theory, 56(5):2053–2080, 2010. [11] A. Carlson, J. Betteridge, B. Kisiel, B. Settles, E. R. H. Jr., and T. M. Mitchell. Toward an architecture for never-ending language learning. In AAAI Conference on Artificial Intelligence, 2010. [12] J. Costeira and T. Kanade. A multibody factorization method for independently moving objects. International Journal of Computer Vision, 29(3):159–179, 1998. [13] C. Dhanjal, R. Gaudel, and S. Clémencon. Online matrix completion through nuclear norm regularisation. In SIAM International Conference on Data Mining, pages 623–631, 2014. [14] A. Gittens. The spectral norm error of the naïve Nyström extension. arXiv preprint arXiv:1110.5305, 2011. [15] A. Gopnik, A. N. Meltzoff, and P. K. Kuhl. How babies think: the science of childhood. Phoenix, 2001. [16] T. Hastie and P. Y. Simard. Metrics and models for handwritten character recognition. Statistical Science, pages 54–65, 1998. [17] R. Kennedy, C. J. Taylor, and L. Balzano. Online completion of ill-conditioned low-rank matrices. In IEEE Global Conference on Signal and Information, pages 507–511, 2014. [18] A. Krishnamurthy and A. Singh. Low-rank matrix and tensor completion via adaptive sampling. In Advances in Neural Information Processing Systems, pages 836–844, 2013. [19] A. Krishnamurthy and A. Singh. On the power of adaptivity in matrix completion and approximation. arXiv preprint arXiv:1407.3619, 2014. [20] G. Lerman and T. Zhang. ℓp-recovery of the most significant subspace among multiple subspaces with outliers. Constructive Approximation, 40(3):329–385, 2014. [21] B. Lois and N. Vaswani. Online matrix completion and online robust PCA. In IEEE International Symposium on Information Theory, pages 1826–1830, 2015. [22] B. Recht. A simpler approach to matrix completion. Journal of Machine Learning Research, 12:3413–3430, 2011. [23] L. L. Scharf and B. Friedlander. Matched subspace detectors. IEEE Transactions on Signal Processing, 42(8):2146–2157, 1994. [24] M. K. Warmuth and D. Kuzmin. Randomized online pca algorithms with regret bounds that are logarithmic in the dimension. Journal of Machine Learning Research, 9(10):2287–2320, 2008. [25] H. Xu, C. Caramanis, and S. Sanghavi. Robust PCA via outlier pursuit. IEEE Transaction on Information Theory, 58(5):3047–3064, 2012. [26] H. Zhang, Z. Lin, and C. Zhang. Completing low-rank matrices with corrupted samples from few coefficients in general basis. IEEE Transactions on Information Theory, 62(8):4748–4768, 2016. [27] H. Zhang, Z. Lin, C. Zhang, and E. Chang. Exact recoverability of robust PCA via outlier pursuit with tight recovery bounds. In AAAI Conference on Artificial Intelligence, pages 3143–3149, 2015. [28] H. Zhang, Z. Lin, C. Zhang, and J. Gao. Relations among some low rank subspace recovery models. Neural Computation, 27:1915–1950, 2015. 9 | 2016 | 495 |
6,433 | Satisfying Real-world Goals with Dataset Constraints Gabriel Goh Dept. of Mathematics UC Davis Davis, CA 95616 ggoh@math.ucdavis.edu Andrew Cotter, Maya Gupta Google Inc. 1600 Amphitheatre Parkway Mountain View, CA 94043 acotter@google.com mayagupta@google.com Michael Friedlander Dept. of Computer Science University of British Columbia Vancouver, B.C. V6T 1Z4 mpf@cs.ubc.ca Abstract The goal of minimizing misclassification error on a training set is often just one of several real-world goals that might be defined on different datasets. For example, one may require a classifier to also make positive predictions at some specified rate for some subpopulation (fairness), or to achieve a specified empirical recall. Other real-world goals include reducing churn with respect to a previously deployed model, or stabilizing online training. In this paper we propose handling multiple goals on multiple datasets by training with dataset constraints, using the ramp penalty to accurately quantify costs, and present an efficient algorithm to approximately optimize the resulting non-convex constrained optimization problem. Experiments on both benchmark and real-world industry datasets demonstrate the effectiveness of our approach. 1 Real-world goals We consider a broad set of design goals important for making classifiers work well in real-world applications, and discuss how metrics quantifying many of these goals can be represented in a particular optimization framework. The key theme is that these metrics, which range from the standard precision and recall, to less well-known examples such as coverage and fairness [17, 27, 15], and including some new proposals, can be expressed in terms of the positive and negative classification rates on multiple datasets. Coverage: One may wish to control how often a classifier predicts the positive (or negative) class. For example, one may want to ensure that only 10% of customers are selected to receive a printed catalog due to budget constraints, or perhaps to compensate for a biased training set. In practice, constraining the “coverage rate” (the expected proportion of positive predictions) is often easier than measuring e.g. accuracy or precision because coverage can be computed on unlabeled data—labeling data can be expensive, but acquiring a large number of unlabeled examples is often very easy. Coverage was also considered by Mann and McCallum [17], who proposed what they call “label regularization”, in which one adds a regularizer penalizing the relative entropy between the mean score for each class and the desired distribution, with an additional correction to avoid degeneracies. Churn: Work does not stop once a machine learning model has been adopted. There will be new training data, improved features, and potentially new model structures. Hence, in practice, one will deploy a series of models, each improving slightly upon the last. In this setting, determining whether each candidate should be deployed is surprisingly challenging: if we evaluate on the same held-out testing set every time a new candidate is proposed, and deploy it if it outperforms its predecessor, then every compare-and-deploy decision will increase the statistical dependence between the deployed model and the testing dataset, causing the model sequence to fit the originally-independent testing data. This problem is magnified if, as is typical, the candidate models tend to disagree only on a relatively small number of examples near the true decision boundary. 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. A simple and safe solution is to draw a fresh testing sample every time one wishes to compare two models in the sequence, only considering examples on which the two models disagree. Because labeling data is expensive, one would like these freshly sampled testing datasets to be as small as possible. It is here that the problem of “churn” arises. Imagine that model A, our deployed model, is 70% accurate, and that model B, our candidate, is 75% accurate. In the best case, only 5% of test samples would be labeled differently, and all differences would be “wins” for classifier B. Then only a dozen or so examples would need to be labeled in order to establish that B is the statistically significantly better classifier with 95% confidence. In the worst case, model A would be correct and model B incorrect 25% of the time, model B correct and model A incorrect 30% of the time, and both models correct the remaining 45% of the time. Then 55% of testing examples will be labeled differently, and closer to 1000 examples would need to be labeled to determine that model B is better. We define the “churn rate” as the expected proportion of examples on which the prediction of the model being considered (model B above) differs from that of the currently-deployed model (model A). During training, we propose constraining the empirical churn rate with respect to a given deployed model on a large unlabeled dataset (see also Fard et al. [12] for an alternative approach). Stability: A special case of minimizing churn is to ensure stability of an online classifier as it evolves, by constraining it to not deviate too far from a trusted classifier on a large held-out unlabeled dataset. Fairness: A practitioner may be required to guarantee fairness of a learned classifier, in the sense that it makes positive predictions on different subgroups at certain rates. For example, one might require that housing loans be given equally to people of different genders. Hardt et al. [15] identify three types of fairness: (i) demographic parity, in which positive predictions are made at the same rate on each subgroup, (ii) equal opportunity, in which only the true positive rates must match, and (iii) equalized odds, in which both the true positive rates and false positive rates must match. Fairness can also be specified by a proportion, such as the 80% rule in US law that certain decisions must be in favor of group B individuals at least 80% as often as group A individuals [e.g. 3, 26, 27, 15]. Zafar et al. [27] propose learning fair classifiers by imposing linear constraints on the covariance between the predicted labels and the values of certain features, while Hardt et al. [15] propose first learning an “unfair” classifier, and then choosing population-dependent thresholds to satisfy the desired fairness criterion. In our framework, rate constraints such as those mentioned above can be imposed directly, at training time. Recall and Precision: Requirements of real-world classifiers are often expressed in terms of precision and recall, especially when examples are highly imbalanced between positives and negatives. In our framework, we can handle this problem via Neyman-Pearson classification [e.g. 23, 9], in which one seeks to minimize the false negative rate subject to a constraint on the false positive rate. Indeed, our ramp-loss formulation is equivalent to that of Gasso et al. [13] in this setting. Egregious Examples: For certain classification applications, examples may be discovered that are particularly embarrassing if classified incorrectly. One standard approach to handling such examples is to increase their weights during training, but this is difficult to get right: too large a weight may distort the classifier too much in the surrounding feature space, whereas too small a weight may not fix the problem. Worse, over time the dataset will often be augmented with new training examples and new features, causing the ideal weights to drift. We propose instead simply adding a constraint ensuring that some proportion of a set of such egregious examples is correctly classified. Such constraints should be used with extreme care, since they can cause the problem to become infeasible. 2 Optimization problem A key aspect of many of the goals of Section 1 is that they are defined on different datasets. For example, we might seek to maximize the accuracy on a set of labeled examples drawn in some biased manner, require that its recall be at least 90% on 50 small datasets sampled in an unbiased manner from 50 different countries, desire low churn relative to a deployed classifier on a large unbiased unlabeled dataset, and require that 100 given egregious examples be classified correctly. Another characteristic common to the metrics of Section 1 is that they can be expressed in terms of the positive and negative classification rates on various datasets. We consider only unlabeled datasets, as described in Table 1—a dataset with binary labels, for example, would be handled by partitioning it into the two unlabeled datasets D+ and D−containing the positive and negative examples, 2 Table 1: Dataset notation. Notation Dataset D Any dataset D+, D− Sets of examples labeled positive/negative, respectively D++, D+−, D−+, D−− Sets of examples with ground-truth positive/negative labels, and for which a baseline classifier makes positive/negative predictions DA, DB Sets of examples belonging to subpopulation A and B, respectively Table 2: The quantities discussed in Section 1, expressed in the notation used in Problem 1, with the dependence on w and b dropped for notational simplicity, and using the dataset notation of Table 1. Metric Expression Coverage rate sp (D) #TP, #TN, #FP, #FN |D+| sp (D+), |D−| sn (D−), |D−| sp (D−), |D+| sn (D+) #Errors #FP + #FN Error rate #Errors/ (|D+| + |D−|) Recall #TP/ (#TP + #FN) = #TP/ |D+| #Changes |D+−| sp (D+−) + |D−+| sn (D−+) + |D+−| sp (D+−) + |D−+| sn (D−+) Churn rate #Changes/ (|D++| + |D+−| + |D−+| + |D−−|) Fairness constraint sp DA ≥κsp DB , where κ > 0 Equal opportunity constraint sp DA ∩D+ ≥κsp DB ∩D+ , where κ > 0 Egregious example constraint sp (D+) ≥κ and/or sn (D−) ≤κ for a dataset D of egregious examples, where κ ∈[0, 1] respectively. We wish to learn a linear classification function f(x) = ⟨w, x⟩−b parameterized by a weight vector w ∈Rd and bias b ∈R, for which the positive and negative classification rates are: sp (D; w, b) = 1 |D| P x∈D1 (⟨w, x⟩−b) , sn (D; w, b) = sp (D; −w, −b) , (1) where 1 is an indicator function that is 1 if its argument is positive, 0 otherwise. In words, sp(D; w, b) and sn(D; w, b) denote the proportion of positive or negative predictions, respectively, that f makes on D. Table 2 specifies how the metrics of Section 1 can be expressed in terms of the sps and sns. We propose handling these goals by minimizing an ℓ2-regularized positive linear combination of prediction rates on different datasets, subject to upper-bound constraints on other positive linear combinations of such prediction rates: Problem 1. Starting point: discontinuous constrained problem minimize w∈Rd,b∈R Pk i=1 α(0) i sp(Di; w, b) + β(0) i sn(Di; w, b) + λ 2 ∥w∥2 2 s.t. Pk i=1 α(j) i sp(Di; w, b) + β(j) i sn(Di; w, b) ≤γ(j) j ∈{1, . . . , m}. Here, λ is the parameter on the ℓ2 regularizer, there are k unlabeled datasets D1, . . . , Dk and m constraints. The metrics minimized by the objective and bounded by the constraints are specified via the choices of the nonnegative coefficients α(0) i , β(0) i , α(j) i , β(j) i and upper bounds γ(j) for the ith dataset and, where applicable, the jth constraint—a user should base these choices on Table 2. Note that because sp + sn = 1, it is possible to transform any linear combination of rates into an equivalent positive linear combination, plus a constant (see Appendix B1 for an example). We cannot optimize Problem 1 directly because the rate functions sp and sn are discontinuous. We can, however, work around this difficulty by training a classifier that makes randomized predictions based on the ramp function [7]: σ(z) = max{0, min{1, 1/2 + z}}, (2) 1Appendices may be found in the supplementary material 3 Algorithm 1 Proposed majorization-minimization procedure for (approximately) optimizing Problem 2. Starting from an initial feasible solution w(0), b0, we repeatedly find a convex upper bound problem that is tight at the current candidate solution, and optimize it to yield the next candidate. See Section 2.1 for details, and Section 2.2 for how one can perform the inner optimizations on line 3. MajorizationMinimization w(0), b0, T 1 For t ∈{1, 2, . . . , T} 2 Construct an instance of Problem 3 with w′ = w(t−1) and b′ = bt−1 3 Optimize this convex optimization problem to yield w(t) and bt 4 Return w(t), bt where the randomized classifier parameterized by w and b will make a positive prediction on x with probability σ (⟨w, x⟩−b), and a negative prediction otherwise (see Appendix A for more on this randomized classification rule). For this randomized classifier, the expected positive and negative rates will be: rp (D; w, b) = 1 |D| P x∈Dσ (⟨w, x⟩−b) , rn (D; w, b) = rp (D; −w, −b) . (3) Using these expected rates yields a continuous (but non-convex) analogue of Problem 1: Problem 2. Ramp version of Problem 1 minimize w∈Rd,b∈R Pk i=1 α(0) i rp(Di; w, b) + β(0) i rn(Di; w, b) + λ 2 ∥w∥2 2 s.t. Pk i=1 α(j) i rp(Di; w, b) + β(j) i rn(Di; w, b) ≤γ(j) j ∈{1, . . . , m}. Efficient optimization of this problem is the ultimate goal of this section. In Section 2.1, we will propose a majorization-minimization approach that sequentially minimizes convex upper bounds on Problem 2, and, in Section 2.2, will discuss how these convex upper bounds may themselves be efficiently optimized. 2.1 Optimizing the ramp problem -1 -0.5 0 0.5 1 0 0.5 1 Figure 1: Convex upper bounds on the ramp function σ(z) = max {0, min {1, 1/2 + z}}. Notice that the hinge bound (red) is tight for all z ≤1/2, and the constant bound (blue) is tight for all z ≥1/2. To address the non-convexity of Problem 2, we will iteratively optimize approximations, by, starting from an feasible initial candidate solution, constructing a convex optimization problem upperbounding Problem 2 that is tight at the current candidate, optimizing this convex problem to yield the next candidate, and repeating. Our choice of a ramp for σ makes finding such tight convex upper bounds easy: both the hinge function max {0, 1/2 + z} and constant-1 function are upper bounds on σ, with the former being tight for all z ≤1/2, and the latter for all z ≥1/2 (see Figure 1). We’ll therefore define the following upper bounds on σ and 1 −σ, with the additional parameter z′ determining which of the two bounds (hinge or constant) will be used, such that the bounds will always be tight for z = z′: ˇσp (z; z′) = max {0, 1/2 + z} if z′ ≤1/2 1 otherwise , ˇσn(z; z′) = ˇσp (−z; −z′) . (4) Based upon these we define the following upper bounds on the expected rates: ˇrp (D; w, b; w′, b′) = 1 |D| P x∈D ˇσp (⟨w, x⟩−b; ⟨w′, x⟩−b′) (5) ˇrn (D; w, b; w′, b′) = 1 |D| P x∈D ˇσn (⟨w, x⟩−b; ⟨w′, x⟩−b′) , which have the properties that both ˇrp and ˇrn are convex in w and b, are upper bounds on the original ramp-based rates: ˇrp (D; w, b; w′, b′) ≥rp (D; w, b) and ˇrn (D; w, b; w′, b′) ≥rn (D; w, b) , 4 Algorithm 2 Skeleton of a cutting-plane algorithm that optimizes Equation 6 to within ϵ for v ∈V, where V ⊆Rm is compact and convex. Here, l0, u0 ∈R are finite with l0 ≤maxv∈V ϝ(v) ≤u0. There are several options for the CutChooser function on line 8—please see Appendix E for details. The SVMOptimizer function returns w(t) and bt approximately minimizing Ψ(w, b, v(t); w′, b′), and a lower bound lt ≤ϝ(v) for which ut −lt ≤ϵt for ut as defined on line 10. CuttingPlane (l0, u0, V, ϵ) 1 Initialize g(0) ∈Rm to the all-zero vector 2 For t ∈{1, 2, . . . } 3 Let ht (v) = mins∈{0,1,...,t−1} us + g(s), v −v(s) 4 Let Lt = maxs∈{0,1,...,t−1} ls and Ut = maxv∈V ht (v) 5 If Ut −Lt ≤ϵ then 6 Let s ∈{1, . . . , t −1} be an index maximizing ls 7 Return w(s), bs, v(s) 8 Let v(t), ϵt = CutChooser (ht, Lt) 9 Let w(t), bt, lt = SVMOptimizer v(t), ht v(t) , ϵt 10 Let ut = Ψ(w(t), bt, v(t); w′, b′) and g(t) = ∇vΨ(w(t), bt, v(t); w′, b′) and are tight at w′, b′: ˇrp (D; w′, b′; w′, b′) = rp (D; w′, b′) and ˇrn (D; w′, b′; w′, b′) = rn (D; w′, b′) . Substituting these bounds into Problem 2 yields: Problem 3. Convex upper bound on Problem 2 minimize w∈Rd,b∈R Pk i=1 α(0) i ˇrp (Di; w, b; w′, b′) + β(0) i ˇrn (Di; w, b; w′, b′) + λ 2 ∥w∥2 2 s.t. Pk i=1 α(j) i ˇrp (Di; w, b; w′, b′) + β(j) i ˇrn (Di; w, b; w′, b′) ≤γ(j) j ∈{1, . . . , m}. As desired, this problem upper bounds Problem 2, is tight at w′, b′, and is convex (because any positive linear combination of convex functions is convex). Algorithm 1 contains our proposed procedure for approximately solving Problem 2. Given an initial feasible solution, it’s straightforward to verify inductively, using the fact that we construct tight convex upper bounds at every step, that every convex subproblem will have a feasible solution, every (w(t), bt) pair will be feasible w.r.t. Problem 2, and every (w(t+1), bt+1) will have an objective function value that is no larger that that of (w(t), bt). In other words, no iteration can make negative progress. The non-convexity of Problem 2, however, will cause Algorithm 1 to arrive at a suboptimal solution that depends on the initial (w(0), b0). 2.2 Optimizing the convex subproblems The first step in optimizing Problem 3 is to add Lagrange multipliers v over the constraints, yielding the equivalent unconstrained problem: maximize v⪰0 ϝ(v) = min w,b Ψ (w, b, v; w′, b′) , (6) where the function: Ψ (w, b, v; w′, b′) =Pk i=1 α(0) i + Pm j=1vjα(j) i ˇrp (Di; w, b; w′, b′) (7) + β(0) i + Pm j=1vjβ(j) i ˇrn (Di; w, b; w′, b′) + λ 2 ∥w∥2 2 −Pm j=1vjγ(j) is convex in w and b, and concave in the multipliers v. For the purposes of this section, w′ and b′, which were found in the previous iteration of Algorithm 1, are fixed constants. Because this is a convex-concave saddle point problem, there are a large number of optimization techniques that could be successfully applied. For example, in settings similar to our own, Eban et al. [10] simply perform SGD jointly over all parameters (including v), while Gasso et al. [13] use the Uzawa algorithm, which would alternate between (i) optimizing exactly over w and b, and (ii) taking gradient steps on v. 5 We instead propose an approach for which, in our setting, it is particularly easy to create an efficient implementation. The key insight is that evaluating ϝ(v) is, thanks to our use of hinge and constant upper-bounds on our ramp σ, equivalent to optimization of a support vector machine (SVM) with perexample weights—see Appendix F for details. This observation enables us to solve the saddle system in an inside-out manner. On the “inside”, we optimize over (w, b) for fixed v using an off-the-shelf SVM solver [e.g. 6]. On the “outside”, the resulting (w, b)-optimizer is used as a component in a cutting-plane optimization over v. Notice that this outer optimization is very low-dimensional, since v ∈Rm, where m is the number of constraints. Algorithm 2 contains a skeleton of the cutting-plane algorithm that we use for this outer optimization over v. Because this algorithm is intended to be used as an outer loop in a nested optimization routine, it does not expect that ϝ(v) can be evaluated or differentiated exactly. Rather, it’s based upon the idea of possibly making “shallow” cuts [4] by choosing a desired accuracy ϵt at each iteration, and expecting the SVMOptimizer to return a solution with suboptimality ϵt. More precisely, the SVMOptimizer function approximately evaluates ϝ(v(t)) for a given fixed v(t) by constructing the corresponding SVM problem and finding a (w(t), bt) for which the primal and dual objective function values differ by at most ϵt. After finding (w(t), bt), the SVMOptimizer then evaluates the dual objective function value of the SVM to determine lt. The primal objective function value ut and its gradient g(t) w.r.t. v (calculated on line 10 of Algorithm 2) define the cut ut + g(t), v −v(t) . Notice that since Ψ(w(t), bt, v; w′, b′) is a linear function of v, it is equal to this cut function, which therefore upperbounds minw,b Ψ(w, b, v; w′, b′). One advantage of this cutting-plane formulation is that typical CutChooser implementations will choose ϵt to be large in the early iterations, and will only shrink it to be ϵ or smaller once we’re close to convergence. We leave the details of the analysis to Appendices E and F—a summary can be found in Appendix G. 3 Related work The problem of finding optimal trade-offs in the presence of multiple objectives has been studied generically in the field of multi-objective optimization [18]. Two common approaches are (i) linear scalarization [18, Section 3.1], and (ii) the method of ϵ-constraints [18, Section 3.2]. Linear scalarization reduces to the common heuristic of reweighting groups of examples. The method of ϵ-constraints puts hard bounds on the magnitudes of secondary objectives, like our dataset constraints. Notice that, in our formulation, the Lagrange multipliers v play the role of the weights in the linear scalarization approach, with the difference being that, rather than being provided directly by the user, they are dynamically chosen to satisfy constraints. The user controls the problem through these constraint choices, which have concrete real-world meanings. While the hinge loss is one of the most commonly-used convex upper bounds on the 0/1 loss [22], we use the ramp loss, trading off convexity for tightness. For our purposes, the main disadvantage of the hinge loss is that it is unbounded, and therefore cannot distinguish a single very bad example from say, 10 slightly bad ones, making it ill-suited for constraints on rates. In contrast, for the ramp loss the contribution of any single datum is bounded, no matter how far it is from the decision boundary. The ramp loss has also been investigated in Collobert et al. [7] (without constraints). Gasso et al. [13] use the ramp loss both in the objective and constraints, but their algorithm only tackles the Neyman-Pearson problem. They compared their classifier to that of Davenport et al. [9], which differs in that it uses a hinge relaxation instead of the ramp loss, and found with the ramp loss they achieved similar or slightly better results with up to 10× less computation (our approach does not enjoy this computational speedup). Narasimhan et al. [19] considered optimizing the F-measure and other quantities that can be written as concave functions of the TP and TN rates. Their proposed stochastic dual solver adaptively linearizes concave functions of the rate functions (Equation 1). Joachims [16] indirectly optimizes upper-bounds on functions of sp(D+), sp(D−), sn(D+), sn(D−) using a hinge loss approximation. Finally, for some simple problems (particularly when there is only one constraint), the goals in Section 1 can be coarsely handled by simple bias-shifting, i.e. first training an unconstrained classifier, and then attempting to adjust the decision threshold to satisfy the constraints as a second step. 6 1 2 3 4 5 6 Fairness ratio 0.15 0.16 0.17 0.18 0.19 0.2 Error Rate Proposed (deterministic) Proposed (stochastic) Zafar et al. Figure 2: Blue dots: our proposal, with the classification functions’ predictions being deterministically thresholded at zero. Red dots: same, but using the randomized classification rule described in Section 2. Green dots: Zafar et al. [27]. Green line: unconstrained SVM. (Left) Test set error plotted vs. observed test set fairness ratio sp DM /sp DF . (Right) The 1/κ hyper-parameter used to specify the desired fairness in the proposed method, and the observed fairness ratios of our classifiers on the test data. All points are averaged over 100 runs. 4 Experiments We evaluate the performance of the proposed approach in two experiments, the first using a benchmark dataset for fairness, and the second on a real-world problem with churn and recall constraints. 4.1 Fairness We compare training for fairness on the Adult dataset 2, the same dataset used by Zafar et al. [27]. The 32 561 training and 16 281 testing examples, derived from the 1994 Census, are 123-dimensional and sparse. Each feature contains categorical attributes such as race, gender, education levels and relationship status. A positive class label means that individual’s income exceeds 50k. Let DM and DF denote the sets of male and female examples. The number of positive labels in DM is roughly six times that of DF . The goal is to train a classifier that respects the fairness constraint sp DM ≤sp DF /κ for a parameter κ ∈(0, 1] (where κ = 0.8 corresponds to the 80% rule mentioned in Section 1). Our publicly-available Julia implementation3 for these experiments uses LIBLINEAR [11] with the default parameters (most notably λ = 1/n ≈3 × 10−5) to implement the SVMOptimizer function, and does not include an unregularized bias b. The outer optimization over v does not use the m-dimensional cutting plane algorithm of Algorithm 2, instead using a simpler one-dimensional variant (observe that these experiments involve only one constraint). The majorization-minimization procedure starts from the all-zeros vector (w(0) in Algorithm 1). We compare to the method of Zafar et al. [27], which proposed handling fairness with the constraint: ⟨w, ¯x⟩≤c, ¯x = DM−1P x∈DM x − DF −1 P x∈DF x. (8) An SVM subject to this constraint (see Appendix D for details), for a range of c values, is our baseline. Results in Figure 2 show the proposed method is much more accurate for any desired fairness, and achieves fairness ratios not reachable with the approach of Zafar et al. [27] for any choice of c. It is also easier to control: the values of c in Zafar et al. [27] do not have a clear interpretation, whereas κ is an effective proxy for the fairness ratio. 4.2 Churn Our second set of experiments demonstrates meeting real-world requirements on a proprietary problem from Google: predicting whether a user interface element should be shown to a user, based 2“a9a” from https://www.csie.ntu.edu.tw/~cjlin/libsvmtools/datasets/binary.html 3https://github.com/gabgoh/svmc.jl 7 0.03 0.04 0.05 0.06 Churn target 0.02 0.03 0.04 0.05 Churn Proposed (deterministic) Proposed (stochastic) Thresholded SVM Testing Training 0.03 0.04 0.05 0.06 Churn target 0.18 0.19 0.2 0.21 0.22 Error rate Figure 3: Blue: our proposal, with the classification functions’ predictions being deterministically thresholded at zero. Red: same, but using the randomized classification rule described in Section 2. Green: unconstrained SVM trained on D1 ∪D2, then thresholded (by shifting the bias b) to satisfy the recall constraint on D2. Dashed and dotted curves denote results on the testing and training datasets, respectively. (Left) Observed churn (vertical axis) vs. the churn target used during training (horizontal axis), on the unlabeled dataset D3. (Right) Empirical error rates (vertical axis) vs. the churn target, on the union D1 ∪D2 of the two labeled datasets. All curves are averaged over 10 runs. on a 31-dimensional vector of informative features, which is mapped to a roughly 30 000-dimensional feature vector via a fixed kernel function Φ. We train classifiers that are linear with respect to Φ(x). We are given the currently-deployed model, and seek to train a classifier that (i) has high accuracy, (ii) has no worse recall than the deployed model, and (iii) has low churn w.r.t. the deployed model. We are given three datasets, D1, D2 and D3, consisting of 131 840, 53 877 and 68 892 examples, respectively. The datasets D1 and D2 are hand-labeled, while D3 is unlabeled. In addition, D1 was chosen via active sampling, while D2 and D3 are sampled i.i.d. from the underlying data distribution. For all three datasets, we split out 80% for training and reserved 20% for testing. We address the three goals in the proposed framework by simultaneously training the classifier to minimize the number of errors on D1 plus the number of false positives on D2, subject to the constraints that the recall on D2 be at least as high as the deployed model’s recall (we’re essentially performing Neyman-Pearson classification on D2), and that the churn w.r.t. the deployed model on D3 be no larger than a given target parameter. These experiments use a proprietary C++ implementation of Algorithm 2, using the combined SDCA and cutting plane approach of Appendix F to implement the inner optimizations over w and b, with the CutChooser helper functions being as described in Appendices E.1 and F.2.1. We performed 5 iterations of the majorization-minimization procedure of Algorithm 1. Our baseline is an unconstrained SVM that is thresholded after training to achieve the desired recall, but makes no effort to minimize churn. We chose the regularization parameter λ using a power-of-10 grid search, found that 10−7 was best for this baseline, and then used λ = 10−7 for all experiments. The plots in Figure 3 show the achieved churn and error rates on the training and testing sets for a range of churn constraint values (red and blue curves), compared to the baseline thresholded SVM (green lines). When using deterministic thresholding of the learned classifier (the blue curves, which significantly outperformed randomized classification–the red curves), the proposed method achieves lower churn and better accuracy for all targeted churn rates, while also meeting the recall constraint. As expected, the empirical churn is extremely close to the targeted churn on the training set when using randomized classification (red dotted curve, left plot), but less so on the 20% held-out test set (red dashed curve). We hypothesize this disparity is due to overfitting, as the classifier has 30 000 parameters, and D3 is rather small (please see Appendix C for a discussion of the generalization performance of our approach). However, except for the lowest targeted churn, the actual classifier churn (blue dashed curves) is substantially lower than the targeted churn. Compared to the thresholded SVM baseline, our approach significantly reduces churn without paying an accuracy cost. 8 References [1] K. Ball. An elementary introduction to modern convex geometry. Flavors of Geometry, 31: 1–58, 1997. [2] P. L. Bartlett and S. Mendelson. Rademacher and Gaussian complexities: Risk bounds and structural results. JMLR, 3:463–482, 2002. [3] D. Biddle. Adverse Impact and Test Validation: A Practitioner’s Guide to Valid and Defensible Employment Testing. Gower, 2005. [4] R. G. Bland, D. Goldfarb, and M. J. Todd. Feature article—the ellipsoid method: A survey. Operations Research, 29(6):1039–1091, November 1981. [5] S. Boyd and L. Vandenberghe. Localization and cutting-plane methods, April 2011. Stanford EE 364b lecture notes. [6] C.-C. Chang and C.-J. Lin. LIBSVM: A library for support vector machines. ACM Transactions on Intelligent Systems and Technology, 2:27:1–27:27, 2011. Software available at http: //www.csie.ntu.edu.tw/~cjlin/libsvm. [7] R. Collobert, F. Sinz, J. Weston, and L. Bottou. Trading convexity for scalability. In ICML, 2006. [8] A. Cotter, S. Shalev-Shwartz, and N. Srebro. Learning optimally sparse support vector machines. In ICML, pages 266–274, 2013. [9] M. Davenport, R. G. Baraniuk, and C. D. Scott. Tuning support vector machines for minimax and Neyman-Pearson classification. IEEE Transactions on Pattern Analysis and Machine Intelligence, 2010. [10] E. E. Eban, M. Schain, A. Gordon, R. A. Saurous, and G. Elidan. Large-scale learning with global non-decomposable objectives, 2016. URL https://arxiv.org/abs/1608.04802. [11] R.-E. Fan, K.-W. Chang, C.-J. Hsieh, X.-R. Wang, and C.-J. Lin. LIBLINEAR: A library for large linear classification. JMLR, 9:1871–1874, 2008. [12] M. M. Fard, Q. Cormier, K. Canini, and M. Gupta. Launch and iterate: Reducing prediction churn. In NIPS, 2016. [13] G. Gasso, A. Pappaionannou, M. Spivak, and L. Bottou. Batch and online learning algorithms for nonconvex Neyman-Pearson classification. ACM Transactions on Intelligent Systems and Technology, 2011. [14] B. Grünbaum. Partitions of mass-distributions and convex bodies by hyperplanes. Pacific Journal of Mathematics, 10(4):1257–1261, December 1960. [15] M. Hardt, E. Price, and N. Srebro. Equality of opportunity in supervised learning. In NIPS, 2016. [16] T. Joachims. A support vector method for multivariate performance measures. In ICML, 2005. [17] G. S. Mann and A. McCallum. Simple, robust, scalable semi-supervised learning with expectation regularization. In ICML, 2007. [18] K. Miettinen. Nonlinear multiobjective optimization, volume 12. Springer Science & Business Media, 2012. [19] H. Narasimhan, P. Kar, and P. Jain. Optimizing non-decomposable performance measures: a tale of two classes. In ICML, 2015. [20] A. Nemirovski. Lecture notes: Efficient methods in convex programming. 1994. URL http://www2.isye.gatech.edu/~nemirovs/Lect_EMCO.pdf. [21] L. Rademacher. Approximating the centroid is hard. In SoCG, pages 302–305, 2007. [22] R. T. Rockafellar and S. Uryasev. Optimization of conditional value-at-risk. Journal of Risk, 2: 21–42, 2000. [23] C. D. Scott and R. D. Nowak. A Neyman-Pearson approach to statistical learning. IEEE Transactions on Information Theory, 2005. [24] S. Shalev-Shwartz and T. Zhang. Stochastic dual coordinate ascent methods for regularized loss. JMLR, 14(1):567–599, Feb. 2013. [25] S. Shalev-Shwartz, Y. Singer, N. Srebro, and A. Cotter. Pegasos: Primal Estimated sub-GrAdient SOlver for SVM. Mathematical Programming, 127(1):3–30, March 2011. [26] M. S. Vuolo and N. B. Levy. Disparate impact doctrine in fair housing. New York Law Journal, 2013. [27] M. B. Zafar, I. Valera, M. G. Rodriguez, and K. P. Gummadi. Fairness constraints: A mechanism for fair classification. In ICML Workshop on Fairness, Accountability, and Transparency in Machine Learning, 2015. 9 | 2016 | 496 |
6,434 | Launch and Iterate: Reducing Prediction Churn Q. Cormier ENS Lyon 15 parvis René Descartes Lyon, France quentin.cormier@ens-lyon.fr M. Milani Fard, K. Canini, M. R. Gupta Google Inc. 1600 Amphitheatre Parkway Mountain View, CA 94043 {mmilanifard,canini,mayagupta}@google.com Abstract Practical applications of machine learning often involve successive training iterations with changes to features and training examples. Ideally, changes in the output of any new model should only be improvements (wins) over the previous iteration, but in practice the predictions may change neutrally for many examples, resulting in extra net-zero wins and losses, referred to as unnecessary churn. These changes in the predictions are problematic for usability for some applications, and make it harder and more expensive to measure if a change is statistically significant positive. In this paper, we formulate the problem and present a stabilization operator to regularize a classifier towards a previous classifier. We use a Markov chain Monte Carlo stabilization operator to produce a model with more consistent predictions without adversely affecting accuracy. We investigate the properties of the proposal with theoretical analysis. Experiments on benchmark datasets for different classification algorithms demonstrate the method and the resulting reduction in churn. 1 The Curse of Version 2.0 In most practical settings, training and launching an initial machine-learned model is only the first step: as new and improved features are created, additional training data is gathered, and the model and learning algorithm are improved, it is natural to launch a series of ever-improving models. Each new candidate may bring wins, but also unnecessary changes. In practice, it is desirable to minimize any unnecessary changes for two key reasons. First, unnecessary changes can hinder usability and debugability as they can be disorienting to users and follow-on system components. Second, unnecessary changes make it more difficult to measure with statistical confidence whether the change is truly an improvement. For both these reasons, there is great interest in making only those changes that are wins, and minimizing any unnecessary changes, while making sure such process does not hinder the overall accuracy objective. There is already a large body of work in machine learning that treats the stability of learning algorithms. These range from the early works of Devroye and Wagner [1] and Vapnik [2, 3] to more recent studies of learning stability in more general hypothesis spaces [4, 5, 6]. Most of the literature on this topic focus on stability of the learning algorithm in terms of the risk or loss function and how such properties translate into uniform generalization with specific convergence rates. We build on these notions, but the problem treated here is substantively different. We address the problem of training consecutive classifiers to reduce unnecessary changes in the presence of realistic evolution of the problem domain and the training sets over time. The main contributions of this paper include: (I) discussion and formulation of the “churn” metric between trained models, (II) design of stabilization operators for regularization towards a previous model, (III) proposing a Markov chain Monte Carlo (MCMC) stabilization technique, (VI) theoretical analysis of the proposed stabilization in terms of churn, and (V) empirical analysis of the proposed methods on benchmark datasets with different classification algorithms. 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. Table 1: Win-loss ratio (WLR) needed to establish a change is statistically significant at the p = 0.05 level for k wins out of n diffs from a binomial distribution. The empirical WLR column shows the WLR one must actually see in the diffs. The true WLR column is the WLR the change must have so that any random draw of diffs has at least a 95% chance of producing the needed empirical WLR. # Diffs Min # Wins Max # Losses Empirical WLR True WLR Needed Allowed Needed Needed 10 9 1 9.000 26.195 100 59 41 1.439 1.972 1,000 527 473 1.114 1.234 10,000 5,083 4,917 1.034 1.068 1.1 Testing for Improvements In the machine learning literature, it is common to compare classifiers on a fixed pre-labeled test set. However, a fixed test set has a few practical downsides. First, if many potential changes to the model are evaluated on the same dataset, it becomes difficult to avoid observing spurious positive effects that are actually due to chance. Second, the true test distribution may be evolving over time, meaning that a fixed test set will eventually diverge from the true distribution of interest. Third, and most important to our discussion, any particular change may affect only a small subset of the test examples, leaving too small a sample of differences (diffs) to determine whether a change is statistically significant. For example, suppose one has a fixed test set of 10,000 samples with which to evaluate a classifier. Consider a change to one of the features, say a Boolean string-similarity feature that causes the feature to match more synonyms, and suppose that re-training a classifier with this small change to this one feature impacts only 0.1% of random examples. Then only 10 of the 10,000 test examples would be affected. As shown in the first row of Table 1, given only 10 diffs, there must be 9 or more wins to declare the change statistically significantly positive for p = 0.05. Note that cross-validation (CV), even in leave-one-out form, does not solve this issue. First, we are still bound by the size of the training set which might not include enough diffs between the two models. Second, and more importantly, the model in the previous iteration has likely seen the entire dataset, which breaks the independence assumption needed for the statistical test. To address these problems and ensure a fresh, sufficiently large test set for each comparison, practitioners often instead measure changes on a set of diffs for the proposed change. For example, to compare classifier A and B, each classifier is evaluated on a billion unlabeled examples, and then the set of diffs is defined as those examples for which classifiers A and B predict a different class. 1.2 Churn We define the churn between two models as the expected percent of diffs sampled from the test distribution. For a fixed accuracy gain, less churn is better. For example, if classifier A has accuracy 90% and classifier B has accuracy 91%, then the best case is if classifier B gets the same 90% of examples correct as classifier A, while correcting A’s errors on 1% of the data. Churn is thus only 1% in this case, and all diffs between A and B will be wins for B. Therefore the improvement of B over A will achieve statistical significance after labelling a mere 10 diffs. The worst case is if classifier A is right on the 9% of examples that B gets wrong, and B is right on the 10% of examples that A gets wrong. In this case, churn is 19%, and a given diff will only have probability of 10/19 of being a win for B, and almost 1,000 diffs will have to be labeled to be confident that B is better. On Statistical Significance: Throughout this paper, we assume that every diff is independent and identically distributed with some probability of being a win for the test model vs. the base model. Thus, the probability of k wins in n trials follows a binomial distribution. Confidence intervals can provide more information than a p-value, but p-values are a useful summary statistic to motivate the problem and proposed solution, and are relevant in practice; for a longer discussion see e.g. [7]. 2 Reducing Churn for Classifiers In this paper, we propose a new training strategy for reducing the churn between classifiers. One special case is how to train a classifier B to be low-churn given a fixed classifier A. We treat that 2 De-Churning Markov Chain A B T1 T2 TK TA TB . .. F ∗ 1 F ∗ 2 F ∗ K A∗ B∗ . .. Figure 1: The orange nodes illustrate a Markov Chain, at each step the classifier F ∗ t is regularized towards the previous step’s classifier F ∗ t−1 using the stabilization operator S, and each step trained on a different random training set Tt. We run K steps of this Markov chain, for K large enough so that the distribution of F ∗ k is close to a stationary distribution. The classifier A∗= S(F ∗ K, TA) is then deployed. Later, some changes are proposed, and a new classifier B∗is trained on training set TB but regularized towards A∗using B∗= S(A∗, TB). We compare this proposal in terms of churn and accuracy to the green nodes, which do not use the proposed stabilization. special case as well as a broader problem: a framework for training both classifiers A and B so that classifier B is expected to have low-churn relative to classifier A, though when we train A we do not yet know exactly the changes B will incorporate. We place no constraints on the kind of classifiers or the kind of future changes allowed. Our solution consists of two components: a stabilization operator that regularizes classifier B to be closer in predictions to classifier A; and a randomization of the training set that attempts to mimic expected future changes. We consider a training set T = {(xi, yi)}m i=1 of m samples with each D-dimensional feature vector xi ∈X ⊆RD and each label yi ∈Y = {−1, 1}. Samples are drawn i.i.d. from distribution D. Define a classifier f : RD →{−1, 1}, and the churn between two classifiers f1 and f2 as: C(f1, f2) = E (X,Y )∼D[1f1(X)f2(X)<0], (1) where 1 is the indicator function. We are given training sets TA and TB to train the first and second version of the model respectively. TB might add or drop features or examples compared to TA. 2.1 Perturbed Training to Imitate Future Changes Consider a random training set drawn from a distribution P(TA), such that different draws may have different training samples and different features. We show that one can train an initial classifier to be more consistent in predictions for different realizations of the perturbed training set by iteratively training on a series of i.i.d. random draws T1, T2, . . . from P(TA). We choose P(TA) to model a typical expected future change to the dataset. For example, if we think a likely future change will add 5% more training data and one new feature, then we would define a random training set to be a random 95% of the m examples in TA, while dropping a feature at random. 2.2 Stabilized Training Based On A Previous Model using a Markov Chain We propose a Markov chain Monte Carlo (MCMC) approach to form a distribution over classifiers that are consistent in predictions w.r.t. the distribution P(TA) on the training set. Let S denote a regularized training that outputs a new classifier F ∗ t+1 = S(F ∗ t , Tt+1) where F ∗ t is a previous classifier and Tt+1 is the current training set. Applying S repeatedly to random training sets Tt forms a Markov chain as shown in Figure 1. We expect this chain to produce a stationary peaked distribution on classifiers robust to the perturbation P(TA). We sample a model from this resulting distribution after K steps. We end the proposed Markov chain with a classifier A∗trained on the full training set TA, that is, A∗= S(F ∗ K, TA). Classifier A∗is the initial launched model, and has been pre-trained to be robust to the kind of changes we expect to see in some future training set TB. Later, classifier B∗should be trained as B∗= S(A∗, TB). We expect the chain to have reduced the churn C(A∗, B∗) compared to the churn C(A, B) that would have resulted from training classifiers A and B without the proposed stabilization. See Figure 1 for an illustration. Note that this chain only needs to be run for the first version of the model. 3 On Regularization Effect of Perturbed Training: One can view the perturbation of the dataset and random feature drops during the MCMC run as a form of regularization, resembling the dropout technique [8] now popular in deep, convolutional and recurrent neural networks (see e.g. [9] for a recent survey). Such regularization can result in better generalization error, and our empirical results show some evidence of such an effect. See further discussion in the experiments section. Perturbation Chain as Longitudinal Study: The chain in Figure 1 can also be viewed as a study of the stabilization operator upon several iterations of the model, with each trained and anchored on the previous version. It can help us assess if the successive application of the operator has any adverse effect on the accuracy or if the resulting churn reduction diminishes over time. 3 Stabilization Operators We propose two stabilization operators: (I) Regress to Corrected Prediction (RCP) which turns the classification problem into a regression towards corrected predictions of an older model, and (II) the Diplopia operator which regularizes the new model towards the older model using example weights. 3.1 RCP Stabilization Operator We propose a stabilization operator S(f, T) that can be used with almost any regression algorithm and any type of change. The RCP operator re-labels each classification training label yj ∈{−1, 1} in T with a regularized label ˜yj ∈R, using an anchor model f: ˜yj = αf(xj) + (1 −α)yj if yjf(xj) ≥0 ϵyj otherwise, (2) where α, ϵ ∈[0, 1] are hyperparameters of S that control the churn-accuracy trade-off, with larger α corresponding to lower churn but less sensitive to good changes. Denote the set of all re-labeled examples ˜T. The RCP stabilization operator S trains a regression model on ˜T, using the user’s choice of regression algorithm. 3.2 Diplopia Stabilization Operator The second stabilization operator, which we term Diplopia (double-vision), can be used with any classification strategy that can output a probability estimate for each class, including algorithms like SVMs and random forests (calibrated with a method like Platt scaling [10] or isotonic regression [11]). This operator can be easily extended to multi-class problems. For binary classification, the Diplopia operator copies each training example into two examples with labels ±1, and assigns different weights to the two contradictorily labeled copies. If f(.) is the probability estimate of class +1: (xi, yi) → (xi, +1) with weight Λi (xi, −1) with weight 1 −Λi Λi = αf(xi) + (1 −α)1yi≥0 if yi(f(xi) −1 2) ≥0 1/2 + ϵyi otherwise. The formula always assigns the higher weight to the copy with the correct label. Notice that the roles of α and ϵ are very similar than to those in (2). To see the intuition behind this operator, note that with α = 1 and without the ϵ-correction, stochastic f(.) maximizes the likelihood of the new dataset. The RCP operator requires using a regressor, but our preliminary experiments showed that it often trains faster (without the need to double the dataset size) and reduces churn better than the Diplopia operator. We therefore focus on the RCP operator for theoretical and empirical analysis. 4 Theoretical Results In this section we present some general bounds on smoothed churn, assuming that the perturbation does not remove any features, and that the training algorithm is symmetric in training examples (i.e. independent of the order of the dataset). The analysis here assumes datasets for different models are sampled i.i.d., ignoring the dependency between consecutive re-labeled datasets (through the intermediate model). Proofs and further technical details are given in the supplemental material. 4 First, note that we can rewrite the definition of the churn in terms of zero-one loss: C(f1, f2) = E (X,Y )∼D [ℓ0,1(f1(X), f2(X))] = E (X,Y )∼D [|ℓ0,1(f1(X), Y ) −ℓ0,1(f2(X), Y )|] . (3) We define a relaxation of C that is similar to the loss used by [5] to study the stability of classification algorithms, we call it smooth churn and it is parameterized by the choice of γ: Cγ(f1, f2) = E (X,Y )∼D [|ℓγ(f1(X), Y ) −ℓγ(f2(X), Y )|] , (4) where ℓγ(y, y′) = 1 if yy′ ≤0, ℓγ(y, y′) = 1 −yy′/γ for 0 ≤yy′ ≤γ, and ℓγ(y, y′) = 0 otherwise. Smooth churn can be interpreted as γ playing the role of a “confidence threshold” of the classifier f such that |f(x)|≪γ means the classifier is not confident in its prediction. It is easy to verify that ℓγ is (1/γ)-Lipschitz continuous with respect to y, when y′ ∈{−1, 1}. Let fT (x) →R be a classifier discriminant function (which can be thresholded to form a classifier) trained on set T. Let T i be the same as T except with the ith training sample (xi, yi) replaced by another sample. Then, as in [4], define training algorithm f.(.) to be β-stable if: ∀x, T, T i : |fT (x) −fT i(x)|≤β. (5) Many algorithms such as SVM and classical regularization networks have been shown to be β-stable with β = O(1/m) [4, 5]. We can use β-stability of learning algorithms to get a bound on the expected churn between independent runs of the algorithms on i.i.d. datasets: Theorem 1 (Expected Churn). Suppose f is β-stable, and is used to train classifiers on i.i.d. training sets T and T ′ sampled from Dm. We have: E T,T ′∼Dm[Cγ(fT , fT ′)] ≤β√πm γ . (6) Assuming β = O(1/m) this bound is of order O(1/√m), in line with most concentration bounds on the generalization error. We can further show that churn is concentrated around its expectation: Theorem 2 (Concentration Bound on Churn). Suppose f is β-stable, and is used to train classifiers on i.i.d. training sets T and T ′ sampled from Dm. We have: Pr T,T ′∼Dm Cγ(fT , fT ′) > ϵ + √πmβ γ ≤e−ϵ2γ2 mβ2 . (7) β-stability for learning algorithms often includes worst case bound on loss or Lipschitz-constant of the loss function. Assuming we use the RCP operator with squared loss in a reproducing kernel Hilbert space (RKHS), we can derive a distribution-dependent bound on the expected squared churn: Theorem 3 (Expected Squared Churn). Let F be a reproducing kernel Hilbert space with kernel k such that ∀x ∈X : k(x, x) ≤κ2 < ∞. Let fT be a model trained on T = {(xi, yi)}m i=1 defined by: fT = arg min g∈F 1 m m X 1 (g(xi) −yi)2 + λ∥g∥2 k. (8) For models trained on i.i.d. training sets T and T ′: E T,T ′∼Dm (X,Y )∼D (ℓγ(fT (X), Y ) −ℓγ(fT ′(X), Y ))2 ≤ 2κ4 mλ2γ2 E T ∼Dm " 1 m m X i=1 (fT (xi) −yi)2 # . (9) We can further use Chebyshev’s inequality to get a concentration bound on the smooth churn Cγ. Unlike the bounds in [4] and [5], the bound of Theorem 3 scales with the expected training error (note that we must use ˜yi in place of of yi when applying the theorem, since training data is re-labeled by the stabilization operator). We can thus use the above bound to analyse the effect of α and ϵ on the churn, through their influence on the training error. Suppose the Markov chain described in Section 2.2 has reached a stationary distribution. Let F ∗ k be a model sampled from the resulting stationary distribution, used with the RCP operator defined in (2) 5 Table 2: Description of the datasets used in the experimental analysis. Nomao [13] News Popularity [14] Twitter Buzz [15] # Features 89 61 77 TA 4000 samples, 84 features 8000 samples, 58 features 4000 samples, 70 features TB 5000 samples, 89 features 10000 samples, 61 features 5000 samples, 77 features Validation set 1000 samples 1000 samples 1000 samples Testing set 28465 samples 28797 samples 45402 samples to re-label the dataset Tk+1. Since F ∗ k+1 is the minimizer of objective in (8) on the re-labeled dataset we have: E Tk+1 " 1 m m X i=1 (F ∗ k+1(xi) −˜yi)2 # ≤ E Tk+1 " 1 m m X i=1 (F ∗ k (xi) −˜yi)2 + λ(∥F ∗ k ∥2 k−∥F ∗ k+1∥2 k) # = E Tk+1 " 1 m m X i=1 (F ∗ k (xi) −˜yi)2 # , (10) where line (10) is by the assumptions of stationary regime on F ∗ k and F ∗ k+1 with similar dataset sampling distributions for Tk and Tk+1. If E is the set of examples that F ∗ k got wrong, using the definition of the RCP operator we can replace ˜yi to get this bound on the squared churn: κ4 mλ2γ2 E Tk+1 " 1 −α m X i/∈E (F ∗ k (xi) −yi)2 + 1 m X i∈E (F ∗ k (xi) + ϵ)2 # . (11) We can see in Eqn. (11) that using an α close to 1 can decrease the first part of the bound, but at the same time it can negatively affect the error rate of the classifier, resulting in more samples in E and consequently a larger second term. Decreasing ϵ can reduce the (F ∗ k (xi) + ϵ)2 term of the bound, but can again cause an increase in the error rate. As shown in the experimental results, there is often a trade-off between the amount of churn reduction and the accuracy of the resulting model. We can measure the accuracy on the training set or a validation set to make sure the choice of α and ϵ does not degrade the accuracy. To estimate churn reduction, we can use an un-labeled dataset. 5 Experiments This section demonstrates the churn reduction effect of the RCP operator for three UCI benchmark datasets (see Table 2) with three regression algorithms: ridge regression, random forest regression, and support vector machine regression with RBF kernel, all implemented in Scikit-Learn [12] (additional results for boosted stumps and linear SVM in the appendix). We randomly split each dataset into three fixed parts: a training set, a validation set on which we optimized the hyper-parameters for all algorithms, and a testing set. We impute any missing values by the corresponding mean, and normalize the data to have zero mean and variance 1 on the training set. See the supplementary material for more experimental details. To compare two models by computing the WLR on a reasonable number of diffs, we have made the testing sets as large as possible, so that the expected number of diffs between two different models is large enough to derive accurate and statistically significant conclusions. Lastly, we note that the churn metric does not require labels, so it can be computed on an unlabeled dataset. 5.1 Experimental Set-up and Metrics We assume an initial classifier is to be trained on TA, and a later candidate trained on TB will be tested against the initial classifier. For the baseline of our experiments, we train classifier A on TA and classifier B on TB independently and without any stabilization, as shown in Figure 1. For the RCP operator comparison, we train A on TA, then train B+= S(A, TB). For the MCMC operator comparison, we run the MCMC chain for k = 30 steps—empirically enough for convergence 6 5 10 15 20 25 30 Iteration of the Markov chain 1 1.5 2 2.5 3 Churn (%) between consecutive models C(Fi,Fi-1) C(Fi *, Fi-1 * ) 5 10 15 20 25 30 Iteration of the Markov chain 94.1 94.2 94.3 94.4 94.5 94.6 94.7 94.8 94.9 Test Accuracy (%) Fi Accuracy Fi * Accuracy Figure 2: Left: Churn between consecutive models during the MCMC run on Nomao Dataset, with and without stabilization. Right: Accuracy of the intermediate models, with and without stabilization. Values are averaged over 40 runs of the chain. Dotted lines show standard errors. for the datasets we considered as seen in Figure 2—and set A∗= S(F ∗ k , TA) and B∗= S(A∗, TA). The dataset perturbation sub-samples 80% of the examples in TA and randomly drops 3-7 features. We run 40 independent chains to measure the variability, and report the average outcome and standard deviation. Figure 2 (left) plots the average and standard deviation of the churn along the 40 traces, and Figure 2 (right) shows the accuracy. For each experiment we report the churn ratio Cr between the initial classifier and candidate change, that is, Cr = C(B+, A)/C(B, A) for the RCP operator, and Cr = C(B∗, A∗)/C(B, A) for the MCMC operator, and Cr = C(B, A)/C(B, A) = 1 for the baseline experiment. The most important metric in practice is how easy it is to tell if B is an improvement over A, which we quantify by the WLR between the candidate and initial classifier for each experiment. To help interpret the WLR, we also report the resulting probability pwin that we would conclude that the candidate change is positive (p ≤0.05) with a random 100-example set of differences. Lastly, to demonstrate that the proposed methods reduce the churn without adversely impacting the accuracy of the models, we also report the accuracy of the different trained models for a large test set, though the point of this work is that a sufficiently-large labeled test set may not be available in a real setting (see Section 1.1), and note that even if available, using a fixed test set to test many different changes will lead to overfitting. 5.2 Results Table 3 shows results using reasonable default values of α = 0.5 and ϵ = 0.5 for both RCP and the MCMC (for results with other values of α and ϵ see Appendix D). As seen in the Cr rows of the table, RCP reduces churn over the baseline in all 9 cases, generally by 20%, but as much as 46% for ridge regression on the Nomao dataset. Similarly, running RCP in the Markov Chain also reduces the churn compared to the baseline in all 9 cases, and by slightly more on average than with the one-step RCP. 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 Epsilon Parameter for RCP 0.1 0.2 0.3 0.4 0.5 Test accuracy compared to baseline (%) 0.5 0.55 0.6 0.65 0.7 Churn Ratio (A*- A) Accuracy (B*- B) Accuracy Churn Ratio 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 Alpha Parameter for RCP -1.5 -1 -0.5 0 0.5 1 Test accuracy compared to baseline (%) 0.3 0.5 0.7 0.9 1.1 Churn Ratio (A*- A) Accuracy (B*- B) Accuracy Churn Ratio Figure 3: SVM on Nomao dataset. Left: Testing accuracy of A∗and B∗compared to A and B, and churn ratio Cr as a function of ϵ, for fixed α = 0.7. Both the accuracy and the churn ratio tend to increase with larger values of ϵ. Right: Accuracies and the churn ratio versus α, for fixed ϵ = 0.1. There is a sharp decrease in accuracy with α > 0.8 likely due to divergence in the chain. 7 Table 3: Experiment results on 3 domains with 3 different training algorithms for a single step RCP and the MCMC methods. For the MCMC experiment, we report the numbers with the standard deviation over the 40 runs of the chain. Baseline RCP MCMC, k = 30 No Stabilization α = 0.5, ϵ = 0.5 α = 0.5, ϵ = 0.5 Nomao Ridge WLR 1.24 1.40 1.31 pwin 26.5 49.2 36.5 Cr 1.00 0.54 0.54 ± 0.06 Acc V1 / V2 93.1 / 93.4 93.1 / 93.4 93.2 ± 0.1 / 93.4 ± 0.1 RF WLR 1.02 1.13 1.09 pwin 5.6 13.4 9.8 Cr 1.00 0.83 0.83 ± 0.05 Acc V1 / V2 94.8 / 94.8 94.8 / 95.0 94.9 ± 0.2 / 95.0 ± 0.2 SVM WLR 1.70 2.51 2.32 pwin 82.5 99.7 99.2 Cr 1.00 0.75 0.69 ± 0.06 Acc V1 / V2 94.6 / 95.1 94.6 / 95.2 94.8 ± 0.2 / 95.3 ± 0.1 News Ridge WLR 0.95 0.94 1.04 pwin 2.5 2.4 6.7 Cr 1.00 0.75 0.78 ± 0.04 Acc V1 / V2 65.1 / 65.0 65.1 / 65.0 65.0 ± 0.1 / 65.1 ± 0.1 RF WLR 1.07 1.02 1.10 pwin 8.5 5.7 10.8 Cr 1.00 0.69 0.67 ± 0.04 Acc V1 / V2 64.5 / 65.1 64.5 / 64.7 64.3 ± 0.3 / 64.8 ± 0.2 SVM WLR 1.17 1.26 1.24 pwin 18.4 29.4 26.1 Cr 1.00 0.77 0.86 ± 0.02 Acc V1 / V2 64.9 / 65.4 64.9 / 65.4 64.8 ± 0.1 / 65.4 ± 0.1 Twitter Buzz Ridge WLR 1.71 3.54 1.53 pwin 83.1 100.0 66.4 Cr 1.00 0.85 0.65 ± 0.05 Acc V1 / V2 89.7 / 89.9 89.7 / 90.0 90.1 ± 0.1 / 90.2 ± 0.1 RF WLR 1.35 1.15 1.15 pwin 41.5 16.1 15.9 Cr 1.00 0.86 0.77 ± 0.07 Acc V1 / V2 96.2 / 96.4 96.2 / 96.3 96.3 ± 0.1 / 96.3 ± 0.1 SVM WLR 1.35 1.77 1.55 pwin 42.2 86.6 68.4 Cr 1.00 0.70 0.70 ± 0.03 Acc V1 / V2 96.0 / 96.1 96.0 / 96.1 96.1 ± 0.1 / 96.2 ± 0.1 In some cases, the reduced churn has a huge impact on the WLR. For example, for the SVM on Twitter, the 30% churn reduction by RCP raised the WLR from 1.35 to 1.77, making it twice as likely that labelling 100 differences would have verified the change was good (compare pwin values). MCMC provides a similar churn reduction, but the WLR increase is not as large. In addition to the MCMC providing slightly more churn reduction on average than RCP, running the Markov chain provides slightly higher accuracy on average as well, most notably for the ridge classifier on the Twitter dataset, raising initial classifier accuracy by 2.3% over the baseline. We hypothesize this is due to the regularization effect of the perturbed training during the MCMC run, resembling the effect of dropout in neural networks. We used fixed values of α = 0.5 and ϵ = 0.5 for all the experiments in Table 3, but note that results will vary with the choice of α and ϵ, and if they can be tuned with cross-validation or otherwise, results can be substantially improved. Figure 3 illustrates the dependence on these hyper-parameters: the left plot shows that small values of ϵ result in lower churn with reduced improvement on accuracy, and the right plot shows that increasing α reduces churn, and also helps increase accuracy, but at values larger than 0.8 causes the Markov chain to diverge. 8 References [1] L. Devroye and T. Wagner. Distribution-free performance bounds for potential function rules. Information Theory, IEEE Transactions on, 25(5):601–604, 1979. [2] V. N. Vapnik. The Nature of Statistical Learning Theory. Springer-Verlag: New York, 1995. [3] V. N. Vapnik. Statistical Learning Theory. John Wiley: New York, 1998. [4] O. Bousquet and A. Elisseeff. Algorithmic stability and generalization performance. In Advances in Neural Information Processing Systems 13: Proceedings of the 2000 Conference, volume 13, page 196. MIT Press, 2001. [5] O. Bousquet and A. Elisseeff. Stability and generalization. Journal of Machine Learning Research, 2(Mar):499–526, 2002. [6] S. Mukherjee, P. Niyogi, T. Poggio, and R. Rifkin. Learning theory: stability is sufficient for generalization and necessary and sufficient for consistency of empirical risk minimization. Advances in Computational Mathematics, 25(1-3):161–193, 2006. [7] A. Reinart. Statistics Done Wrong: The Woefully Complete Guide. No Starch Press, San Francisco, USA, 2015. [8] N. Srivastava, G. Hinton, A. Krizhevsky, I. Sutskever, and R. Salakhutdinov. Dropout: A simple way to prevent neural networks from overfitting. The Journal of Machine Learning Research, 15(1):1929–1958, 2014. [9] L. Zhang and P. N. Suganthan. A survey of randomized algorithms for training neural networks. Information Sciences, 2016. [10] J. Platt. Probabilistic outputs for support vector machines and comparisons to regularized likelihood methods. Advances in Large Margin Classifiers, 10(3):61–74, 1999. [11] A. Niculescu-Mizil and R. Caruana. Predicting good probabilities with supervised learning. In Proceedings of the 22nd International Conference on Machine Learning, pages 625–632. ACM, 2005. [12] F. Pedregosa, G. Varoquaux, A. Gramfort, V. Michel, B. Thirion, O. Grisel, M. Blondel, P. Prettenhofer, R. Weiss, V. Dubourg, J. Vanderplas, A. Passos, D. Cournapeau, M. Brucher, M. Perrot, and E. Duchesnay. Scikit-learn: Machine learning in Python. Journal of Machine Learning Research, 12:2825–2830, 2011. [13] L. Candillier and V. Lemaire. Design and analysis of the Nomao challenge active learning in the real-world. In Proceedings of the ALRA: Active Learning in Real-world Applications, Workshop ECML-PKDD, 2012. [14] K. Fernandes, P. Vinagre, and P. Cortez. Progress in Artificial Intelligence: 17th Portuguese Conference on Artificial Intelligence, EPIA 2015, Coimbra, Portugal, September 8-11, 2015. Proceedings, chapter A Proactive Intelligent Decision Support System for Predicting the Popularity of Online News, pages 535–546. Springer International Publishing, Cham, 2015. [15] F. Kawala, E. Gaussier, A. Douzal-Chouakria, and E. Diemert. Apprentissage d’ordonnancement et influence de l’ambiguïté pour la prédiction d’activité sur les réseaux sociaux. In Coria’2014, pages 1–15, Nancy, France, France, March 2014. 9 | 2016 | 497 |
6,435 | Constraints Based Convex Belief Propagation Yaniv Tenzer Department of Statistics The Hebrew University Alexander Schwing Department of Electrical and Computer Engineering University of Illinois at Urbana-Champaign Kevin Gimpel Toyota Technological Institute at Chicago Tamir Hazan Faculty of Industrial Engineering and Management Technion - Israel Institute of Technology Abstract Inference in Markov random fields subject to consistency structure is a fundamental problem that arises in many real-life applications. In order to enforce consistency, classical approaches utilize consistency potentials or encode constraints over feasible instances. Unfortunately this comes at the price of a tremendous computational burden. In this paper we suggest to tackle consistency by incorporating constraints on beliefs. This permits derivation of a closed-form message-passing algorithm which we refer to as the Constraints Based Convex Belief Propagation (CBCBP). Experiments show that CBCBP outperforms the conventional consistency potential based approach, while being at least an order of magnitude faster. 1 Introduction Markov random fields (MRFs) [10] are widely used across different domains from computer vision and natural language processing to computational biology, because they are a general tool to describe distributions that involve multiple variables. The dependencies between variables are conveniently encoded via potentials that define the structure of a graph. Besides encoding dependencies, in a variety of real-world applications we often want consistent solutions that are physically plausible, e.g., when jointly reasoning about multiple tasks or when enforcing geometric constraints in 3D indoor scene understanding applications [18]. Therefore, various methods [22, 13, 16, 12, 1] enforce consistency structure during inference by imposing constraints on the feasible instances. This was shown to be effective in practice. However for each new constraint we may need to design a specifically tailored algorithm. Therefore, the most common approach to impose consistency is usage of PN-consistency potentials [9]. This permits reuse of existing message passing solvers, however, at the expense of an additional computational burden, as real-world applications may involve hundreds of additional factors. Our goal in this work is to bypass this computational burden while being generally applicable. To do so, we consider the problem of inference when probabilistic equalities are imposed over the beliefs of the model rather than its feasible instances. As we show in Sec. 3, the adaptive nature of message passing algorithms conveniently allows for such probabilistic equality constraints within its framework. Since our method eliminates potentially many multivariate factors, inference is much more scalable than using PN-consistency potentials [9]. In this paper, for notational simplicity, we illustrate the belief constraints based message passing rules using a framework known as convex belief propagation (CBP). We refer to the illustrated algorithm as constraints based CBP (CBCBP). However we note that the same derivation can be used to obtain, e.g., a constraints based tree-reweighted message passing algorithm. 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. We evaluate the benefits of our algorithm on semantic image segmentation and machine translation tasks. Our results indicate that CBCBP improves accuracy while being at least an order of magnitude faster than CBP. 2 Background In this section we review the standard CBP algorithm. To this end we consider joint distributions defined over a set of discrete random variables X = (X1, . . . , Xn). The distribution p(x1, . . . , xn) is assumed to factor into a product of non-negative potential functions, i.e., p(x1, . . . , xn) ∝exp (P r θr(xr)) , where r ⊂{1, ..., n} is a subset of variable indices, which we use to restrict the domain via xr = (xi)i∈r. The real-valued functions θr(xr) assign a preference to each of the variables in the subset r. To visualize the factorization structure we use a region graph, i.e., a generalization of factor graphs. In this graph, each real-valued function θr(xr) corresponds to a node. Nodes θr and θp can be connected if r ⊂p. Hence the parent set P(r) of a region r contains index sets p ∈P(r) if r ⊂p. Conversely we define the set of children of region r as C(r) = {c : r ∈P(c)}. An important inference task is computation of the marginal probabilities p(xr) = P x\xr p(x). Whenever the region graph has no cycles, marginals are easily computed using belief propagation. Unfortunately, this algorithm may not converge in the presence of cycles. To fix convergence a variety of approximations have been suggested, one of which is known as convex belief propagation (CBP). CBP performs block-coordinate descent over the dual function of the following program: max br X r,xr br(xr)θr(xr)+ X r H(br) s.t. ∀r br(xr) ≥0, P xr br(xr) = 1, ∀r, p ∈P(r), xr P xp\xr bp(xp) = br(xr). (1) This program is defined over marginal distributions br(xr) and incorporates their entropy H(br) in addition to the potential function θr. In many real world applications we require the solution to be consistent, i.e., hard constraints between some of the involved variables exist. For example, consider the case where X1, X2 are two binary variables such that for every feasible joint assignment, x1 = x2. To encourage consistency while reusing general purpose solvers, a PN-consistency potential [9] is often incorporated into the model: θ1,2(x1, x2) = 0 x1 = x2 −c otherwise . (2) Hereby c is a positive constant that is tuned to penalize for the violation of consistency. As c increases, the following constraint holds: b1(X1 = x1) = b2(X2 = x2). (3) However, usage of PN-potentials raises concerns: (i) increasing the number of pairwise constraints decreases computational efficiency, (ii) enforcing consistency in a soft manner requires tuning of an additional parameter c, (iii) large values of c reduce convergence, and (iv) large values of c result in corresponding beliefs being assigned zero probability mass which is not desirable. To alleviate these issues we suggest to enforce the equality constraints given in Eq. (3) directly during optimization of the program given in Eq. (1). We refer to the additionally introduced constraints as consistency constraints. At this point two notes are in place. First we emphasize that utilizing consistency constraints instead of PN-consistency potentials has a computational advantage, since it omits all pairwise beliefs that correspond to consistency potentials. Therefore it results in an optimization problem with fewer functions, which is expect to be more efficiently solvable. Second we highlight that the two approaches are not equivalent. Intuitively, as c increases, we expect consistency constraints to yield better results than usage of PN-potentials. Indeed, as c increases, the PN-consistency potential enforces the joint distribution to be diagonal, i.e., b(X1 = i, X2 = j) = 0, ∀i ̸= j. However, the consistency constraint as specified in Eq. (3) only requires the univariate marginals to agree. The latter is a considerably weaker requirement, as a diagonal pairwise distribution implies agreement of the univariate marginals, but the opposite direction does not hold. Consequently, using consistency constraints results in a larger search space, which is desirable. 2 Algorithm 1 Constraints Based Convex Belief Propagation (CBCBP) Repeat until convergence: Update λ messages - for each r update for all p ∈P(r), xr: µp→r(xr)=ln X xp\xr exp θr(xr) − X p′∈P (p) λp→p′(xp) + X r′∈C(p)\r λr′→p(xr′) − X k∈Kp νp→k(xp) λr→p(xr)∝ 1 1 + |P(r)| θr(xr) + X c∈C(r) λc→r(xc) + X p∈P (r) µp→r(xr) − X k∈Kr νr→k(xr) −µp→r(xr) Update ν messages - for each k ∈K update for all r ∈N(k) using αr,k as defined in Eq. (6): νr→k(sk r) = log αr,k − 1 |N(k)| X r′∈N(k) log αr′,k Figure 1: The CBCBP algorithm. Shown are the update rules for the λ and ν messages. Next we derive a general message-passing algorithm that aims at solving the optimization problem given in Eq. (1) subject to consistency constraints of the form given in Eq. (3). 3 Constraints Based Convex Belief Propagation (CBCBP) To enforce consistency of beliefs we want to incorporate constraints of the form br1(xr1) = . . . = brm(xrm). Each constraint involves a set of regions ri and some of their assignments xri. If this constraint involves more than two regions, i.e., if m > 2, it is easier to formulate the constraint as a series of constraints bri(xri) = v, i ∈{1, . . . , m}, for some constant v that eventually cancels. Generally, given a constraint k, we define the set of its neighbours N(k) to be the involved regions rk i as well as the involved assignment xk ri, i.e., N(k) = {rk i , xk ri}mk i=1. To simplify notation we subsequently use r ∈N(k) instead of (r, xr) ∈N(k). However, it should be clear from the context that each region rk is matched with a value xk r. We subsume all constraints within the set K. Additionally, we let Kr denote the set of all those constraints k which depend on region r, i.e., Kr = {k : r ∈N(k)}. Using the aforementioned notation we are now ready to augment the conventional CBP given in Eq. (1) with one additional set of constraints. The CBCBP program then reads as follows: max br X r,xr br(xr)θr(xr) + X r H(br) s.t. ∀r br(xr) ≥0, P xr br(xr) = 1 ∀r, p ∈P(r), xr P xp\xr bp(xp) = br(xr) ∀k ∈K, r ∈N(k) br(xk r) = vk . (4) To solve this program we observe that its constraint space exhibits a rich structure, defined on the one hand by the parent set P, and on the other hand by the neighborhood of the constraint subsumed in the set K. To exploit this structure, we aim at deriving the dual which is possible because the program is strictly convex. Importantly we can subsequently derive block-coordinate updates for the dual variables, which are efficiently computable in closed form. Hence solving the program given in Eq. (4) via its dual is much more effective. In the following we first present the dual before discussing how to efficiently solve it. Derivation of the dual program: The dual program of the task given in Eq. (4) is obtained by using the Lagrangian as shown in the following lemma. Lemma 3.1.: The dual problem associated with the primal program given in Eq. (4) is: min λ,ν X r log X xr exp θr(xr, λ) − X k∈Kr νr→k(xr) ! s.t. ∀k ∈K, X r∈N(k) νr→k(xk r) = 0, 3 where we set νr→k(xr) = 0 ∀k ∈K, r ∈N(k), xr ̸= xk r and where we introduced θr(xr, λ) = θr(xr) −P p∈P (r) λr→p(xr) + P c∈C(r) λc→r(sc). Proof: We begin by defining a Lagrange multiplier for each of the constraints given in Eq. (4). Concretely, for all r, p ∈P(r), xr we let λr→p(xr) be the Lagrange multiplier associated with the marginalization constraint P xp\xr bp(xp) = br(xr). Similarly for all k ∈K, r ∈N(k), we let νr→k(xk r) be the Lagrange multiplier that is associated with the constraint br(xk r) = vk. The corresponding Lagrangian is then given by L(b, λ, ν) = X r,xr br(xr) θr(xr, λ) − X k∈Kr νr→k(xr) ! + X r H(br) + X k∈K,r∈N(k) νr→k(xk r)vk, where θr(xr, λ) = θr(xr) −P p∈P (r) λr→p(xr) + P c∈C(r) λc→r(xc) and νr→k(xr) = 0 for all k, r ∈N(k), xr ̸= xk r. Due to conjugate duality between the entropy and the log-sum-exp function [25], the dual function is: D(λ, ν) = max b L(b, λ, ν) = X r log X xr exp θr(xr, λ) − X k∈Kr νr→k(xr) ! + X k vk X r∈N(k) νr→k(xk r). The result follows since the dual function is unbounded from below with respect to the Lagrange multipliers νr→k(xk r), requiring constraints. Derivation of message passing update rules: As mentioned before we can derive blockcoordinate descent update rules for the dual which are computable in closed form. Hence the dual given in Lemma 3.1 can be solved efficiently, which is summarized in the following theorem: Theorem 3.2.: A block coordinates descent over the dual problem giving in Lemma 3.1 results in a message passing algorithm whose details are given in Fig. 1 and which we refer to as the CBCBP algorithm. It is guaranteed to converge. Before proving this result, we provide intuition for the update rules: as in the standard and distributed [19] CBP algorithm, each region r sends a message to its parents via the dual variable λr→p. Differently from CBP but similar to distributed variants [19], our algorithm has another type of messages, i.e., the ν messages. Conceptually, think of the constraints as a new node. A constraint node k is connected to a region r if r ∈N(k). Hence, a region r ‘informs’ the constraint node using the dual variable νr→k. We now show how to derive the message passing rules to optimize the dual. Proof: First we note that convergence is guaranteed by the strict convexity of the primal problem [6]. Next we begin by optimizing the dual function given in Lemma 3.1 with respect to the λ parameters. Specifically, for a chosen region r we optimize the dual w.r.t. a block of Lagrange multipliers λr→p(xr) ∀p ∈P(r), xr. To this end we derive the dual with respect to λr→p(xr) while keeping all other variables fixed. The technique for solving the optimality conditions follows existing literature, augmented by messages νr→k. It yields the update rules given in Fig. 1. Next we turn to optimizing the dual with respect to the Lagrange multipliers ν. Recall that each constraint k ∈K in the dual function given in Lemma 3.1 is associated with the linear constraint P r∈N(k) νr→k(xk r) = 0. Therefore we employ a Lagrange multiplier γk for each k. For compact exposition, we introduce the Lagrangian that is associated with a constraint k, denoted by Lk: Lk(λ, ν) = X r∈N(k) log X xr exp θr(xr, λ) − X k∈Kr νr→k(xr) ! + γk X r∈N(k) νr→k(xk r) . Deriving Lk with respect to νr→k ∀r ∈N(k) and using optimality conditions, we then arrive at: νr→k(xk r) = log αr,k · 1 + γk −γk (5) for all r ∈N(k), where αr,k = exp θr(xk r, λ) −P k′∈Kr\k νr→k′(xk r) P xr\xk r exp θr(xr, λ) −P k′∈Kr νr→k′(xr) . (6) 4 n = 100 n = 200 n = 300 n = 400 CBP 1.47 ± 2e−4 2.7 ± 1e−4 5.95 ± 3e−3 13.42 ± 2e−3 CBCBP 0.05 ± 3e−4 0.11 ± 1e−4 0.23 ± 2e−3 0.43 ± 1e−3 Table 1: Average running time and standard deviation, over 10 repetitions, of CBCBP and CBP. Both infer the parameters of MRFs that consist of n variables. c = 2 c = 4 c = 6 c = 8 c = 10 CBP 31.40 ± 0.74 42.05 ± 1.02 49.17 ± 1.27 53.35 ± 0.93 58.01 ± 0.82 Table 2: Average speedup factor and standard deviation, over 10 repetitions, of CBCBP compared to CBP, for different values of c. Both infer the beliefs of MRFs that consist of 200 variables. Summing the right hand side of Eq. (5) over r ∈N(k) and using the constraint P r∈N(k) νr→k(xk r) = 0 results in 1 + γk −γk = Y r∈N(k) 1 αr,k 1 |N(k)| . Finally, substituting this result back into Eq. (5) yields the desired update rule. We summarized the resulting algorithm in Fig. 1 and now turn our attention to its evaluation. 4 Experiments We first demonstrate the applicability of the procedure using synthetic data. We then turn to image segmentation and machine translation, using real-world datasets. As our work directly improves the standard CBP approach, we use it as a baseline. 4.1 Synthetic Evaluation Consider two binary variables X and Y whose support consists of L levels, {1, . . . , L}. Assume we are given the following PN-consistency potential: θx,y(x, y) = 0 (y = 1 ∧x = 1) ∨(y = 0 ∧x ̸= 1) −c otherwise, (7) where c is some positive parameter. This potential encourages the assignment y = 1 to agree with the assignment x = 1 and y = 0 to agree with x = {2, . . . , L}. Phrased differently, this potential favours beliefs such that: by(y = 1) = bx(x = 1), by(y = 0) = bx(x ̸= 1). (8) Therefore, one may replace the above potential using a single consistency constraint. Note that the above two constraints complement each other, hence, it suffices to include one of them. We use the left consistency constraint since it fits our derivation. We test this hypothesis by constructing four networks that consist of n = 2v, v = 50, 100, 150, 200 variables, where v variables are binary, denoted by Y and the other v variables are multi-levels, subsumed within X. Note that the support of variable Xi, 1 ≤i ≤v, consists of i states. Each multi-level variable is matched with a binary one. For each variable we randomly generate unary potentials according to the standard Gaussian distribution. We then run the standard CBP algorithm using the aforementioned PN-consistency potential given in Eq. (7) with c = 1. In a next step we replace each such potential by its corresponding consistency constraint following Eq. (8). For each network we repeat this process 10 times and report the mean running time and standard deviation in Tab. 1. As expected, CBCBP is significantly faster than the standard CBP. Quantitatively, CBCBP was approximately 25 times faster for the smallest, and more than 31 times faster for the largest graphs. Obviously, different values of c effect the convexity of the problem and therefore also the running time of both CBP and CBCBP. To quantify its impact we repeat the experiment with n = 200 for distinct values of c ∈{2, 4, 6, 8, 10}. In Tab. 2 we report the mean speedup factor over 10 repetitions, for each value of c. As clearly evident, the speedup factors substantially increases with c. 5 global accuracy average accuracy mean running time CBP 84.2 74.3 1.41 ± 5e−3 CBCBP 85.4 76.1 0.02 ± 2e−3 Table 3: Global accuracy, average accuracy and mean running time as well as standard deviation for the 256 images of the MSRC-21 dataset. void grass tree cow sheep sky aeropl water face car bicycle flower sign bird book chair road cat dog body boat CBP 0.79 0.99 0.84 0.68 0.67 0.92 0.78 0.83 0.82 0.79 0.90 0.92 0.56 0.42 0.94 0.48 0.87 0.81 0.51 0.63 0 CBCBP 0.72 0.97 0.89 0.77 0.84 0.95 0.83 0.83 0.82 0.80 0.92 0.96 0.69 0.49 0.95 0.58 0.89 0.81 0.53 0.65 0 Table 4: Segmentation accuracy per class of CBCBP and CBP, for the MSRC-21 dataset. 4.2 Image Segmentation We evaluate our approach on the task of semantic segmentation using the MSRC-21 dataset [21] as well as the PascalVOC 2012 [4] dataset. Both contain 21 foreground classes. Each variable Xi in our model corresponds to a super-pixel in an image. In addition, each super-pixel is associated with a binary variable Yi, that indicates whether the super-pixel belongs to the foreground, i.e., yi = 1, or to the background, i.e., yi = 0. The model potentials are: Super-pixel unary potentials: For MSRC-21 these potentials are computed by averaging the TextonBoost [11] pixel-potentials inside each super-pixel. For the PascalVOC 2012 dataset we train a convolutional neural network following the VGG16 architecture. Foreground/Background unary potentials: For MSRC-21 we let the value of the potential at yi = 1 equal the value of the super-pixel unary potential that corresponds to the ‘void’ label, and for yi = 0 we define it to be the maximum value of the super-pixel unary potential among the other labels. For PascalVOC 2012 we obtain the foreground/background potential by training another convolutional neural network following again the VGG16 architecture. Super pixel - foreground/background consistency: We define pairwise potentials between superpixel and the foreground/background labels using Eq. (7) and set c = 1. Naturally, these consistency potentials encourage CBP to favour beliefs where pixels that are labeled as ‘void’ are also labeled as ‘background’ and vice versa. This can also be formulated using the constraints bi(Xi = 0) = bi(Yi = 0) and bi(Xi ̸= 1) = bi(Yi = 1). We compare the CBCBP algorithm with the standard CBP approach. For MSRC-21 we use the standard error measure of average per class accuracy and average per pixel accuracy, denoted as global. Performances results are provided in Tab. 3. Appealingly, our results indicate that CBCBP outperforms the standard CBP, across both metrics. Moreover and as summarized in Tab. 4, in 19 out of 21 classes CBCBP achieves an accuracy that is equal to or higher than CBP. At last, CBCBP is more than 65 times faster than CBP. In Tab. 5 we present the average pixel accuracy as well as the Intersection over Union (IoU) metric for the VOC2012 data. We observe CBCBP to perform better since it is able to transfer information between the foreground-background classification and the semantic segmentation. 4.3 Machine Translation We now consider the task of machine translation. We define a phrase-based translation model as a factor graph with many large constraints and use CBCBP to efficiently incorporate them during inference. Our model is inspired by the widely-used approach of [8]. Given a sentence in a source language, the output of our phrase-based model consists of a segmentation of the source sentence into phrases (subsequences of words), a phrase translation for each source phrase, and an ordering of the phrase translations. See Fig. 2 for an illustration. We index variables in our model by i = 1, . . . , n, which include source words (sw), source phrases (sp), and translation phrase slots (tp). The sequence of source words is first segmented into source phrases. The possible values for source word sw are Xsw = {(sw1, sw2) : (sw1 ≤sw ≤ sw2) ∧(sw2 −sw1 < m)}, where m is the maximum phrase length. If source phrase sp is used in the derivation, we say that sp aligns to a translation phrase slot tp. If sp is not used, it aligns to ∅. We define variables Xsp to indicate what sp aligns to: Xsp = {tp : 6 average accuracy IOU CBP 90.6 62.69 CBCBP 91.6 62.97 Table 5: Average accuracy and IOU accuracy for the 1449 images of the VOC2012 dataset. Figure 2: An example German sentence with a derivation of its translation. On the right we show the xsw variables, which assign source words to source phrases, the xsp variables, which assign source phrases to translation phrase slots, and the xtp variables, which fill slots with actual words in the translation. Dotted lines highlight how xsw values correspond to indices of xsp variables, and xsp values correspond to indices of xtp variables. The xsp variables for unused source spans (e.g., x(1,1), x(2,4), etc.) are not shown. sw1 −d ≤tp ≤sw2 + d} ∪{∅}, i.e., all translation phrase slots tp (numbered from left to right in the translation) such that the slot number is at most distance d from an edge of sp.1 Each translation phrase slot tp generates actual target-language words which comprise the translation. We define variables Xtp ranging over the possible target-language word sequences (translation phrases) that can be generated at slot tp. However, not all translation phrase slots must be filled in with translations. Beyond some value of tp (equaling the number of source phrases used in the derivation), they must all be empty. To enforce this, we also permit a null (∅) translation. Consistency constraints: Many derivations defined by the discrete product space X1 × · · · × Xn are semantically inconsistent. For example, a derivation may place the first source word into the source phrase (1, 2) and the second source word into (2, 3). This is problematic because the phrases overlap; each source word must be placed into exactly one source phrase. We introduce source word consistency constraints: ∀sp, ∀sw ∈sp : bsw(sp) = b(sp). These constraints force the source word beliefs bsw(xsw) to agree on their span. There are other consistencies we wish to enforce in our model. Specifically, we must match a source phrase to a translation phrase slot if and only if the source phrase is consistently chosen by all of its source words. Formally, ∀sp : b(sp) = P xsp̸=∅bsp(xsp). Phrase translation potentials: We use pairwise potential functions between source phrases sp = (sw1, sw2) and their aligned translation phrase slots tp. We include a factor ⟨sp, tp⟩∈E if sw1 − d ≤tp ≤sw2+d. Letting πsp be the actual words in sp, the potentials θsp,tp(xsp, xtp) determine the preference of the phrase translation ⟨πsp, xtp⟩using a phrase table feature function τ : ⟨π, π′⟩→Rk. In particular, θsp,tp(xsp, xtp) = γ⊤ p τ(⟨πsp, xtp⟩) if xsp = tp and a large negative value otherwise, where γp is the weight vector for the Moses phrase table feature vector. Language model potentials: To include n-gram language models, we add potentials that score pairs of consecutive target phrases, i.e., θtp−1,tp(xtp−1, xtp) = γℓ P|xtp| i=1 log Pr(x(i) tp |xtp−1 · x(1) tp · ... · x(i−1) tp ), where |xtp| is the number of words in xtp, x(i) tp is the i-th word in xtp, · denotes string concatenation, and γℓis the feature weight. This potential sums n-gram log-probabilities of words in the second of the two target phrases. Internal n-gram features and the standard word penalty feature [7] are computed in the θtp potentials, since they depend only on the words in xtp. Source phrase separation potentials: We use pairwise potentials between source phrases to prevent them aligning to the same translation slot. We also prevent two overlapping source phrases 1Our distortion limit d is based on distances from source words to translation slots, rather than distances between source words as in the Moses system [7]. 7 %BLEU no sw constraints 13.12 sw constraints with CBCBP 16.73 Table 6: %BLEU on test set, showing the contribution of the source word consistency constraints. from both aligning to non-null slots (i.e., one must align to ∅). We include a factor between two sources phrases if there is a translation phrase that may relate to both, namely ⟨sp1, sp2⟩∈E if ∃tp : ⟨sp1, tp⟩∈E, ⟨sp2, tp⟩∈E. The source phrase separation potential θsp1,sp2(xsp1, xsp2) is −∞if either xsp1 = xsp2 ̸= ∅or sp1 ∩sp2 ̸= ∅∧xsp1 ̸= ∅∧xsp2 ̸= ∅. Otherwise, it is −γd|(δ(sp1, sp2)− |xsp1 −xsp2|)|, where δ(sp1, sp2) returns the number of source words between the spans sp1 and sp2. This favors similar distances between source phrases and their aligned slots. Experimental Setup: We consider German-to-English translation. As training data for constructing the phrase table, we use the WMT2011 parallel data [2], which contains 1.9M sentence pairs. We use the phrase table to compute θsp,tp and to fill Xtp. We use a bigram language model estimated from the English side of the parallel data along with 601M tokens of randomly-selected sentences from the Linguistic Data Consortium’s Gigaword corpus. This is used when computing the θtp−1,tp potentials. As our test set, we use the first 150 sentences from the WMT2009 test set. Results below are (uncased) %BLEU scores [17] on this 150-sentence set. We use maximum phrase length m = 3 and distortion limit d = 3. We run 250 iterations of CBCBP for each sentence. For the feature weights (γ), we use the default weights in Moses, since our features are analogous to theirs. Learning the weights is left to future work. Results: We compare to a simplified version of our model that omits the sw variables and all constraints and terms pertaining to them. This variation still contains all sp and tp variables and their factors. This comparison shows the contribution of our novel handling of consistency constraints. Tab. 6 shows our results. The consistency constraints lead to a large improvement for our model at negligible increase in runtime due to our closed-form update rules. We found it impractical to attempt to obtain these results using the standard CBP algorithm for any source sentences of typical length. For comparison to a standard benchmark, we also trained a Moses system [7], a state-of-the-art phrase-based system, on the same data. We used default settings and feature weights, except we used max phrase length 3 and no lexicalized reordering model, in order to more closely match the setting of our model. The Moses %BLEU on this dataset is 17.88. When using the source word consistency constraints, we are within 1.2% of Moses. Our model has the virtue of being able to compute marginals for downstream applications and also permits us to study particular forms of constraints in phrase-based translation modeling. Future work can add or remove constraints like we did in our experiments here in order to determine the most effective constraints for phrase-based translation. Our efficient inference framework makes such exploration possible. 5 Related Work Variational approaches to inference have been extensively studied in the past. We address approximate inference using the entropy barrier function and there has been extensive work in this direction, e.g., [24, 14, 23, 5, 19, 20] to name a few. Our work differs since we incorporate consistency constraints within the inference engine. We show that closed-form update rules are still available. Consistency constraints are implied when using PN-potentials [9]. However, pairwise functions are included for every constraint which is expensive if many constraints are involved. In contrast, constraints over the feasible instances are considered in [22, 13, 16, 12, 1]. While impressive results have been shown, each different restrictions of the feasible set may require a tailored algorithm. In contrast, we propose to include probabilistic equalities among the model beliefs, which permits derivation of an algorithm that is generally applicable. 6 Conclusions In this work we tackled the problem of inference with belief based equality constraints, which arises when consistency among variables in the network is required. We introduced the CBCBP algorithm that directly incorporates constraints into the CBP framework and results in closed-form update rules. We demonstrated the merit of CBCBP both on synthetic data and on two real-world tasks. Our experiments indicate that CBCBP outperforms PN-potentials in both speed and accuracy. In the future we intend to incorporate our approximate inference with consistency constraints into learning frameworks, e.g., [15, 3]. 8 References [1] S. Bach, M. Broecheler, L. Getoor, and D. O’leary. Scaling mpe inference for constrained continuous markov random fields with consensus optimization. In Advances in Neural Information Processing Systems, pages 2654–2662, 2012. [2] C. Callison-Burch, P. Koehn, C. Monz, and O. Zaidan. Findings of the 2011 Workshop on Statistical Machine Translation. In Proc. of WMT, 2011. [3] L.-C. Chen∗, A. G. Schwing∗, A. L. Yuille, and R. Urtasun. Learning Deep Structured Models. In Proc. ICML, 2015. ∗equal contribution. [4] M. Everingham, L. Van Gool, C. Williams, J. Winn, and A. Zisserman. The pascal visual object classes challenge 2012 (voc2012). http://www.pascal-network.org/challenges/VOC/voc2012/workshop/index.html, 2012. [5] T. Hazan, J. Peng, and A. Shashua. Tightening fractional covering upper bounds on the partition function for high-order region graphs. In Proc. UAI, 2012. [6] T. Heskes. On the uniqueness of loopy belief propagation fixed points. Neural Computation, 16(11):2379– 2413, 2004. [7] P. Koehn, H. Hoang, A. Birch, C. Callison-Burch, M. Federico, N. Bertoldi, B. Cowan, W. Shen, C. Moran, R. Zens, C. Dyer, O. Bojar, A. Constantin, and E. Herbst. Moses: Open source toolkit for statistical machine translation. In Proc. of ACL, 2007. [8] P. Koehn, F. J. Och, and D. Marcu. Statistical phrase-based translation. In Proceedings of the 2003 Conference of the North American Chapter of the Association for Computational Linguistics on Human Language Technology-Volume 1, pages 48–54. Association for Computational Linguistics, 2003. [9] P. Kohli, P. H. Torr, et al. Robust higher order potentials for enforcing label consistency. International Journal of Computer Vision, 82(3):302–324, 2009. [10] D. Koller and N. Friedman. Probabilistic graphical models: principles and techniques. MIT press, 2009. [11] L. Ladicky, C. Russell, P. Kohli, and P. H. Torr. Graph cut based inference with co-occurrence statistics. In Computer Vision–ECCV 2010, pages 239–253. Springer, 2010. [12] A. F. Martins, M. A. Figeuiredo, P. M. Aguiar, N. A. Smith, and E. P. Xing. An augmented lagrangian approach to constrained map inference. 2011. [13] A. F. T. Martins. The geometry of constrained structured prediction: applications to inference and learning of natural language syntax. PhD thesis, Columbia University, 2012. [14] T. Meltzer, A. Globerson, and Y. Weiss. Convergent message passing algorithms-a unifying view. In UAI, 2009. [15] O. Meshi, D. Sontag, T. Jaakkola, and A. Globerson. Learning efficiently with approximate inference via dual losses. In Proc. ICML, 2010. [16] S. Nowozin and C. H. Lampert. Global connectivity potentials for random field models. In Computer Vision and Pattern Recognition, 2009. CVPR 2009. IEEE Conference on, pages 818–825. IEEE, 2009. [17] K. Papineni, S. Roukos, T. Ward, and W. Zhu. BLEU: a method for automatic evaluation of machine translation. In Proc. of ACL, 2002. [18] A. G. Schwing, S. Fidler, M. Pollefeys, and R. Urtasun. Box In the Box: Joint 3D Layout and Object Reasoning from Single Images. In Proc. ICCV, 2013. [19] A. G. Schwing, T. Hazan, M. Pollefeys, and R. Urtasun. Distributed Message Passing for Large Scale Graphical Models. In Proc. CVPR, 2011. [20] A. G. Schwing, T. Hazan, M. Pollefeys, and R. Urtasun. Globally Convergent Dual MAP LP Relaxation Solvers using Fenchel-Young Margins. In Proc. NIPS, 2012. [21] J. Shotton, M. Johnson, and R. Cipolla. Semantic texton forests for image categorization and segmentation. In Computer vision and pattern recognition, 2008. CVPR 2008. IEEE Conference on, pages 1–8. IEEE, 2008. [22] D. A. Smith and J. Eisner. Dependency parsing by belief propagation. In Proceedings of the Conference on Empirical Methods in Natural Language Processing, pages 145–156. Association for Computational Linguistics, 2008. [23] D. Tarlow, D. Batra, P. Kohli, and V. Kolmogorov. Dynamic tree block coordinate ascent. ICML, pages 113–120, 2011. [24] M. J. Wainwright, T. S. Jaakkola, and A. S. Willsky. A new class of upper bounds on the log partition function. Trans. on Information Theory, 51(7):2313–2335, 2005. [25] M. J. Wainwright and M. I. Jordan. Graphical models, exponential families, and variational inference. Foundations and Trends R⃝in Machine Learning, 1(1-2):1–305, 2008. 9 | 2016 | 498 |
6,436 | Data driven estimation of Laplace-Beltrami operator Frédéric Chazal Inria Saclay Palaiseau France frederic.chazal@inria.fr Ilaria Giulini Inria Saclay Palaiseau France ilaria.giulini@me.com Bertrand Michel Ecole Centrale de Nantes Laboratoire de Mathématiques Jean Leray (UMR 6629 CNRS) Nantes France bertrand.michel@ec-nantes.fr Abstract Approximations of Laplace-Beltrami operators on manifolds through graph Laplacians have become popular tools in data analysis and machine learning. These discretized operators usually depend on bandwidth parameters whose tuning remains a theoretical and practical problem. In this paper, we address this problem for the unnormalized graph Laplacian by establishing an oracle inequality that opens the door to a well-founded data-driven procedure for the bandwidth selection. Our approach relies on recent results by Lacour and Massart [LM15] on the so-called Lepski’s method. 1 Introduction The Laplace-Beltrami operator is a fundamental and widely studied mathematical tool carrying a lot of intrinsic topological and geometric information about the Riemannian manifold on which it is defined. Its various discretizations, through graph Laplacians, have inspired many applications in data analysis and machine learning and led to popular tools such as Laplacian EigenMaps [BN03] for dimensionality reduction, spectral clustering [VL07], or semi-supervised learning [BN04], just to name a few. During the last fifteen years, many efforts, leading to a vast literature, have been made to understand the convergence of graph Laplacian operators built on top of (random) finite samples to LaplaceBeltrami operators. For example pointwise convergence results have been obtained in [BN05] (see also [BN08]) and [HAL07], and a (uniform) functional central limit theorem has been established in [GK06]. Spectral convergence results have also been proved by [BN07] and [VLBB08]. More recently, [THJ11] analyzed the asymptotic of a large family of graph Laplacian operators by taking the diffusion process approach previously proposed in [NLCK06]. Graph Laplacians depend on scale or bandwidth parameters whose choice is often left to the user. Although many convergence results for various metrics have been established, little is known about how to rigorously and efficiently tune these parameters in practice. In this paper we address this problem in the case of unnormalized graph Laplacian. More precisely, given a Riemannian manifold M of known dimension d and a function f : M →R , we consider the standard unnormalized graph Laplacian operator defined by ˆ∆hf(y) = 1 nhd+2 X i K y −Xi h [f(Xi) −f(y)] , y ∈M, 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. where h is a bandwidth, X1, . . . , Xn is a finite point cloud sampled on M on which the values of f can be computed, and K is the Gaussian kernel: for y ∈Rm K(y) = 1 (4π)d/2 e−∥y∥2 m/4, (1) where ∥y∥m is the Euclidean norm in the ambiant space Rm. In this case, previous results (see for instance [GK06]) typically say that the bandwidth parameter h in ˆ∆h should be taken of the order of n− 1 d+2+α for some α > 0, but in practice, for a given point cloud, these asymptotic results are not sufficient to choose h efficiently. In the context of neighbor graphs [THJ11] proposes self-tuning graphs by choosing h locally in terms of the distances to the k-nearest neighbor, but note that k still need to be chosen and moreover as far as we know there is no guarantee for such method to be rate-optimal. More recently a data driven method for spectral clustering has been proposed in [Rie15]. Cross validation [AC+10] is the standard approach for tuning parameters in statistics and machine learning. Nevertheless, the problem of choosing h in ˆ∆h is not easy to rewrite as a cross validation problem, in particular because there is no obvious contrast corresponding to the problem (see [AC+10]). The so-called Lepski’s method is another popular method for selecting the smoothing parameter of an estimator. The method has been introduced by Lepski [Lep92b, Lep93, Lep92a] for kernel estimators and local polynomials for various risks and several improvements of the method have then been proposed, see [LMS97, GL09, GL+08]. In this paper we adapt Lepski’s method for selecting h in the graph Laplacian estimator ˆ∆h. Our method is supported by mathematical guarantees: first we obtain an oracle inequality - see Theorem 3.1 - and second we obtain the correct rate of convergence - see Theorem 3.3 - already proved in the asymptotical studies of [BN05] and [GK06] for non data-driven choices of the bandwidth. Our approach follows the ideas recently proposed in [LM15], but for the specific problem of Laplacian operators on smooth manifolds. In this first work about the data-driven estimation of Laplace-Beltrami operator, we focus as in [BN05] and [GK06] on the pointwise estimation problem: we consider a smooth function f on M and the aim is to estimate ˆ∆hf for the L2-norm ∥· ∥2,M on M ⊂Rm. The data driven method presented here may be adapted and generalized for other types of risks (uniform norms on functional family and convergence of the spectrum) and other types of graph Laplacian operators, this will be the subject of future works. The paper is organized as follows: Lepski’s method is introduced in Section 2. The main results are stated in Section 3 and a sketch of their proof is given in Section 4 (the complete proofs are given in the supplementary material). A numerical illustration and a discussion about the proposed method are given in Sections 5 and 6 respectively. 2 Lepski’s procedure for estimating the Laplace-Beltrami operator All the Riemannian manifolds considered in the paper are smooth compact d-dimensional submanifolds (without boundary) of Rm endowed with the Riemannian metric induced by the Euclidean structure of Rm. Recall that, given a compact d-dimensional smooth Riemannian manifold M with volume measure µ, its Laplace-Beltrami operator is the linear operator ∆defined on the space of smooth functions on M as ∆(f) = −div(∇f) where ∇f is the gradient vector field and div the divergence operator. In other words, using the Stoke’s formula, ∆is the unique linear operator satisfying Z M ∥∇f∥2dµ = Z M ∆(f)fdµ. Replacing the volume measure µ by a distribution P which is absolutely continuous with respect to µ , the weighted Laplace-Beltrami operator ∆P is defined as ∆Pf = ∆f + 1 p⟨∇p, ∇f⟩, (2) where p is the density of P with respect to µ. The reader may refer to classical textbooks such as, e.g., [Ros97] or [Gri09] for a general and detailed introduction to Laplace operators on manifolds. In the following, we assume that we are given n points X1, . . . , Xn sampled on M according to the distribution P. Given a smooth function f on M, the aim is to estimate ∆Pf, by selecting 2 an estimator in a given finite family of graph Laplacian ( ˆ∆hf)h∈H, where H is a finite family of bandwidth parameters. Lepski’s procedure is generally presented as a method for selecting bandwidth in an adaptive way. More generally, this method can be seen as an estimator selection procedure. 2.1 Lepski’s procedure We first shortly explain the ideas of Lepski’s method. Consider a target quantity s, a collection of estimators (ˆsh)h∈H and a loss function ℓ(·, ·). A standard objective when selecting ˆsh is trying to minimize the risk Eℓ(s, ˆsh) among the family of estimators. In most settings, the risk of an estimator can be decomposed into a bias part and a variance part. Of course neither the risk, the bias nor the variance of an estimator are known in practice. However in many cases, the variance term can be controlled quite precisely. Lepski’s method requires that the variance of each estimator ˆsh can be tightly upper bounded by a quantity v(h). In most cases, the bias can be written as ℓ(s, ¯sh) where ¯sh corresponds to some (deterministic) averaged version of ˆsh. It thus seems natural to estimate ℓ(s, ¯sh) by ℓ(ˆsh′, ˆsh) for some h′ smaller than h. The later quantity incorporates some randomness while the bias does not. The idea is to remove the “random part" of the estimation by considering [ℓ(ˆsh′, ˆsh) −v(h) −v(h′)]+, where [ ]+ denotes the positive part. The bias term is estimated by considering all pairs of estimators (sh, ˆsh′) through the quantity suph′≤h [ℓ(ˆsh′, ˆsh) −v(h) −v(h′)]+. Finally, the estimator minimizing the sum of the estimated bias and variance is selected, see eq. (3) below. In our setting, the control of the variance of the graph Laplacian estimators ˆ∆h is not tight enough to directly apply the above described method. To overcome this issue, we use a more flexible version of Lepski’s method that involves some multiplicative coefficients a and b introduced in the variance and bias terms. More precisely, let V (h) = Vf(h) be an upper bound for E[∥(E[ ˆ∆h] −ˆ∆h)f∥2 2,M]. The bandwidth ˆh selected by our Lepski’s procedure is defined by ˆh = ˆhf = arg min h∈H {B(h) + bV (h)} (3) where B(h) = Bf(h) = max h′≤h, h′∈H h ∥( ˆ∆h′ −ˆ∆h)f∥2 2,M −aV (h′) i + (4) with 0 < a ≤b. The calibration of the constants a and b in practice is beyond the scope of this paper, but we suggest a heuristic procedure inspired from [LM15] in section 5. 2.2 Variance of the graph Laplacian for smooth functions In order to control the variance term, we consider for this paper the set F of smooth functions f : M →R uniformly bounded up to the third order. For some constant CF > 0 , let F = n f ∈C3(M, R) , ∥f (k)∥∞≤CF, k = 0, . . . , 3 o . (5) We introduce some notation before giving the variance term for f ∈F. Define Dα = 1 (4π)d Z Rd C∥u∥α+2 d 2 + C1∥u∥α d e−∥u∥2 d/4 du (6) ˜Dα = 1 (4π)d/2 Z Rd C∥u∥α+2 d 4 + C1∥u∥α d e−∥u∥2 d/8 du (7) where C and C1 are geometric constants that only depend on the metric structure of M (see Appendix). We also introduce the d-dimensional Gaussian kernel on Rd: Kd(u) = 1 (4π)d/2 e−∥u∥2 d/4, u ∈Rd and we denote by ∥· ∥p,d the Lp-norm on Rd. The next proposition provides an explicit bound V (h) on the variance term. 3 Proposition 2.1. Given h ∈H, for any f ∈F, we have V (h) = C2 F nhd+2 2ωd ∥Kd∥2 2,d + αd(h) , where αd(h) = h2 2D4 + D + 3ωd ∥Kd∥2 2,d + h4 D6 + 3D 2 (8) with D = 3µ(M) (4π)d/2 and ωd = 3 × 2d/2−1. 3 Results We now give the main result of the paper: an oracle inequality for the estimator ˆ∆ˆh, or in other words, a bound on the risk that shows that the performance of the estimator is almost as good as it would be if we knew the risks of each estimator. In particular it performs an (almost) optimal trade-off between the variance term V (h) and the approximation term D(h) = Df(h) = max ∥(p∆P −E[ ˆ∆h])f∥2,M, sup h′≤h ∥(E[ ˆ∆h′] −E[ ˆ∆h])f∥2,M ≤2 sup h′≤h ∥(p∆P −E[ ˆ∆h′])f∥2,M. Theorem 3.1. According to the notation introduced in the previous section, let ϵ = √a/2 −1 and δ(h) = X h′≤h max exp −min{ϵ2, ϵ}√n 24 , exp −cϵ2γd(h′) where c > 0 is an absolute constant and γd(h′) = 1 ∥p∥∞h′d " 2ωd ∥Kd∥2 2,d + αd(h′) (2ωd ∥Kd∥1,d + βd(h))2 # with αd defined by (8) and βd(h) = 2hωd ∥Kd∥1,d + h2(2 ˜D3 + D) + h3( ˜D4 + D). (9) Given f ∈C2(M, R), with probability at least 1 −2 P h∈H δ(h), ∥(p∆P −ˆ∆ˆh)f∥2,M ≤inf h∈H n 3D(h) + (1 + √ 2) p bV (h) o . Broadly speaking, Theorem 3.1 says that there exists an event of large probability for which the estimator selected by Lepski’s method is almost as good as the best estimator in the collection. Note that the size of the bandwidth family H has an impact on the probability term 1 −2 P h∈H δ(h). If H is not too large, an oracle inequality for the risk of ˆ∆ˆhf can be easily deduced from the later result. Henceforth we assume that f ∈F. We first give a control on the approximation term D(h). Proposition 3.2. Assume that the density p is C2. It holds that D(h) ≤γ CFh where CF is defined in eq. (5) and γ > 0 is a constant depending on ∥p∥∞, ∥p′∥∞, ∥p′′∥∞and on M. We consider the following grid of bandwidths: H = e−k , ⌈log log(n)⌉≤k ≤⌊log(n)⌋ . The previous results lead to the pointwise rate of convergence of the graph Laplacian selected by Lepski’s method: Theorem 3.3. Assume that the density p is C2. For any f ∈F, we have E h ∥(p∆P −ˆ∆ˆh)f∥2,M i ≲n− 1 d+4 . (10) 4 4 Sketch of the proof of theorem 3.1 We observe that the following inequality holds ∥(p∆P −ˆ∆ˆh)f∥2,M ≤D(h) + ∥(E[ ˆ∆h] −ˆ∆h)f∥2,M + p 2 (B(h) + bV (h)). (11) Indeed, for h ∈H, ∥(p∆P −ˆ∆ˆh)f∥2,M ≤∥(p∆P −∆h)f∥2,M + ∥(∆h −ˆ∆h)f∥2,M + ∥( ˆ∆h −ˆ∆ˆh)f∥2,M ≤D(h) + ∥(∆h −ˆ∆h)f∥2,M + ∥( ˆ∆h −ˆ∆ˆh)f∥2,M. By definition of B(h), for any h′ ≤h, ∥( ˆ∆h′ −ˆ∆h)f∥2 2,M ≤B(h) + aV (h′) ≤B(max{h, h′}) + aV (min{h, h′}), so that, according to the definition of ˆh in eq. (3) and recalling that a ≤b, ∥( ˆ∆ˆh −ˆ∆h)f∥2 2,M ≤2 [B(h) + aV (h)] ≤2 [B(h) + bV (h)] which proves eq. (11). We are now going to bound the terms that appear in eq. (11). The bound for D(h) is already given in proposition 3.2, so that in the following we focus on B(h) and ∥(E[ ˆ∆h] −ˆ∆h)f∥2,M. More precisely the bounds we present in the next two propositions are based on the following lemma from [LM15]. Lemma 4.1. Let X1, . . . , Xnbe an i.i.d. sequence of variables. Let eS a countable set of functions and let η(s) = 1 n P i [gs(Xi) −E[gs(Xi)]] for any s ∈eS. Assume that there exist constants θ and vg such that for any s ∈eS ∥gs∥∞≤θ and Var[gs(X)] ≤vg. Denote H = E[sups∈e S η(s)]. Then for any ϵ > 0 and any H′ ≥H P " sup s∈e S η(s) ≥(1 + ϵ)H′ # ≤max exp −ϵ2nH′2 6vg , exp −min{ϵ, 1}ϵnH′ 24 θ . Proposition 4.2. Let ϵ = √a 2 −1. Given h ∈H, define δ1(h) = X h′≤h max exp −min{ϵ2, ϵ}√n 24 , exp −2ϵ2 3 γd(h′) . With probability at least 1 −δ1(h) B(h) ≤2D(h)2. Proposition 4.3. Let ˜ϵ = √a −1. Given h ∈H define δ2(h) = max exp −min{˜ϵ2, ˜ϵ}√n 24 , exp −˜ϵ2 24γd(h) . With probability at least 1 −δ2(h) ∥(E[ ˆ∆h] −ˆ∆h)f∥2,M ≤ p aV (h). Combining the above propositions with eq. (11), we get that, for any h ∈H, with probability at least 1 −(δ1(h) + δ2(h)), ∥(p∆P −ˆ∆ˆh)f∥2,M ≤D(h) + p aV (h) + p 4D(h)2 + 2bV (h) ≤3D(h) + (1 + √ 2) p bV (h) where we have used the fact that a ≤b. Taking a union bound on h ∈H we conclude the proof. 5 5 Numerical illustration In this section we illustrate the results of the previous section on a simple example. In section 5.1, we describe a practical procedure when the data set X is sampled according to the uniform measure on M. A numerical illustration us given in Section 5.2 when M is the unit 2-dimensional sphere in R3. 5.1 Practical application of the Lepksi’s method Lepski’s method presented in Section 2 can not be directly applied in practice for two reasons. First, we can not compute the L2-norm ∥∥2,M on M, the manifold M being unknown. Second, the variance terms involved in Lepski’s method are not completely explicit. Regarding the first issue, we can approximate ∥∥2,M by splitting the data into two samples: an estimation sample X1 for computing the estimators and a validation sample X2 for evaluating this norm. More precisely, given two estimators ˆ∆hf and ˆ∆h′f computed using X1, the quantity ∥( ˆ∆h −ˆ∆h′)f∥2 2,M/µ(M) is approximated by the averaged sum 1 n2 P x∈X2 | ˆ∆hf(x) −ˆ∆h′f(x)|2, where n2 is the number of points in X2. We use these approximations to evaluate the bias terms B(h) defined by (4). The second issue comes from the fact that the variance terms involved in Lepski’s method depend on the metric properties of the manifold and on the sampling density, which are both unknown. Theses variance terms are thus only known up to a multiplicative constant. This situation contrasts with more standard frameworks for which a tight and explicit control on the variance terms can be proposed, as in [Lep92b, Lep93, Lep92a]. To address this second issue, we follow the calibration strategy recently proposed in [LM15] (see also [LMR16]). In practice we remove all the multiplicative constants from V (h): all these constants are passed into the terms a and b. This means that we rewrite Lepski’s method as follows: ˆh(a, b) = arg min h∈H B(h) + b 1 nh4 where B(h) = max h′≤h, h′∈H ∥( ˆ∆h′ −ˆ∆h)f∥2 2,M −a 1 nh′4 + . We choose a and b according to the following heuristic: 1. Take b = a and consider the sequence of selected models: ˆh(a, a), 2. Starting from large values of a, make a decrease and find the location a0 of the main bandwidth jump in the step function a 7→ˆh(a, a), 3. Select the model ˆh(a0, 2a0). The justification of this calibration method is currently the subject of mathematical studies ([LM15]). Note that a similar strategy called "slope heuristic" has been proposed for calibrating ℓ0 penalties in various settings by strong mathematical results, see for instance [BM07, AM09, BMM12]. 5.2 Illustration on the sphere In this section we illustrate the complete method on a simple example with data points generated uniformly on the sphere S2 in R3. In this case, the weighted Laplace-Beltrami operator is equal to the (non weighted) Laplace-Beltrami operator on the sphere. We consider the function f(x, y, z) = (x2 + y2 + z) sin x cos x. The restriction of this function on the sphere has the following representation in spherical coordinates: ˜f(θ, φ) = (sin2 φ + cos φ) sin(sin φ cos θ) cos(sin φ cos θ). It is well known that the Laplace-Beltrami operator on the sphere satisfies (see Section 3 in [Gri09]): ∆S2u = 1 sin2 φ ∂2u ∂θ2 + 1 sin φ ∂ ∂φ sin φ∂u ∂φ for any smooth polar function u. This allows us to derive an analytic expression of ∆S2 ˜f. 6 We sample n1 = 106 points on the sphere for computing the graph Laplacians and we use n = 103 points for approximating the norms ∥( ˆ∆h −ˆ∆h′) ˜f∥2 2,M. We compute the graph Laplacians for bandwidths in a grid H between 0.001 and 0.8 (see fig. 1). The risk of each graph Laplacian is estimated by a standard Monte Carlo procedure (see fig. 2). Figure 1: Choosing h is crucial for estimating ∆S2 ˜f: small bandwidth overfits ∆S2 ˜f whereas large bandwidth leads to almost constant approximation functions of ∆S2 ˜f. Figure 2: Estimation of the risk of each graph Laplacian operator: the oracle Laplacian is for approximatively h = 0.15. Figure 3 illustrates the calibration method. On this picture, the x-axis corresponds to the values of a and the y-axis represents the bandwidths. The blue step function represents the function a 7→ˆh(a, a). The red step function gives the model selected by the rule a 7→ˆh(a, 2a). Following the heuristics given in Section 5.1, one could take for this example the value a0 ≈3.5 (location of the bandwidth jump for the blue curve) which leads to select the model ˆh(a0, 2a0) ≈0.2 (red curve). 6 Discussion This paper is a first attempt for a complete and well-founded data driven method for inferring LaplaceBeltrami operators from data points. Our results suggest various extensions and raised some questions of interest. For instance, other versions of the graph Laplacian have been studied in the literature (see 7 Figure 3: Bandwidth jump heuristic: find the location of the jump (blue curve) and deduce the selected bandwidth with the red curve. for instance [HAL07, BN08]), for instance when data is not sampled uniformly. It would be relevant to propose a bandwidth selection method for these alternative estimators also. From a practical point of view, as explained in section 5, there is a gap between the theory we obtain in the paper and what can be done in practice. To fill this gap, a first objective is to prove an oracle inequality in the spirit of Theorem 3.1 for a bias term defined in terms of the empirical norms computed in practice. A second objective is to propose mathematically well-founded heuristics for the calibration of the parameters a and b. Tuning bandwidths for the estimation of the spectrum of the Laplace-Beltrami operator is a difficult but important problem in data analysis. We are currently working on the adaptation of our results to the case of operator norms and spectrum estimation. Appendix: the geometric constants C and C1 The following classical lemma (see, e.g. [GK06][Prop. 2.2 and Eq. 3.20]) relates the constants C and C1 introduced in Equations (6) and (7) to the geometric structure of M. Lemma 6.1. There exist constants C, C1 > 0 and a positive real number r > 0 such that for any x ∈M, and any v ∈TxM such that ∥v∥≤r, q det(gij)(v) −1 ≤C1∥v∥2 d and 1 2∥v∥2 d ≤∥v∥2 d −C∥v∥4 d ≤∥Ex(v) −x∥2 m ≤∥v∥2 d (12) where Ex : TxM →M is the exponential map and (gi,j)i,j ∈{1, · · · , d} are the components of the metric tensor in any normal coordinate system around x. Although the proof of the lemma is beyond the scope of this paper, notice that one can indeed give explicit bounds on r and C in terms of the reach and injectivity radius of the submanifold M. Acknowledgments The authors are grateful to Pascal Massart for helpful discussions on Lepski’s method. This work was supported by the ANR project TopData ANR-13-BS01-0008 and ERC Gudhi No. 339025 References [AC+10] Sylvain Arlot, Alain Celisse, et al. A survey of cross-validation procedures for model selection. Statistics surveys, 4:40–79, 2010. [AM09] Sylvain Arlot and Pascal Massart. Data-driven calibration of penalties for least-squares regression. The Journal of Machine Learning Research, 10:245–279, 2009. 8 [BM07] Lucien Birgé and Pascal Massart. Minimal penalties for gaussian model selection. Probability theory and related fields, 138(1-2):33–73, 2007. [BMM12] Jean-Patrick Baudry, Cathy Maugis, and Bertrand Michel. Slope heuristics: overview and implementation. Statistics and Computing, 22(2):455–470, 2012. [BN03] Mikhail Belkin and Partha Niyogi. Laplacian eigenmaps for dimensionality reduction and data representation. Neural computation, 15(6):1373–1396, 2003. [BN04] Mikhail Belkin and Partha Niyogi. Semi-supervised learning on riemannian manifolds. Machine learning, 56(1-3):209–239, 2004. [BN05] Mikhail Belkin and Partha Niyogi. Towards a theoretical foundation for laplacian-based manifold methods. In Learning theory, pages 486–500. Springer, 2005. [BN07] Mikhail Belkin and Partha Niyogi. Convergence of laplacian eigenmaps. Advances in Neural Information Processing Systems, 19:129, 2007. [BN08] Mikhail Belkin and Partha Niyogi. Towards a theoretical foundation for laplacian-based manifold methods. Journal of Computer and System Sciences, 74(8):1289–1308, 2008. [GK06] E. Giné and V. Koltchinskii. Empirical graph laplacian approximation of laplace–beltrami operators: Large sample results. In High dimensional probability, pages 238–259. IMS, 2006. [GL+08] Alexander Goldenshluger, Oleg Lepski, et al. Universal pointwise selection rule in multivariate function estimation. Bernoulli, 14(4):1150–1190, 2008. [GL09] A. Goldenshluger and O. Lepski. Structural adaptation via lp-norm oracle inequalities. Probability Theory and Related Fields, 143(1-2):41–71, 2009. [Gri09] Alexander Grigoryan. Heat kernel and analysis on manifolds, volume 47. American Mathematical Soc., 2009. [HAL07] M. Hein, JY Audibert, and U.von Luxburg. Graph laplacians and their convergence on random neighborhood graphs. Journal of Machine Learning Research, 8(6), 2007. [Lep92a] Oleg V Lepski. On problems of adaptive estimation in white gaussian noise. Topics in nonparametric estimation, 12:87–106, 1992. [Lep92b] OV Lepskii. Asymptotically minimax adaptive estimation. i: Upper bounds. optimally adaptive estimates. Theory of Probability & Its Applications, 36(4):682–697, 1992. [Lep93] OV Lepskii. Asymptotically minimax adaptive estimation. ii. schemes without optimal adaptation: Adaptive estimators. Theory of Probability & Its Applications, 37(3):433–448, 1993. [LM15] Claire Lacour and Pascal Massart. Minimal penalty for goldenshluger-lepski method. arXiv preprint arXiv:1503.00946, 2015. [LMR16] Claire Lacour, Pascal Massart, and Vincent Rivoirard. Estimator selection: a new method with applications to kernel density estimation. arXiv preprint arXiv:1607.05091, 2016. [LMS97] Oleg V Lepski, Enno Mammen, and Vladimir G Spokoiny. Optimal spatial adaptation to inhomogeneous smoothness: an approach based on kernel estimates with variable bandwidth selectors. The Annals of Statistics, pages 929–947, 1997. [NLCK06] B. Nadler, S. Lafon, RR Coifman, and IG Kevrekidis. Diffusion maps, spectral clustering and reaction coordinates of dynamical systems. Applied and Computational Harmonic Analysis, 21(1):113– 127, 2006. [Rie15] Antonio Rieser. A topological approach to spectral clustering. arXiv:1506.02633, 2015. [Ros97] Steven Rosenberg. The Laplacian on a Riemannian manifold: an introduction to analysis on manifolds. Number 31. Cambridge University Press, 1997. [THJ11] Daniel Ting, Ling Huang, and Michael Jordan. An analysis of the convergence of graph laplacians. arXiv preprint arXiv:1101.5435, 2011. [VL07] Ulrike Von Luxburg. A tutorial on spectral clustering. Statistics and computing, 17(4):395–416, 2007. [VLBB08] Ulrike Von Luxburg, Mikhail Belkin, and Olivier Bousquet. Consistency of spectral clustering. The Annals of Statistics, pages 555–586, 2008. 9 | 2016 | 499 |
6,437 | Conditional Generative Moment-Matching Networks Yong Ren, Jialian Li, Yucen Luo, Jun Zhu∗ Dept. of Comp. Sci. & Tech., TNList Lab; Center for Bio-Inspired Computing Research State Key Lab for Intell. Tech. & Systems, Tsinghua University, Beijing, China {renyong15, luoyc15, jl12}@mails.tsinghua.edu.cn; dcszj@tsinghua.edu.cn Abstract Maximum mean discrepancy (MMD) has been successfully applied to learn deep generative models for characterizing a joint distribution of variables via kernel mean embedding. In this paper, we present conditional generative momentmatching networks (CGMMN), which learn a conditional distribution given some input variables based on a conditional maximum mean discrepancy (CMMD) criterion. The learning is performed by stochastic gradient descent with the gradient calculated by back-propagation. We evaluate CGMMN on a wide range of tasks, including predictive modeling, contextual generation, and Bayesian dark knowledge, which distills knowledge from a Bayesian model by learning a relatively small CGMMN student network. Our results demonstrate competitive performance in all the tasks. 1 Introduction Deep generative models (DGMs) characterize the distribution of observations with a multilayered structure of hidden variables under nonlinear transformations. Among various deep learning methods, DGMs are natural choice for those tasks that require probabilistic reasoning and uncertainty estimation, such as image generation [1], multimodal learning [30], and missing data imputation. Recently, the predictive power, which was often shown inferior to pure recognition networks (e.g., deep convolutional networks), has also been significantly improved by employing the discriminative max-margin learning [18]. For the arguably more challenging unsupervised learning, [5] presents a generative adversarial network (GAN), which adopts a game-theoretical min-max optimization formalism. GAN has been extended with success in various tasks [21, 1]. However, the min-max formalism is often hard to solve. The recent work [19, 3] presents generative moment matching networks (GMMN), which has a simpler objective function than GAN while retaining the advantages of deep learning. GMMN defines a generative model by sampling from some simple distribution (e.g., uniform) followed through a parametric deep network. To learn the parameters, GMMN adopts maximum mean discrepancy (MMD) [7], a moment matching criterion where kernel mean embedding techniques are used to avoid unnecessary assumptions of the distributions. Back-propagation can be used to calculate the gradient as long as the kernel function is smooth. A GMMN network estimates the joint distribution of a set of variables. However, we are more interested in a conditional distribution in many cases, including (1) predictive modeling: compared to a generative model that defines the joint distribution p(x, y) of input data x and response variable y, a conditional model p(y|x) is often more direct without unnecessary assumptions on modeling x, and leads to better performance with fewer training examples [23, 16]; (2) contextual generation: in some cases, we are interested in generating samples based on some context, such as class labels [21], visual attributes [32] or the input information in cross-modal generation (e.g., from image to text [31] ∗Corresponding author 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. or vice versa [2]); and (3) building large networks: conditional distributions are essential building blocks of a large generative probabilistic model. One recent relevant work [1] provides a good example of stacking multiple conditional GAN networks [21] in a Laplacian pyramid structure to generate natural images. In this paper, we present conditional generative moment-matching networks (CGMMN) to learn a flexible conditional distribution when some input variables are given. CGMMN largely extends the capability of GMMN to address a wide range of application problems as mentioned above, while keeping the training process simple. Specifically, CGMMN admits a simple generative process, which draws a sample from a simple distribution and then passes the sample as well as the given conditional variables through a deep network to generate a target sample. To learn the parameters, we develop conditional maximum mean discrepancy (CMMD), which measures the HilbertSchmidt norm (generalized Frobenius norm) between the kernel mean embedding of an empirical conditional distribution and that of our generative model. Thanks to the simplicity of the conditional generative model, we can easily draw a set of samples to estimate the kernel mean embedding as well as the CMMD objective. Then, optimizing the objective can be efficiently implemented via back-propagation. We evaluate CGMMN in a wide range of tasks, including predictive modeling, contextual generation, and Bayesian dark knowledge [15], an interesting case of distilling dark knowledge from Bayesian models. Our results on various datasets demonstrate that CGMMN can obtain competitive performance in all these tasks. 2 Preliminary In this section, we briefly review some preliminary knowledge, including maximum mean discrepancy (MMD) and kernel embedding of conditional distributions. 2.1 Hilbert Space Embedding We begin by providing an overview of Hilbert space embedding, where we represent distributions by elements in a reproducing kernel Hilbert space (RKHS). A RKHS F on X with kernel k is a Hilbert space of functions f : X →R. Its inner product ⟨·, ·⟩F satisfies the reproducing property: ⟨f(·), k(x, ·)⟩F = f(x). Kernel functions are not restricted on Rd. They can also be defined on graphs, time series and structured objects [11]. We usually view φ(x) := k(x, ·) as a (usually infinite dimension) feature map of x. The most interesting part is that we can embed a distribution by taking expectation on its feature map: µX := EX[φ(X)] = ! Ω φ(X)dP(X). If EX[k(X, X)] ≤∞, µX is guaranteed to be an element in the RKHS. This kind of kernel mean embedding provides us another perspective on manipulating distributions whose parametric forms are not assumed, as long as we can draw samples from them. This technique has been widely applied in many tasks, including feature extractor, density estimation and two-sample test [27, 7]. 2.2 Maximum Mean Discrepancy Let X = {xi}N i=1 and Y = {yi}M j=1 be the sets of samples from distributions PX and PY , respectively. Maximum Mean Discrepancy (MMD), also known as kernel two sample test [7], is a frequentist estimator to answer the query whether PX = PY based on the observed samples. The basic idea behind MMD is that if the generating distributions are identical, all the statistics are the same. Formally, MMD defines the following difference measure: MMD[K, PX, PY ] := sup f∈K (EX[f(X)] −EY [f(Y )]), where K is a class of functions. [7] found that the class of functions in a universal RKHS F is rich enough to distinguish any two distributions and MMD can be expressed as the difference of their mean embeddings. Here, universality requires that k(·, ·) is continuous and F is dense in C(X) with respect to the L∞norm, where C(X) is the space of bounded continuous functions on X. We summarize the result in the following theorem: Theorem 1 [7] Let K be a unit ball in a universal RKHS F, defined on the compact metric space X, with an associated continuous kernel k(·, ·). When the mean embedding µp, µq ∈F, the MMD objective function can be expressed as MMD[K, p, q] = ∥µp −µq∥2 F. Besides, MMD[K, p, q] = 0 if and only if p = q. 2 In practice, an estimate of the MMD objective compares the square difference between the empirical kernel mean embeddings: "L2 MMD = ###### 1 N N $ i=1 φ(xi) −1 M M $ j=1 φ(yi) ###### 2 F , which can be easily evaluated by expanding the square and using the associated kernel k(·, ·). Asymptotically, "L2 MMD is an unbiased estimator. 2.3 Kernel Embedding of Conditional Distributions The kernel embedding of a conditional distribution P(Y |X) is defined as: µY |x := EY |x[φ(Y )] = % Ωφ(y)dP(y|x). Unlike the embedding of a single distribution, the embedding of a conditional distribution is not a single element in RKHS, but sweeps out a family of points in the RKHS, each indexed by a fixed value of x. Formally, the embedding of a conditional distribution is represented as an operator CY |X, which satisfies the following properties: 1. µY |x = CY |Xφ(x); 2. EY |x[g(Y )|x] = ⟨g, µY |x⟩G, (1) where G is the RKHS corresponding to Y . [29] found that such an operator exists under some assumptions, using the technique of crosscovariance operator CXY : G →F: CXY := EXY [φ(X) ⊗φ(Y )] −µX ⊗µY , where ⊗is the tensor product. An interesting property is that CXY can also be viewed as an element in the tensor product space G ⊗F. The result is summarized as follows. Theorem 2 [29] Assuming that EY |X[g(Y )|X] ∈F, the embedding of conditional distributions CY |X defined as CY |X := CY XC−1 XX satisfies properties 1 and 2. Given a dataset DXY = {(xi, yi)}N i=1 of size N drawn i.i.d. from P(X, Y ), we can estimate the conditional embedding operator as "CY |X = Φ(K +λI)−1Υ⊤, where Φ = (φ(y1), ..., φ(yN)), Υ = (φ(x1), ..., φ(xN)), K = Υ⊤Υ and λ serves as regularization. The estimator is an element in the tensor product space F ⊗G and satisfies properties 1 and 2 asymptotically. When the domain of X is finite, we can also estimate C−1 XX and CY X directly (See Appendix A.2.2 for more details). 3 Conditional Generative Moment-Matching Networks We now present CGMMN, including a conditional maximum mean discrepancy criterion as the training objective, a deep generative architecture and a learning algorithm. 3.1 Conditional Maximum Mean Discrepancy Given conditional distributions PY |X and PZ|X, we aim to test whether they are the same in the sense that when X = x is fixed whether PY |x = PZ|x holds or not. When the domain of X is finite, a straightforward solution is to test whether PY |x = PZ|x for each x separately by using MMD. However, this is impossible when X is continuous. Even in the finite case, as the separate tests do not share statistics, we may need an extremely large number of training data to test a different model for each single value of x. Below, we present a conditional maximum mean discrepancy criterion, which avoids the above issues. Recall the definition of kernel mean embedding of conditional distributions. When X = x is fixed, we have the kernel mean embedding µY |x = CY |Xφ(x). As a result, if we have CY |X = CZ|X, then µY |x = µZ|x is also satisfied for every fixed x. By the virtue of Theorem 1, that PY |x = PZ|x follows as the following theorem states. Theorem 3 Assuming that F is a universal RKHS with an associated kernel k(·, ·), EY |X[g(Y )|X] ∈F, EZ|X[g(Z)|X] ∈F and CY |X, CZ|X ∈F ⊗G. If the embedding of conditional distributions CY |X = CZ|X, then PY |X = PZ|X in the sense that for every fixed x, we have PY |x = PZ|x. 3 The above theorem gives us a sufficient condition to guarantee that two conditional distributions are the same. We use the operators to measure the difference of two conditional distributions and we call it conditional maximum mean discrepancy (CMMD), which is defined as follows: L2 CMMD = ##CY |X −CZ|X ##2 F⊗G . Suppose we have two sample sets Ds XY = {(xi, yi)}N i=1 and Dd XY = {(xi, yi)}M i=1. Similar as in MMD, in practice we compare the square difference between the empirical estimates of the conditional embedding operators: "L2 CMMD = ### "Cd Y |X −"Cs Y |X ### 2 F⊗G , where the superscripts s and d denote the two sets of samples, respectively. For notation clarity, we define &K = K +λI. Then, using kernel tricks, we can compute the difference only in term of kernel gram matrices: "L2 CMMD = ##Φd(Kd + λI)−1Υ⊤ d −Φs(Ks + λI)−1Υ⊤ s ##2 F⊗G =Tr ' Kd &K−1 d Ld &K−1 d ( + Tr ' Ks &K−1 s Ls &K−1 s ( −2 · Tr ' Ksd &K−1 d Lds &K−1 s ( , (2) where Φd := (φ(yd 1), ..., φ(yd N)) and Υd := (φ(xd 1), ..., φ(xd N)) are implicitly formed feature matrices, Φs and Υs are defined similarly for dataset Ds XY . Kd = Υ⊤ d Υd and Ks = Υ⊤ s Υs are the gram matrices for input variables, while Ld = Φ⊤ d Φd and Ls = Φ⊤ s Φs are the gram matrices for output variables. Finally, Ksd = Υ⊤ s Υd and Lds = Φ⊤ d Φs are the gram matrices between the two datasets on input and out variables, respectively. It is worth mentioning that we have assumed that the conditional mean embedding operator CY |X ∈ F ⊗G to have the CMMD objective well-defined, which needs some smoothness assumptions such that C−3/2 XX CXY is Hilbert-Schmidt [8]. In practice, the assumptions may not hold, however, the empirical estimator Φ(K + λI)−1Υ⊤is always an element in the tensor product space which gives as a well-justified approximation (i.e., the Hilbert-Schmidt norm exists) for practical use [29]. Remark 1 Taking a close look on the objectives of MMD and CMMD, we can find some interesting connections. Suppose N = M. By omitting the constant scalar, the objective function of MMD can be rewritten as "L2 MMD = Tr(Ld · 1) + Tr(Ls · 1) −2 · Tr(Lds · 1), where 1 is the matrix with all entities equaling to 1. The objective function of CMMD can be expressed as "L2 CMMD = Tr(Ld · C1) + Tr(Ls · C2) −2 · Tr(Lds · C3), where C1, C2, C3 are some matrices based on the conditional variables x in both data sets. The difference is that instead of putting uniform weights on the gram matrix as in MMD, CMMD applies non-uniform weights, reflecting the influence of conditional variables. Similar observations have been shown in [29] for the conditional mean operator, where the estimated conditional embedding µY |x is a non-uniform weighted combination of φ(xi). 3.2 CGMMN Nets We now present a conditional DGM and train it by the CMMD criterion. One desirable property of the DGM is that we can easily draw samples from it to estimate the CMMD objective. Below, we present such a network that takes both the given conditional variables and an extra set of random variables as inputs, and then passes through a deep neural network with nonlinear transformations to produce the samples of the target variables. Specifically, our network is built on the fact that for any distribution P on sample space K and any continuous distribution Q on L that are regular enough, there is a function G : L →K such that G(x) ∼P, where x ∼Q [12]. This fact has been recently explored by [3, 19] to define a deep generative model and estimate the parameters by the MMD criterion. For a conditional model, we would like the function G to depend on the given values of input variables. This can be fulfilled via a process as illustrated in Fig. 1, where the inputs of a deep neural network (DNN) consist of two parts — the input variables x and an extra set of stochastic variables H ∈Rd that follow some continuous distribution. For simplicity, we put a uniform prior on each hidden unit p(h) = d) i=1 U(hi), where U(h) = I(0≤h≤1) is a uniform distribution on [0, 1] and I(·) is the indicator 4 function that equals to 1 if the predicate holds and 0 otherwise. After passing both x and h through the DNN, we get a sample from the conditional distribution P(Y |x): y = f(x, h|w), where f denotes the deterministic mapping function represented by the network with parameters w. By default, we concatenate x and h and fill &x = (x, h) into the network. In this case, we have y = f(&x|w). Figure 1: An example architecture of CGMMN networks. Due to the flexibility and rich capability of DNN on fitting nonlinear functions, this generative process can characterize various conditional distributions well. For example, a simple network can consist of multiple layer perceptrons (MLP) activated by some non-linear functions such as the rectified linear unit (ReLu) [22]. Of course the hidden layer is not restricted to MLP, as long as it supports gradient propagation. We also use convolutional neural networks (CNN) as hidden layers [25] in our experiments. It is worth mentioning that there exist other ways to combine the conditional variables x with the auxiliary variables H. For example, we can add a corruption noise to the conditional variables x to produce the input of the network, e.g., define &x = x + h, where h may follow a Gaussian distribution N(0, ηI) in this case. With the above generative process, we can train the network by optimizing the CMMD objective with proper regularization. Specifically, let Ds XY = {(xd i , yd i )}N i=1 denote the given training dataset. To estimate the CMMD objective, we draw a set of samples from the above generative model, where the conditional variables can be set by sampling from the training set with/without small perturbation (More details are in the experimental section). Thanks to its simplicity, the sampling procedure can be easily performed. Precisely, we provide each x in the training dataset to the generator to get a new sample and we denote Dd XY = {(xs i, ys i )}M i=1 as the generated samples. Then, we can optimize the CMMD objective in Eq. (2) by gradient descent. See more details in Appendix A.1. Algorithm 1 Stochastic gradient descent for CGMMN 1: Input: Dataset D = {(xi, yi)}N i=1 2: Output: Learned parameters w 3: Randomly divide training dataset D into mini batches 4: while Stopping criterion not met do 5: Draw a minibatch B from D; 6: For each x ∈B, generate a y; and set B′ to contain all the generated (x, y); 7: Compute the gradient ∂! L2 CMMD ∂w on B and B′; 8: Update w using the gradient with proper regularizer. 9: end while Note that the inverse matrices &K−1 s and &K−1 d in the CMMD objective are independent of the model parameters, suggesting that we are not restricted to use differentiable kernels on the conditional variables x. Since the computation cost for kernel gram matrix grows cubically with the sample size, we present an mini-batch version algorithm in Alg. 1 and some discussions can be found in Appendix A.2.1. 4 Experiments We now present a diverse range of applications to evaluate our model, including predictive modeling, contextual generation and an interesting case of Bayesian dark knowledge [15]. Our results demonstrate that CGMMN is competitive in all the tasks. 4.1 Predictive Performance 4.1.1 Results on MNIST dataset We first present the prediction performance on the widely used MINIST dataset, which consists of images in 10 classes. Each image is of size 28 × 28 and the gray-scale is normalized to be in range [0, 1]. The whole dataset is divided into 3 parts with 50, 000 training examples, 10, 000 validation examples and 10, 000 testing examples. For prediction task, the conditional variables are the images x ∈[0, 1]28×28, and the generated sample is a class label, which is represented as a vector y ∈R10 + and each yi denotes the confidence that x is in class i. We consider two types of architectures in CGMMN — MLP and CNN. 5 Table 1: Error rates (%) on MNIST dataset Model Error Rate VA+Pegasos [18] 1.04 MMVA [18] 0.90 CGMMN 0.97 CVA + Pegasos [18] 1.35 CGMMN-CNN 0.47 Stochastic Pooling [33] 0.47 Network in Network [20] 0.47 Maxout Network [6] 0.45 CMMVA [18] 0.45 DSN [17] 0.39 We compare our model, denoted as CGMMN in the MLP case and CGMMN-CNN in the CNN case, with Varitional Auto-encoder (VA) [14], which is an unsupervised DGM learnt by stochastic variational methods. To use VA for classification, a subsequent classifier is built — We first learn feature representations by VA and then learn a linear SVM on these features using Pegasos algorithm [26]. We also compare with max-margin DGMs (denoted as MMVA with MLP as hidden layers and CMMVA in the CNN case) [18], which is a state-of-the-art DGM for prediction, and several other strong baselines, including Stochastic Pooling [33], Network in Network [20], Maxout Network [6] and Deeply-supervised nets (DSN) [17]. In the MLP case, the model architecture is shown in Fig. 1 with an uniform distribution for hidden variables of dimension 5. Note that since we do not need much randomness for the prediction task, this low-dimensional hidden space is sufficient. In fact, we did not observe much difference with a higher dimension (e.g., 20 or 50), which simply makes the training slower. The MLP has 3 hidden layers with hidden unit number (500, 200, 100) with the ReLu activation function. A minibatch size of 500 is adopted. In the CNN case, we use the same architecture as [18], where there are 32 feature maps in the first two convolutional layers and 64 feature maps in the last three hidden layers. An MLP of 500 hidden units is adopted at the end of convolutional layers. The ReLu activation function is used in the convoluational layers and sigmoid function in the last layer. We do not pre-train our model and a minibatch size of 500 is adopted as well. The total number of parameters in the network is comparable with the competitors [18, 17, 20, 6]. In both settings, we use AdaM [13] to optimize parameters. After training, we simply draw a sample from our model conditioned on the input image and choose the index of maximum element of y as its prediction.Table 1 shows the results. We can see that CGMMN-CNN is competitive with various state-of-the-art competitors that do not use data augumentation or multiple model voting (e.g., CMMVA). DSN benefits from using more supervision signal in every hidden layer and outperforms the other competitors. 4.1.2 Results on SVHN dataset Table 2: Error rates (%) on SVHN dataset Model Error Rate CVA+Pegasos [18] 25.3 CGMMN-CNN 3.13 CNN [25] 4.9 CMMVA [18] 3.09 Stochastic Pooling [33] 2.80 Network in Network [20] 2.47 Maxout Network [6] 2.35 DSN [17] 1.92 We then report the prediction performance on the Street View House Numbers (SVHN) dataset. SVHN is a large dataset consisting of color images of size 32 × 32 in 10 classes. The dataset consists of 598, 388 training examples, 6, 000 validation examples and 26, 032 testing examples. The task is significantly harder than classifying hand-written digits. Following [25, 18], we preprocess the data by Local Contrast Normalization (LCN). The architecture of out network is similar to that in MNIST and we only use CNN as middle layers here. A minibatch size of 300 is used and the other settings are the same as the MNIST experiments. Table 2 shows the results. Through there is a gap between our CGMMN and some discriminative deep networks such as DSN, our results are comparable with those of CMMVA, which is the stateof-the-art DGM for prediction. CGMMN is compatible with various network architectures and we are expected to get better results with more sophisticated structures. 4.2 Generative Performance 4.2.1 Results on MNIST dataset We first test the generating performance on the widely used MNIST dataset. For generating task, the conditional variables are the image labels. Since y takes a finite number of values, as mentioned in Sec. 2.3, we estimate CY X and C−1 XX directly and combine them as the estimation of CY |X (See Appendix A.2.2 for practical details). The architecture is the same as before but exchanging the position of x and y. For the input layer, besides the label information y as conditional variables (represented by a one-hot-spot vector of dimension 10), we further draw a sample from a uniform distribution of dimension 20, which is 6 (a) MNIST samples (b) Random CGMMN samples (c) Samples conditioned on label 0 Figure 2: Samples in (a) are from MNIST dataset; (b) are generated randomly from our CGMMN network; (c) are generated randomly from CGMMN with conditions on label y = 0. Both (b) and (c) are generated after running 500 epoches. sufficiently large. Overall, the network is a 5-layer MLP with input dimension 30 and the middle layer hidden unit number (64, 256, 256, 512), and the output layer is of dimension 28 × 28, which represents the image in pixel. A minibatch of size 200 is adopted. Fig. 2 shows some samples generated using our CGMMN, where in (b) the conditional variable y is randomly chosen from the 10 possible values, and in (c) y is pre-fixed at class 0. As we can see, when conditioned on label 0, almost all the generated samples are really in that class. Figure 3: CGMMN samples and their nearest neighbour in MNIST dataset. The first row is our generated samples. As in [19], we investigate whether the models learn to merely copy the data. We visualize the nearest neighbors in the MNIST dataset of several samples generated by CGMMN in terms of Euclidean pixelwise distance [5] in Fig. 3. As we can see, by this metric, the samples are not merely the copy. Figure 4: Samples generated by CGMMN+Autoencoder, where the architecture follows from [19]. As also discussed in [19], real-world data can be complicated and high-dimensional and autoencoder can be good at representing data in a code space that captures enough statistical information to reliably reconstruct the data. For example, visual data, while represented in a high dimension often exists on a low-dimensional manifold. Thus it is beneficial to combine autoencoders with our CGMMN models to generate more smooth images, in contrast to Fig. 2 where there are some noise in the generated samples. Precisely, we first learn an auto-encoder and produce code representations of the training data, then freeze the auto-encoder weights and learn a CGMMN to minimize the CMMD objective between the generated codes using our CGMMN and the training data codes. The generating results are shown in Fig. 4. Comparing to Fig. 2, the samples are more clear. 4.2.2 Results on Yale Face dataset We now show the generating results on the Extended Yale Face dataset [9], which contains 2, 414 grayscale images for 38 individuals of dimension 32 × 32. There are about 64 images per subject, one per different facial expression or configuration. A smaller version of the dataset consists of 165 images of 15 individuals and the generating result can be found in Appendix A.4.2. We adopt the same architecture as the first generating experiment for MNIST, which is a 5-layer MLP with an input dimension of 50 (12 hidden variables and 38 dimensions for conditional variables, i.e., labels) and the middle layer hidden unit number (64, 256, 256, 512). A mini-batch size of 400 is adopted. The other settings are the same as in the MNIST experiment. The overall generating results are shown in Fig. 5, where we really generate diverse images for different individuals. Again, as shown in Appendix A.4.1, the generated samples are not merely the copy of training data. 4.3 Distill Bayesian Models Our final experiment is to apply CGMMN to distill knowledge from Bayesian models by learning a conditional distribution model for efficient prediction. Specifically, let θ denote the ran7 dom variables. A Bayesian model first computes the posterior distribution given the training set D = {(xi, yi)}N i=1 as p(θ|D). In the prediction stage, given a new input x, a response sample y is generated via probability p(y|x, D) = % p(y|x, θ)p(θ|D)dθ. This procedure usually involves a complicated integral thus is time consuming. [15] show that we can learn a relatively simple student network to distill knowledge from the teacher network (i.e., the Bayesian model) and approximately represent the predictive distribution p(y|x, D) of the teacher network. Figure 5: CGMMN generated samples for Extended Yale Face Dataset. Columns are conditioned on different individuals. Our CGMMN provides a new solution to build such a student network for Bayesian dark knowledge. To learn CGMMN, we need two datasets to estimate the CMMD objective — one is generated by the teacher network and the other one is generated by CGMMN. The former sampled dataset serves as the training dataset for our CGMMN and the latter one is generated during the training process of it. For high-dimensional data, adopting the same strategy as [15], we sample “near" the training data to generate the former dataset (i.e., perturbing the inputs in the training set slightly before sending to the teacher network to sample y). Due to the space limitation, we test our model on a regression problem on the Boston housing dataset, which was also used in [15, 10], while deferring the other results on a synthetic dataset to Appendix A.3. The dataset consists of 506 data points where each data is of dimension 13. We first train a PBP model [10], which is a scalable method for posterior inference in Bayesian neural networks, as the teacher and then distill it using our CGMMN model. We test whether the distilled model will degrade the prediction performance. Table 3: Distilling results on Boston Housing dataset, the error is measured by RMSE PBP prediction Distilled by CGMMN 2.574 ± 0.089 2.580 ± 0.093 We distill the PBP model [10] using an MLP network with three hidden layers and (100, 50, 50) hidden units for middle layers. We draw N = 3, 000 sample pairs {(xi, yi)}N i=1 from the PBP network, where xi is the input variables that serve as conditional variables in our model. For a fair comparison, xi is generated by adding noise into training data to avoid fitting the testing data directly. We evaluate the prediction performance on the original testing data by root mean square error (RMSE). Table 3 shows the results. We can see that the distilled model does not harm the prediction performance. It is worth mentioning that we are not restricted to distill knowledge from PBP. In fact, any Bayesian models can be distilled using CGMMN. 5 Conclusions and Discussions We present conditional generative moment-matching networks (CGMMN), which is a flexible framework to represent conditional distributions. CGMMN largely extends the ability of previous DGM based on maximum mean discrepancy (MMD) while keeping the training process simple as well, which is done by back-propagation. Experimental results on various tasks, including predictive modeling, data generation and Bayesian dark knowledge, demonstrate competitive performance. Conditional modeling has been practiced as a natural step towards improving the discriminative ability of a statistical model and/or relaxing unnecessary assumptions of the conditional variables. For deep learning models, sum product networks (SPN) [24] provide exact inference on DGMs and its conditional extension [4] improves the discriminative ability; and the recent work [21] presents a conditional version of the generative adversarial networks (GAN) [5] with wider applicability. Besides, the recent proposed conditional variational autoencoder [28] also works well on structured prediction. Our work fills the research void to significantly improve the applicability of momentmatching networks. Acknowledgments The work was supported by the National Basic Research Program (973 Program) of China (No. 2013CB329403), National NSF of China Projects (Nos. 61620106010, 61322308, 61332007), the Youth Top-notch Talent Support Program, and the Collaborative Projects with Tencent and Intel. 8 References [1] E. Denton, S. Chintala, A. Szlam, and R. Fergus. Deep generative image models using a laplacian pyramid of adversarial networks. NIPS, 2015. [2] A. Dosovitskiy, J. Springenberg, M. Tatarchenko, and T. Brox. Learning to generate chairs, tables and cars with convolutional networks. arXiv:1411.5928, 2015. [3] G. Dziugaite, D. Roy, and Z. Ghahramani. Training generative neural networks via maximum mean discrepancy optimization. UAI, 2015. [4] R. Gens and P. Domingos. Discriminative learning of sum-product networks. NIPS, 2012. [5] I. Goodfellow, J. Pouget-Abadie, M. Mirza, B. Xu, D. Warde-Farley, S. Ozair, A. Courville, and Y. Bengio. Generative adverisarial nets. NIPS, 2014. [6] I. Goodfellow, D. Warde-Farley, M. Mirza, A. Courville, and Y. Bengio. Maxout networks. ICML, 2013. [7] A. Gretton, K. Borgwardt, M. Rasch, B. Scholkopf, and A. Smola. A kernel two-sample test. JMLR, 2008. [8] S. Grunewalder, G. Lever, L. Baldassarre, S. Patterson, A. Gretton, and M. Pontil. Conditional mean embedding as regressors. ICML, 2012. [9] X. He, S. Yan, Y. Hu, P. Niyogi, and H. Zhang. Face recognition using laplacianfaces. IEEE Trans. Pattern Anal. Mach. Intelligence, 27(3):328–340, 2005. [10] J. Hernandez-Lobato and R. Adams. Probabilistic backpropagation for scalable learning of bayesian neural networks. ICML, 2015. [11] T. Hofmann, B. Scholkopf, and A. Smola. Kernel methods in machine learning. The Annals of Statistics, 36(3):1171–1220, 2008. [12] O. Kallenbery. Foundations of modern probability. New York: Springer, 2002. [13] D. Kingma and J. Ba. Adam: A method for stochastic optimization. ICLR, 2015. [14] D. Kingma and M. Welling. Auto-encoding variational bayes. ICLR, 2014. [15] A. Korattikara, V. Rathod, K. Murphy, and M. Welling. Bayesian dark knowledge. NIPS, 2015. [16] J. Lafferty, A. McCallum, and F. Pereira. Conditional random fields: Probabilistic models for segmenting and labeling sequence data. ICML, 2001. [17] C. Lee, S. Xie, P. Gallagher, Z. Zhang, and Z. Tu. Deeply-supervised nets. AISTATS, 2015. [18] C. Li, J. Zhu, T. Shi, and B. Zhang. Max-margin deep generative models. NIPS, 2015. [19] Y. Li, K. Swersky, and R. Zemel. Generative moment matching networks. ICML, 2015. [20] M. Lin, Q. Chen, and S. Yan. Network in network. ICLR, 2014. [21] M. Mirza and S. Osindero. Conditional generative adversarial nets. ArXiv:1411.1784v1, 2014. [22] V. Nair and G. Hinton. Rectified linear units improve restricted boltzmann machines. ICML, 2010. [23] A. Ng and M.I. Jordan. On discriminative vs. generative classifiers: a comparison of logistic regression and naive bayes. NIPS, 2001. [24] H. Poon and P. Domingos. Sum-product networks: A new deep architecture. UAI, 2011. [25] P. Sermanet, S. Chintala, and Y. Lecun. Convolutional neural networks applied to house numbers digit classification. ICPR, 2012. [26] S. Shalev-Shwartz, Y. Singer, N. Srebro, and A. Cotter. Pegasos: Primal estimated sub-gradient solver for svm. Mathmetical Programming, Series B, 2011. [27] A. Smola, A. Gretton, L. Song, and B. Scholkopf. A hilbert space embedding for distributions. International Conference on Algorithmic Learning Theory, 2007. [28] K. Sohn, X. Yan, and H. Lee. Learning structured output representation using deep conditional generative models. NIPS, 2015. [29] L. Song, J. Huang, A. Smola, and K. Fukumizu. Hilbert space embeddings of conditional distributions with applications to dynamical systems. ICML, 2009. [30] N. Srivastava and R. Salakhutdinov. Multimodal learning with deep boltzmann machines. NIPS, 2012. [31] O. Vinyals, A. Toshev, S. Bengio, and D. Erhan. Show and tell: A neural image caption generator. arXiv:1411.4555v2, 2015. [32] X. Yan, J. Yang, K. Sohn, and H. Lee. Attribute2image: Conditional image generation from visual attributes. arXiv:1512.00570, 2015. [33] M. Zeiler and R. Fergus. Stochastic pooling for regularization of deep convolutional neural networks. ICLR, 2013. 9 | 2016 | 5 |
6,438 | Learning Bayesian networks with ancestral constraints Eunice Yuh-Jie Chen and Yujia Shen and Arthur Choi and Adnan Darwiche Computer Science Department University of California Los Angeles, CA 90095 {eyjchen,yujias,aychoi,darwiche}@cs.ucla.edu Abstract We consider the problem of learning Bayesian networks optimally, when subject to background knowledge in the form of ancestral constraints. Our approach is based on a recently proposed framework for optimal structure learning based on non-decomposable scores, which is general enough to accommodate ancestral constraints. The proposed framework exploits oracles for learning structures using decomposable scores, which cannot accommodate ancestral constraints since they are non-decomposable. We show how to empower these oracles by passing them decomposable constraints that they can handle, which are inferred from ancestral constraints that they cannot handle. Empirically, we demonstrate that our approach can be orders-of-magnitude more efficient than alternative frameworks, such as those based on integer linear programming. 1 Introduction Bayesian networks learned from data are broadly used for classification, clustering, feature selection, and to determine associations and dependencies between random variables, in addition to discovering causes and effects; see, e.g., [Darwiche, 2009, Koller and Friedman, 2009, Murphy, 2012]. In this paper, we consider the task of learning Bayesian networks optimally, subject to background knowledge in the form of ancestral constraints. Such constraints are important in practice as they allow one to assert direct or indirect cause-and-effect relationships (or lack thereof) between random variables. Further, one expects that their presence should improve the efficiency of the learning process as they reduce the size of the search space. However, nearly all mainstream approaches for optimal structure learning make a fundamental assumption, that the scoring function (i.e., the prior and likelihood) is decomposable. This in turn limits their ability to integrate ancestral constraints, which are non-decomposable. Such approaches only support structure-modular constraints such as the presence or absence of edges, or order-modular constraints such as pairwise constraints on topological orderings; see, e.g., [Koivisto and Sood, 2004, Parviainen and Koivisto, 2013]. Recently, a new framework has been proposed for optimal Bayesian network structure learning [Chen et al., 2015], but with non-decomposable priors and scores. This approach is based on navigating the seemingly intractable search space over all network structures (i.e., all DAGs). This intractability can be mitigated however by leveraging an omniscient oracle that can optimally learn structures with decomposable scores. This approach led to the first system for finding optimal DAGs (i.e., model selection) given order-modular priors (a type of non-decomposable prior) [Chen et al., 2015]. The approach was also applied towards the enumeration of the k-best structures [Chen et al., 2015, 2016], where it was orders-of-magnitude more efficient than the existing state-of-the-art [Tian et al., 2010, Cussens et al., 2013, Chen and Tian, 2014]. 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. In this paper, we show how to incorporate non-decomposable constraints into the structure learning approach of Chen et al. [2015, 2016]. We consider learning with ancestral constraints, and inferring decomposable constraints from ancestral constraints to empower the oracle. In principle, structure learning approaches based on integer linear programming (ILP) and constraint programming (CP) can also represent ancestral constraints (and other non-decomposable constraints) [Jaakkola et al., 2010, Bartlett and Cussens, 2015, van Beek and Hoffmann, 2015].1 We empirically evaluate the proposed approach against those based on ILP, showing orders of magnitude improvements. This paper is organized as follows. In Section 2, we review the problem of Bayesian network structure learning. In Section 3, we discuss ancestral constraints and how they relate to existing structure learning approaches. In Section 4, we introduce our approach for learning with ancestral constraints. In Section 5, we show how to infer decomposable constraints from non-decomposable ancestral constraints. We evaluate our approach empirically in Section 6, and conclude in Section 7. 2 Technical preliminaries We use upper case letters X to denote variables and bold-face upper case letters X to denote sets of variables. We use X to denote a variable in a Bayesian network and U to denote its parents. In score-based approaches to structure learning, we are given a complete dataset D and want to learn a DAG G that optimizes a decomposable score, which aggregates scores over the DAG families XU: score(G | D) = P XU score(XU | D) (1) The MDL and BDeu scores are examples of decomposable scores; see, e.g., Darwiche [2009], Koller and Friedman [2009], Murphy [2012]. The seminal K2 algorithm is one of the first algorithms to exploit decomposable scores [Cooper and Herskovits, 1992]. The K2 algorithm optimizes Equation 1, but assumes that a DAG G is consistent with a given topological ordering σ. This assumption decomposes the structure learning problem into independent sub-problems, where we find the optimal set of parents for each variable X, from those variables that precede X in ordering σ. We can find the DAG G that optimizes Equation 1 by running the K2 algorithm on all n! variable orderings σ, and then take the DAG with the best score. Note that these n! instances share many computational sub-problems: finding the optimal set of parents for some variable X. One can aggregate these common sub-problems, leaving us with only n · 2n−1 unique sub-problems. This technique underlies a number of modern approaches to score-based structure learning, including some based on dynamic programming [Koivisto and Sood, 2004, Singh and Moore, 2005, Silander and Myllymäki, 2006], and related approaches based on heuristic search methods such as A* [Yuan et al., 2011, Yuan and Malone, 2013]. This aggregation of K2 sub-problems also corresponds to a search space called the order graph [Yuan et al., 2011, Yuan and Malone, 2013]. Bayesian network structure learning can also be formulated using integer linear programming (ILP), with Equation 1 as the linear objective function of an ILP. Further, for each variable X and candidate parent set U, we introduce an ILP variable I(X, U) ∈{0, 1} to represent the event that X has parents U when I(X, U) = 1, and I(X, U) = 0 otherwise. We then assert constraints that each variable X has a unique set of parents, P U I(X, U) = 1. Another set of constraints ensure that all variables X and their parents U must yield an acyclic graph. One approach is to use cluster constraints [Jaakkola et al., 2010], where for each cluster C ⊆X, at least one variable X in C has no parents in C, P X∈C P U∩C=∅I(X, U) ≥1. Finally, we have the objective function of our ILP, P X∈X P U⊆X\X score(XU | D) · I(X, U), which corresponds to Equation 1. 3 Ancestral constraints An ancestral constraint specifies a relation between two variables X and Y in a DAG G. If X is an ancestor of Y , then there is a directed path connecting X to Y in G. If X is not an ancestor of Y , then there is no such path. Ancestral constraints can be used, for example, to express background knowledge in the form of cause-and-effect relations between variables. When X is an ancestor of Y , we have a positive ancestral constraint, denoted X ⇝Y . When X is not an ancestor of Y , we have a 1To our knowledge, however, the ILP and CP approaches have not been previously evaluated, in terms of their efficacy in structure learning with ancestral constraints. 2 X1 . . . X1 X1 X1 X1 X1 X1 X1 G0 X2 X2 X2 X2 X2 X2 X2 X1 X1 X1 X1 X1 X3 X3 X3 X3 X3 X3 X3 X2 X3 X3 X3 X3 X3 X3 X2 X2 X2 X2 X2 (a) A BN graph X1 . . . P0 X2 X1 X2 X1 X2 X3 X2 X3 X2 X3 X1 X3 X1 X3 X1 X1 X1 X1 X1 X2 X3 X3 X3 X3 X3 X2 X2 X2 X2 151116 (b) A EC Tree Figure 1: Bayesian network search spaces for the set of variables X = {X1, X2, X3}. negative ancestral constraint, denoted X ̸⇝Y . In this case, there is no directed path from X to Y , but there may still be a directed path from Y to X. Positive ancestral constraints are transitive, i.e., if X ⇝Y and Y ⇝Z then X ⇝Z. Negative ancestral constraints are not transitive. Ancestral constraints are non-decomposable since we cannot in general check whether an ancestral constraint is satisfied or violated by independently checking the parents of each variable. For example, consider an optimal DAG, compatible with ordering ⟨X1, X2, X3⟩, from the family scores: X U score X U score X U score X1 {} 1 X2 {}, {X1} 1, 2 X3 {}, {X1}, {X2}, {X1, X2} 10, 10, 1, 10 The optimal DAG (with minimal score) in this case is X1 X2 →X3 . If we assert the ancestral constraint X1 ⇝X3, then the optimal DAG is X1 →X2 →X3 . Yet, we cannot enforce this ancestral constraints using independent, local constraints on the parents that each variable can take. In particular, the choice of parents for variable X2 and the choice of parents for variable X3 will jointly determine whether X1 is an ancestor of X3. Hence, the K2 algorithm and approaches based on the order graph (dynamic programming and heuristic search) cannot enforce ancestral constraints. These approaches, however, can enforce decomposable constraints, such as the presence or absence of an edge U →X, or a limit on the size of a family XU. Interestingly, one can infer some decomposable constraints from non-decomposable ones. We discuss this technique extensively later, showing how it can lead to significant impact on the efficiency of structure search. Structure learning approaches based on ILP can in principle enforce non-decomposable constraints, when they can be encoded as linear constraints. In fact, ancestral relations have been employed in ILPs and other formalisms to enforce a graph’s acyclicity; see, e.g., [Cussens, 2008]. However, to our knowledge, these approaches have not been evaluated for learning structures with ancestral constraints. We provide such an empirical evaluation in Section 6.2 4 Learning with constraints In this section, we review two recently proposed search spaces for learning Bayesian networks: the BN graph and the EC tree [Chen et al., 2015, 2016]. We subsequently show how we can adapt the EC tree to facilitate the learning of Bayesian network structures under ancestral constraints. 4.1 BN graphs The BN graph is a search space for learning structures with non-decomposable scores [Chen et al., 2015]. Figure 1(a) shows a BN graph over 3 variables, where nodes represent DAGs over different subsets of variables. A directed edge Gi XU −−→Gj from a DAG Gi to a DAG Gj exists in the BN graph iff Gj can be obtained from Gi by adding a leaf node X with parents U. Each edge has a cost, corresponding to the score of the family XU, as in Equation 1. Hence, a path from the root G0 to a DAG Gn yields the score of the DAG, score(Gn | D). As a result, the shortest path in the BN graph (the one with the lowest score) corresponds to an optimal DAG, as in Equation 1. 2We also make note of Borboudakis and Tsamardinos [2012], which uses ancestral constraints (path constraints) for constraint-based learning methods, such as the PC algorithm. Borboudakis and Tsamardinos [2013] further proposes a prior based on path beliefs (soft constraints), and evaluated using greedy local search. 3 Unlike the order graph, the BN graph explicitly represents all possible DAGs. Hence, ancestral constraints can be easily integrated by pruning the search space, i.e., by pruning away those DAGs that do not satisfy the given constraints. Consider Figure 1(a) and the ancestral constraint X1 ⇝X2. Since the DAG X1 X2 violates the constraint, we can prune this node, along with all of its descendants, as the descendants must also violate an ancestral constraint (adding new leaves to a DAG will not undo a violated ancestral constraint). Finding a shortest path in this pruned search space will yield an optimal Bayesian network satisfying a given set of ancestral constraints. We can use A* search to find a shortest path in a BN graph. A* is a best-first search algorithm that uses an evaluation function f to guide the search. For a given DAG G, we have the evaluation function f(G) = g(G) + h(G), where g(G) is the actual cost to reach G from the root G0, and h(G) is the estimated cost to reach a leaf from G. A* search is guaranteed to find a shortest path when the heuristic function h is admissible, i.e., it does not over-estimate. Chen et al. [2015, 2016] showed that a heuristic function can be induced by any learning algorithm that takes a (partial) DAG as input, and returns an optimal DAG that extends it. Learning systems based on the order graph fall in this category and can be viewed as powerful oracles that help us to navigate the DAG graph. We employed URLEARNING as an oracle in our experiments [Yuan and Malone, 2013]. We will later show how to empower this oracle by passing it decomposable constraints that we infer from a set of non-decomposable ancestral constraints—the impact of this empowerment turns out to be dramatic. 4.2 EC trees The EC tree is a recently proposed search space that improves the BN graph along two dimensions [Chen et al., 2016]. First, it merges Markov-equivalent nodes in the BN graph. Second, it canonizes the resulting EC graph into a tree, where each node is reachable by a unique path from the root. Two network structures are Markov equivalent iff they have the same undirected skeleton and the same v-structures. A Markov equivalence class can be represented by a completed, partially directed acyclic graph (CPDAG). The set of structures represented by a CPDAG P is denoted by class(P) and may contain exponentially many Markov equivalent structures. Figure 1(b) illustrates an EC tree over 3 variables, where nodes represent CPDAGs over different subsets of variables. A directed edge Pi XU −−→Pj from a CPDAG Pi to a CPDAG Pj exists in the EC tree iff there exists a DAG Gj ∈class(Pj) that can be obtained from a DAG Gi ∈class(Pi) by adding a leaf node X with parents U, but where X must be the largest variable in Gj (according to some canonical ordering). Each edge of an EC tree has a cost score(XU | D), so the shortest path in the EC tree corresponds to an optimal equivalence class of Bayesian networks. 4.3 EC trees and ancestral constraints A DAG G satisfies a set of ancestral constraints A (both over the same set of variables) iff the DAG G satisfies each constraint in A. Moreover, a CPDAG P satisfies A iff there exists a DAG G ∈class(P) that satisfies A. We enforce ancestral constraints by pruning a CPDAG node P from an EC tree when P does not satisfy the constraints A. First, consider an ancestral constraint X1 ̸⇝X2. A CPDAG P containing a directed path from X1 to X2 violates the constraint, as every structure in class(P) contains a path from X1 to X2. Next, consider an ancestral constraint X1 ⇝X2. A CPDAG P with no partially directed paths from X1 to X2 violates the given constraint, as no structure in class(P) contains a path from X1 to X2.3 Given a CPDAG P, we first test for these two cases, which can be done efficiently. If these tests are inconclusive, we exhaustively enumerate the structures of class(P), to check if any of them satisfies the given constraints. If not, we can prune P and its descendants from the EC tree. The soundness of this pruning step is due to the following. Theorem 1 In an EC tree, a CPDAG P satisfies ancestral constraints A, both over the same set of variables X, iff its descendants satisfy A. 5 Projecting constraints In this section, we show how one can project non-decomposable ancestral constraints onto decomposable edge and ordering constraints. For example, if G is a set of DAGs satisfying a set of ancestral 3A partially directed path from X to Y consists of undirected edges and directed edges oriented towards Y . 4 constraints A, we want to find the edges that appear in all DAGs of G. These projected constraints can be then used to improve the efficiency of structure learning. Recall (from Section 4.1) that our approach to structure learning uses a heuristic function that utilizes an optimal structure learning algorithm for decomposable scores (the oracle). We tighten this heuristic (empower the oracle) by passing to it projected edge and ordering constraints, leading to a more efficient search when we are subject to non-decomposable ancestral constraints. Given a set of ancestral constraints A, we shall show how to infer new edge and ordering constraints, that we can utilize to empower our oracle. For the case of edge constraints, we propose a simple algorithm that can efficiently enumerate all inferrable edge constraints. For the case of ordering constraints, we propose a reduction to MaxSAT, that can find a maximally large set of ordering constraints that can be jointly inferred from ancestral constraints. 5.1 Edge constraints We now propose an algorithm for finding all edge constraints that can be inferred from a set of ancestral constraints A. We consider (decomposable) constraints on the presence of an edge, or the absence of an edge. We refer to edge presence constraints as positive constraints, denoted by X →Y , and refer to edge absence constraints as negative constraints, denoted by X ̸→Y . We let E denote a set of edge constraints. We further let G(A) denote the set of DAGs G over the variables X that satisfy all ancestral constraints in the set A, and let G(E) denote the set of DAGs G that satisfy all edge constraints in E. Given a set of ancestral constraints A, we say that A entails a positive edge constraint X →Y iff G(A) ⊆G(X →Y ), and that A entails a negative edge constraint X ̸→Y iff G(A) ⊆G(X ̸→Y ). For example, consider the four DAGs over the variables X, Y and Z that satisfy ancestral constraints X ̸⇝Z and Y ⇝Z. Y Z X Y Z X Y Z X Y Z X First, we note that no DAG above contains the edge X →Z, since this would immediately violate the constraint X ̸⇝Z. Next, no DAG above contains the edge X →Y . Suppose instead that this edge appeared; since Y ⇝Z, we can infer X ⇝Z, which contradicts the existing constraint X ̸⇝Z. Hence, we can infer the negative edge constraint X ̸→Y . Finally, no DAG above contains the edge Z →Y , since this would lead to a directed cycle with the constraint Y ⇝Z. Before we present our algorithm for inferring edge constraints, we first revisit some properties of ancestral constraints that we will need. Note that given a set of ancestral constraints, we may be able to infer additional ancestral constraints. First, given two constraints X ⇝Y and Y ⇝Z, we can infer an additional ancestral constraint X ⇝Z (by transitivity of ancestral relations). Second, if adding a path X ⇝Y would create a directed cycle (e.g., if Y ⇝X exists in A), or if it would violate an existing negative ancestral constraints (e.g., if X ̸⇝Z and Y ⇝Z exists in A), then we can infer a new negative constraint X ̸⇝Y . By using a few rules based on the examples above, we can efficiently enumerate all of the ancestral constraints that are entailed by a given set of ancestral constraints (details omitted for space). Hence, we shall subsequently assume that a given set of ancestral constraints A will already include all ancestral constraints that can be entailed from it. We then refer to A as a maximum set of ancestral constraints. We now consider how to infer edge constraints from a (maximum) set of ancestral constraints A. First, let α(X) be the set that consists of X and every X′ such that X′ ⇝X ∈A, and let β(X) be the set that consists of X and every X′ such that X ⇝X′ ∈A. In other words, α(X) contains X and all nodes that are constrained to be ancestors of X by A, i.e., each X′ ∈α(X) is either X or an ancestor of X, for all DAGs G ∈G(A). Similarly, β(X) contains X and all nodes that are constrained to be descendants of X by A. First, we can check if a negative edge constraint X ̸→Y is entailed by A by enumerating all possible Xa ̸⇝Yb for all Xa ∈α(X) and all Yb ∈β(Y ). If any Xa ̸⇝Yb is in A then we know that A entails X ̸→Y . That is, since Xa ⇝X and Y ⇝Yb, then if there was a DAG G ∈G(A) with the edge X →Y , then G would also have a path from Xa to Yb. Hence, we can infer X ̸→Y . This idea is summarized by the following theorem: 5 Theorem 2 Given a maximum set of ancestral constraints A, then A entails the negative edge constraint X ̸→Y iff Xa ̸⇝Yb, where Xa ∈α(X) and Yb ∈β(Y ). Next, suppose that both (1) A dictates that X can reach Y , and that (2) A dictates that there is no path from X to Z to Y , for any other variable Z. In this case, we can infer a positive edge constraint X →Y . We can again verify if X →Y is entailed by A by enumerating all relevant candidates Z, based on the following theorem. Theorem 3 Given a maximum set of ancestral constraints A, then A entails the positive edge constraint X →Y iff A contains X ⇝Y and for all Z ̸∈α(X) ∪β(Y ), the set A contains a constraint Xa ̸⇝Zb or Za ̸⇝Yb, where Xa ∈α(X), Zb ∈β(Z), Za ∈α(Z) and Yb ∈β(Y ). 5.2 Topological ordering constraints We next consider constraints on the topological orderings of a DAG. An ordering satisfies a constraint X < Y iff X appears before Y in the ordering. Further, an ordering constraint X < Y is compatible with a DAG G iff there exists a topological ordering of DAG G that satisfies the constraint X < Y . The negation of an ordering constraint X < Y is the ordering constraint Y < X. A given ordering satisfies either X < Y or Y < X, but not both at the same time. A DAG G may be compatible with both X < Y and Y < X through two different topological orderings. We let O denote a set of ordering constraints, and let G(O) denote the set of DAGs G that are compatible with each ordering constraint in O. The task of determining whether a set of ordering constraints O is entailed by a set of ancestral constraints A, i.e., whether G(A) ⊆G(O), is more subtle than the case of edge constraints. For example, consider the set of ancestral constraints A = {Z ̸⇝Y, X ̸⇝Z}. We can infer the ordering constraint Y < Z from the first constraint Z ̸⇝Y , and Z < X from the second constraint X ̸⇝Z.4 If we were to assume both ordering constraints, we could infer the third ordering constraint Y < X, by transitivity. However, consider the following DAG G which satisfies A: X →Y Z . This DAG is compatible with the constraint Y < Z as well as the constraint Z < X, but it is not compatible with the constraint Y < X. Consider the three topological orderings of the DAG G: ⟨X, Y, Z⟩, ⟨X, Z, Y ⟩and ⟨Z, X, Y ⟩. We see that none of the orderings satisfy both ordering constraints at the same time. Hence, if we assume both ordering constraints at the same time, it eliminates all topological orderings of the DAG G, and hence the DAG itself. Consider another example over variables W, X, Y and Z with a set of ancestral constraints A = {W ̸⇝Z, Y ̸⇝X}. The following DAG G satisfies A: W →X Y →Z . However, inferring the ordering constraints Z < W and X < Y from each ancestral constraint of A leads to a cycle in the above DAG (W < X < Y < Z < W), hence eliminating the DAG. Hence, for a given set of ancestral constraints A, we want to infer from it a set O of ordering constraints that is as large as possible, but without eliminating any DAGs satisfying A. Roughly, this involves inferring ordering constraints X < Y from ancestral constraints Y ̸⇝X, as long as the ordering constraints do not induce a cycle. We propose to encode the problem as an instance of MaxSAT [Li and Manyà, 2009]. Given a maximum set of ancestral constraints A, we construct a MaxSAT instance where propositional variables represent ordering constraints and ancestral constraints (true if the constraint is present, and false otherwise). The clauses encode the ancestral constraints, as well as constraints to ensure acyclicity. By maximizing the set of satisfied clauses, we then maximize the set of constraints X < Y selected. In turn, the (decomposable) ordering constraints can be to empower an oracle during structure search. Our MaxSAT problem includes hard constraints (1-3), as well as soft constraints (4): 1. transitivity of orderings: for all X < Y , Y < Z: (X < Y ) ∧(Y < Z) ⇒(X < Z) 2. a necessary condition for orderings: for all X < Y : (X < Y ) ⇒(Y ̸⇝X) 3. a sufficient condition for acyclicity: for all X < Y and Z < W: (X < Y ) ∧(Z < W) ⇒(X ⇝Y ) ∨(Z ⇝W) ∨(X ⇝Z) ∨(Y ⇝W) ∨(X ⇝W) ∨(Y ̸⇝Z) 4. infer orderings from ancestral constraints: for all X ̸⇝Y in A: (X ̸⇝Y ) ⇒(Y < X) 4To see this, consider any DAG G satisfying Z ̸⇝Y . We can construct another DAG G′ from G by adding the edge Y →Z, since adding such an edge does not introduce a directed cycle. As a result, every topological ordering of G′ satisfies Y < Z, and G(Z ̸⇝Y ) ⊆G(Y < Z). 6 n = 10 n = 12 n = 14 N 512 2048 8192 512 2048 8192 512 2048 8192 p EC GOB EC GOB EC GOB EC GOB EC GOB EC GOB EC GOB EC GOB EC GOB 0.00 < 7.81 < 112.98 < 19.70 0.01 70.85 0.02 98.28 0.02 144.21 0.06 625.081 0.07 839.46 0.09 1349.24 0.01 < 9.61 < 15.41 < 23.58 0.01 73.39 0.01 99.46 0.01 145.75 0.05 673.003 0.06 901.50 0.08 1356.63 0.05 < 11.56 < 14.54 < 19.85 0.02 60.16 0.01 75.40 0.27 95.11 0.08 243.681 0.05 287.45 0.04 411.22 0.10 < 10.74 < 11.60 < 13.87 0.21 52.02 0.10 53.29 0.36 59.42 0.58 176.500 1.26 198.18 0.03 218.94 0.25 0.01 4.04 < 3.43 < 3.37 4.91 22.47 0.18 20.88 0.17 19.68 55.07 126.312 0.91 112.80 0.02 107.44 0.50 < 0.87 < 0.71 < 0.72 0.51 6.11 0.03 6.10 0.01 5.85 0.48 73.236 0.02 67.29 < 62.60 0.75 < 0.31 < 0.75 < 0.30 < 2.66 < 2.62 < 2.57 < 44.074 < 42.95 < 41.21 1.00 < 0.21 < 0.31 < 0.21 < 2.29 < 2.30 < 2.27 < 39.484 < 39.67 < 37.78 Table 1: Time (in sec) used by EC tree and GOBNILP to find optimal networks. < is less than 0.01 sec. n is the variable number, N is the dataset size, p is the percentage of the ancestral constraints. n = 12 n = 14 N 512 2048 8192 512 2048 8192 p EC (t/s) GOB EC (t/s) GOB EC (t/s) GOB EC (t/s) GOB EC (t/s) GOB EC (t/s) GOB 0.01 0.01 1 63.53 0.01 1 83.59 0.02 1 128.23 0.01 1 634.19 0.123 1 738.25 0.12 1 1295.90 0.05 0.06 1 55.20 0.03 1 70.20 1.18 1 90.59 0.06 1 228.57 0.868 1 276.68 0.18 1 404.35 0.10 2.56 1 50.33 2.36 1 52.80 0.91 1 57.66 2.54 1 174.70 34.979 0.98 183.93 0.60 1 210.12 0.25 70.19 0.98 23.29 4.57 1 20.74 1.63 1 21.16 280.59 0.84 137.67 88.80 1 126.80 1.85 1 126.24 0.50 137.31 1 7.74 15.53 1 7.80 1.43 1 7.36 609.18 0.88 90.92 35.62 1 85.58 4.74 1 83.81 0.75 21.86 1 4.38 1.73 1 4.39 0.50 1 4.30 258.80 1 64.51 6.49 1 63.68 2.28 1 64.04 1.00 2.31 1 4.10 0.35 1 4.07 0.15 1 4.02 21.18 1 61.44 1.39 1 60.56 0.54 1 61.06 Table 2: Time t (in sec) used by EC tree and GOBNILP to find optimal networks, without any projected constraints, using a 32G memory and 2 hour time limit. s is the percentage of test cases that finish. We remark that the above constraints are sufficient for finding a set of ordering constraints O that are entailed by a set of ancestral constraints A, which is formalized in the following theorem. Theorem 4 Given a maximum set of ancestral constraints A, and let O be a closed set of ordering constraints. The set O is entailed by A if O satisfies the following two statements: 1. for all X < Y in O, A contains Y ̸⇝X 2. for all X < Y and Z < W in O, where X, Y, Z and W are distinct, A contains at least one of X ⇝Y, Z ⇝W, X ⇝Z, Y ⇝W, X ⇝W, Y ̸⇝Z. 6 Experiments We now empirically evaluate the effectiveness of our approach to learning with ancestral constraints. We simulated different structure learning problems from standard Bayesian network benchmarks5 ALARM, ANDES, CHILD, CPCS54, and HEPAR2, by (1) taking a random sub-network N of a given size6 (2) simulating a training dataset from N of varying sizes (3) simulating a set of ancestral constraints of a given size, by randomly selecting ordered pairs whose ground-truth ancestral relations in N were used as constraints. In our experiments, we varied the number of variables in the learning problem (n), the size of the training dataset (N), and the percentage of the n(n −1)/2 total ancestral relations that were given as constraints (p). We report results that were averaged over 50 different datasets: 5 datasets were simulated from each of 2 different sub-networks, which were taken from each of the 5 original networks mentioned above. Our experiments were run on a 2.67GHz Intel Xeon X5650 CPU. We assumed BDeu scores with an equivalent sample size of 1. We further pre-computed the scores of candidate parent sets, which were fed as input into each system evaluated. Finally, we used the EVASOLVER partial MaxSAT solver, for inferring ordering constraints.7 In our first set of experiments, we compared our approach with the ILP-based system of GOBNILP,8 where we encoded ancestral constraints using linear constraints, based on [Cussens, 2008]; note again that both are exact approaches for structure learning. In Table 1, we supplied both systems with decomposable constraints inferred via projection (which empowers the oracle for searching the EC tree, and provides redundant constraints for the ILP). In Table 2, we withheld the projected 5The networks used in our experiments are available at http://www.bnlearn.com/bnrepository 6We select random sets of nodes and all their ancestors, up to a connected sub-network of a given size. 7Available at http://www.maxsat.udl.cat/14/solvers/eva500a__ 8Available at http://www.cs.york.ac.uk/aig/sw/gobnilp 7 n = 18 n = 20 N 512 2048 8192 512 2048 8192 p t s ∆ t s ∆ t s ∆ t s ∆ t s ∆ t s ∆ 0.00 2.25 1 16.74 2.78 1 8.32 3.11 1 7.06 19.40 1 23.44 20.62 1 10.60 28.22 1 7.22 0.01 2.22 1 16.58 3.46 1 8.60 3.63 1 7.38 30.38 1 23.67 30.46 1 10.53 34.34 1 7.09 0.05 41.15 0.96 15.02 2.91 0.98 6.96 2.12 1 5.56 87.74 0.96 18.44 39.25 1 8.20 17.40 1 5.00 0.10 149.40 0.94 12.72 73.03 0.96 5.81 7.35 1 3.78 492.59 0.82 14.67 185.82 0.94 7.21 24.46 0.98 3.94 0.25 251.74 0.78 6.33 338.10 0.94 3.79 30.90 0.96 1.96 507.02 0.58 6.17 572.68 0.88 4.46 153.81 0.96 2.28 0.50 95.18 0.98 5.49 13.92 0.98 2.69 116.29 0.98 1.24 163.19 0.88 6.36 46.43 0.96 2.19 70.15 1 1.07 0.75 9.07 1 3.30 5.83 1 1.66 0.72 1 0.72 1.47 1 4.49 0.28 1 1.36 0.38 1 0.60 1.00 < 1 0.72 < 1 0.48 < 1 0.26 < 1 2.02 < 1 0.47 < 1 0.18 Table 3: Time t (in sec) used by EC tree to find optimal networks, with a 32G memory, a 2 hour time limit. < is less than 0.01 sec. n is the variable number, N is the dataset size, p is the percentage of the ancestor constraints, s is the percentage of test cases that finish, ∆is the edge difference of the learned and true networks. constraints. In Table 1, our approach is consistently orders-of-magnitude faster than GOBNILP, for almost all values of n, N and p that we varied. This difference increased with the number of variables n.9 When we compare Table 2 to Table 1, we see that for the EC tree, the projection of constraints has a significant impact on the efficiency of learning (often by several orders of magnitude). For ILP, there is some mild overhead with a smaller number of variables (n = 12), but with a larger number of variables (n = 14), there were consistent improvements when projected constraints are used. Next, we evaluate (1) how introducing ancestral constraints effects the efficiency of search, and (2) how scalable our approach is as we increase the number of variables in the learning problem. In Table 3, we report results where we varied the number of variables n ∈{16, 18, 20}, and asserted a 2 hour time limit and a 32GB memory limit. First, we observe an easy-hard-easy trend as we increase the proportion p of ancestral constraints. When p is small, the learning problem is close to the unconstrained problem, and our oracle serves as an accurate heuristic. When p is large, the problem is highly constrained, and the search space is significantly reduced. In contrast, the ILP approach more consistently became easier as more constraints were provided (from Table 1). As expected, the learning problem becomes more challenging when we increase the number of variables n, and when less training data is available. We note that our approach scales to n = 20 variables here, which is comparable to the scalability of modern score-based approaches reported in the literature (for BDeu scores); e.g., Yuan and Malone [2013] reported results up to 26 variables (for BDeu scores). Table 3 also reports the average structural Hamming distance ∆between the learned network and the ground-truth network used to generate the data. We see that as the dataset size N and the proportion p of constraints available increases, the more accurate the learned model becomes.10 We remark that a relatively small number of ancestral constraints (say 10%–25%) can have a similar impact on the quality of the observed network (relative to the ground-truth), as increasing the amount of data available from 512 to 2048, or from 2048 to 8192. This highlights the impact that background knowledge can have, in contrast to collecting more (potentially expensive) training data. 7 Conclusion We proposed an approach for learning the structure of Bayesian networks optimally, subject to ancestral constraints. These constraints are non-decomposable, posing a particular difficulty for learning approaches for decomposable scores. We utilized a search space for structure learning with non-decomposable scores, called the EC tree, and employ an oracle that optimizes decomposable scores. We proposed a sound and complete method for pruning the EC tree, based on ancestral constraints. We also showed how the employed oracle can be empowered by passing it decomposable constraints inferred from the non-decomposable ancestral constraints. Empirically, we showed that our approach is orders-of-magnitude more efficient compared to learning systems based on ILP. Acknowledgments This work was partially supported by NSF grant #IIS-1514253 and ONR grant #N00014-15-1-2339. 9When no limits are placed on the sizes of families (as was done here), heuristic-search approaches (like ours) have been observed to scale better than ILP approaches [Yuan and Malone, 2013, Malone et al., 2014]. 10∆can be greater than 0 when p = 1, as there may be many DAGs that respect a set of ancestral constraints. For example, DAG X →Y →Z expresses the same ancestral relations, after adding edge X →Z. 8 References M. Bartlett and J. Cussens. Integer linear programming for the Bayesian network structure learning problem. Artificial Intelligence, 2015. G. Borboudakis and I. Tsamardinos. Incorporating causal prior knowledge as path-constraints in Bayesian networks and maximal ancestral graphs. In Proceedings of the Twenty-Ninth International Conference on Machine Learning, 2012. G. Borboudakis and I. Tsamardinos. Scoring and searching over Bayesian networks with causal and associative priors. In Proceedings of the Twenty-Ninth Conference on Uncertainty in Artificial Intelligence, 2013. E. Y.-J. Chen, A. Choi, and A. Darwiche. Learning optimal Bayesian networks with DAG graphs. In Proceedings of the 4th IJCAI Workshop on Graph Structures for Knowledge Representation and Reasoning (GKR’15), 2015. E. Y.-J. Chen, A. Choi, and A. Darwiche. Enumerating equivalence classes of Bayesian networks using EC graphs. In Proceedings of the Nineteenth International Conference on Artificial Intelligence and Statistics, 2016. Y. Chen and J. Tian. Finding the k-best equivalence classes of Bayesian network structures for model averaging. In Proceedings of the Twenty-Eighth Conference on Artificial Intelligence, 2014. G. F. Cooper and E. Herskovits. A Bayesian method for the induction of probabilistic networks from data. Machine learning, 9(4):309–347, 1992. J. Cussens. Bayesian network learning by compiling to weighted MAX-SAT. In Proceedings of the 24th Conference in Uncertainty in Artificial Intelligence (UAI), pages 105–112, 2008. J. Cussens, M. Bartlett, E. M. Jones, and N. A. Sheehan. Maximum likelihood pedigree reconstruction using integer linear programming. Genetic epidemiology, 37(1):69–83, 2013. A. Darwiche. Modeling and reasoning with Bayesian networks. Cambridge University Press, 2009. T. Jaakkola, D. Sontag, A. Globerson, and M. Meila. Learning Bayesian network structure using LP relaxations. In Proceedings of the Thirteen International Conference on Artificial Intelligence and Statistics, pages 358–365, 2010. M. Koivisto and K. Sood. Exact Bayesian structure discovery in Bayesian networks. The Journal of Machine Learning Research, 5:549–573, 2004. D. Koller and N. Friedman. Probabilistic graphical models: principles and techniques. The MIT Press, 2009. C.-M. Li and F. Manyà. MaxSAT, hard and soft constraints. In Handbook of Satisfiability, pages 613–631. 2009. B. Malone, K. Kangas, M. Järvisalo, M. Koivisto, and P. Myllymäki. Predicting the hardness of learning Bayesian networks. In Proceedings of the Twenty-Eighth Conference on Artificial Intelligence, 2014. K. P. Murphy. Machine Learning: A Probabilistic Perspective. MIT Press, 2012. P. Parviainen and M. Koivisto. Finding optimal Bayesian networks using precedence constraints. Journal of Machine Learning Research, 14(1):1387–1415, 2013. T. Silander and P. Myllymäki. A simple approach for finding the globally optimal Bayesian network structure. In Proceedings of the Twenty-Second Conference on Uncertainty in Artificial Intelligence, pages 445–452, 2006. A. P. Singh and A. W. Moore. Finding optimal Bayesian networks by dynamic programming. Technical report, CMU-CALD-050106, 2005. J. Tian, R. He, and L. Ram. Bayesian model averaging using the k-best Bayesian network structures. In Proceedings of the Twenty-Six Conference on Uncertainty in Artificial Intelligence, pages 589–597, 2010. P. van Beek and H. Hoffmann. Machine learning of Bayesian networks using constraint programming. In Proceedings of the 21st International Conference on Principles and Practice of Constraint Programming (CP), pages 429–445, 2015. C. Yuan and B. Malone. Learning optimal Bayesian networks: A shortest path perspective. Journal of Artificial Intelligence Research, 48:23–65, 2013. C. Yuan, B. Malone, and X. Wu. Learning optimal Bayesian networks using A* search. In Proceedings of the Twenty-Second International Joint Conference on Artificial Intelligence, pages 2186–2191, 2011. 9 | 2016 | 50 |
6,439 | The Robustness of Estimator Composition Pingfan Tang School of Computing University of Utah Salt Lake City, UT 84112 tang1984@cs.utah.edu Jeff M. Phillips School of Computing University of Utah Salt Lake City, UT 84112 jeffp@cs.utah.edu Abstract We formalize notions of robustness for composite estimators via the notion of a breakdown point. A composite estimator successively applies two (or more) estimators: on data decomposed into disjoint parts, it applies the first estimator on each part, then the second estimator on the outputs of the first estimator. And so on, if the composition is of more than two estimators. Informally, the breakdown point is the minimum fraction of data points which if significantly modified will also significantly modify the output of the estimator, so it is typically desirable to have a large breakdown point. Our main result shows that, under mild conditions on the individual estimators, the breakdown point of the composite estimator is the product of the breakdown points of the individual estimators. We also demonstrate several scenarios, ranging from regression to statistical testing, where this analysis is easy to apply, useful in understanding worst case robustness, and sheds powerful insights onto the associated data analysis. 1 Introduction Robust statistical estimators [5, 7] (in particular, resistant estimators), such as the median, are an essential tool in data analysis since they are provably immune to outliers. Given data with a large fraction of extreme outliers, a robust estimator guarantees the returned value is still within the nonoutlier part of the data. In particular, the role of these estimators is quickly growing in importance as the scale and automation associated with data collection and data processing becomes more commonplace. Artisanal data (hand crafted and carefully curated), where potential outliers can be removed, is becoming proportionally less common. Instead, important decisions are being made blindly based on the output of analysis functions, often without looking at individual data points and their effect on the outcome. Thus using estimators as part of this pipeline that are not robust are susceptible to erroneous and dangerous decisions as the result of a few extreme and rogue data points. Although other approaches like regularization and pruning a constant number of obvious outliers are common as well, they do not come with the important guarantees that ensure these unwanted outcomes absolutely cannot occur. In this paper we initiate the formal study of the robustness of composition of estimators through the notion of breakdown points. These are especially important with the growth of data analysis pipelines where the final result or prediction is the result of several layers of data processing. When each layer in this pipeline is modeled as an estimator, then our analysis provides the first general robustness analysis of these processes. The breakdown point [4, 3] is a basic measure of robustness of an estimator. Intuitively, it describes how many outliers can be in the data without the estimator becoming unreliable. However, the literature is full of slightly inconsistent and informal definitions of this concept. For example: 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. • Aloupis [1] write “the breakdown point is the proportion of data which must be moved to infinity so that the estimator will do the same.” • Huber and Ronchetti [8] write “the breakdown point is the smallest fraction of bad observations that may cause an estimator to take on arbitrarily large aberrant values." • Dasgupta, Kumar, and Srikumar [14] write “the breakdown point of an estimator is the largest fraction of the data that can be moved arbitrarily without perturbing the estimator to the boundary of the parameter space.” All of these definitions have similar meanings, and they are typically sufficient for the purpose of understanding a single estimator. However, they are not mathematically rigorous, and it is difficult to use them to discuss the breakdown point of composite estimators. Composition of Estimators. In a bit more detail (we give formal definitions in Section 2.1), an estimator E maps a data set to single value in another space, sometimes the same as a single data point. For instance the mean or the median are simple estimators on one-dimensional data. A composite E1-E2 estimator applies two estimators E1 and E2 on data stored in a hierarchy. Let P = {P1, P2, . . . , Pn} be a set of subdata sets, where each subdata set Pi = {pi,1, pi,2, . . . , pi,k} has individual data readings. Then the E1-E2 estimator reports E2(E1(P1), E1(P2), . . . , E1(Pn)), that is the estimator E2 applied to the output of estimator E1 on each subdata set. 1.1 Examples of Estimator Composition Composite estimators arise in many scenarios in data analysis. Uncertain Data. For instance, in the last decade there has been increased focus on the study of uncertainty data [10, 9, 2] where instead of analyzing a data set, we are given a model of the uncertainty of each data point. Consider tracking the summarization of a group of n people based on noisy GPS measurements. For each person i we might get k readings of their location Pi, and use these k readings as a discrete probability distribution of where that person might be. Then in order to represent the center of this set of people a natural thing to do would be to estimate the location of each person as xi ←E1(Pi), and then use these estimates to summarize the entire group E2(x1, x2, . . . , xn). Using the mean as E1 and E2 would be easy, but would be susceptible to even a single outrageous outlier (all people are in Manhattan, but a spurious reading was at (0, 0) lat-long, off the coast of Africa). An alternative is to use the L1-median for E1 and E2, that is known to have an optimal breakdown point of 0.5. But what is the breakdown point of the E1-E2 estimator? Robust Analysis of Bursty Behavior. Understanding the robustness of estimators can also be critical towards how much one can “game” a system. For instance, consider a start-up media website that gets bursts of traffic from memes they curate. They publish a statistic showing the median of the top half of traffic days each month, and aggregate these by taking the median of such values over the top half of all months. This is a composite estimator, and they proudly claim, even through they have bursty traffic, it is robust (each estimator has a breakdown point of 0.25). If this composite estimator shows large traffic, should a potential buyer of this website by impressed? Is there a better, more robust estimator the potential buyer could request? If the media website can stagger the release of its content, how should they distribute it to maximize this composite estimator? Part of the Data Analysis Pipeline. This process of estimator composition is very common in broad data analysis literature. This arises from the idea of an “analysis pipeline” where at several stages estimators or analysis is performed on data, and then further estimators and analysis are performed downstream. In many cases a robust estimator like the median is used, specifically for its robustness properties, but there is no analysis of how robust the composition of these estimators is. 1.2 Main Results This paper initiates the formal and general study of the robustness of composite estimators. • In Subsection 2.1, we give two formal definitions of breakdown points which are both required to prove composition theorem. One variant of the definition closely aligns with other formalizations [4, 3], while another is fundamentally different. • The main result provides general conditions under which an E1-E2 estimator with breakdown points β1 and β2, has a breakdown point of β1β2 (Theorem 2 in Subsection 2.2). 2 • Moreover, by showing examples where our conditions do not strictly apply, we gain an understanding of how to circumvent the above result. An example is in composite percentile estimators (e.g., E1 returns the 25th percentile, and E2 the 75th percentile of a ranked set). These composite estimators have larger breakdown point than β1 · β2. • The main result can extended to multiple compositions, under suitable conditions, so for instance an E1-E2-E3 estimator has a breakdown point of β1β2β3 (Theorem 3 in Subsection 2.3). This implies that long analysis chains can be very suspect to a few carefully places outliers since the breakdown point decays exponentially in the length of the analysis chain. • In Section 3, we highlight several applications of this theory, including robust regression, robustness of p-values, a depth-3 composition, and how to advantageously manipulate the observation about percentile estimator composition. We demonstrate a few more applications with simulations in Section 4. 2 Robustness of Estimator Composition 2.1 Formal Definitions of Breakdown Points In this paper, we give two definitions for the breakdown point: Asymptotic Breakdown Point and Asymptotic Onto-Breakdown Point. The first definition, Asymptotic Breakdown Point, is similar to the classic formal definitions in [4] and [3] (including their highly technical nature), although their definitions of the estimator are slightly different leading to some minor differences in special cases. However our second definition, Asymptotic Onto-Breakdown Point, is a structurally new definition, and we illustrate how it can result in significantly different values on some common and useful estimators. Our main theorem will require both definitions, and the differences in performance will lead to several new applications and insights. We define an estimator E as a function from the collection of some finite subsets of a metric space (X , d) to another metric space (X ′, d′): E : A ⊂{X ⊂X | 0 < |X| < ∞} 7→X ′, (1) where X is a multiset. This means if x ∈X then x can appear more than once in X, and the multiplicity of elements will be considered when we compute |X|. Finite Sample Breakdown Point. For estimator E defined in (1) and positive integer n we define its finite sample breakdown point gE(n) over a set M as gE(n) = max(M) if M ̸= ∅ 0 if M = ∅ (2) where for ρ(x′, X) = maxx∈X d(x′, x) is the distance from x′ to the furthest point in X, M = {m ∈[0, n] | ∀X ∈A , |X| = n, ∀G1 > 0, ∃G2 = G2(X, G1) s.t. ∀X′ ∈A , if |X′| = n and |{x′ ∈X′ | ρ(x′, X) > G1}| ≤m then d′(E(X), E(X′)) ≤G2}. (3) For an estimator E in (1) and X ∈A , the finite sample breakdown point gE(n) means if the number of unbounded points in X′ is at most gE(n), then E(X′) will be bounded. Lets break this definition down a bit more. The definition holds over all data sets X ∈A of size n, and for all values G1 > 0 and some value G2 defined as a function G2(X, G1) of the data set X and value G1. Then gE(n) is the maximum value m (over all X, G1, and G2 above) such that for all X′ ∈A with |X′| = n then |{x′ ∈X′ | ρ(x′, X) > G1}| ≤m (that is at most m points are further than G1 from X) where the estimators are close, d′(E(X), E(X′)) ≤G2. For example, consider a point set X = {0, 0.15, 0.2, 0.25, 0.4, 0.55, 0.6, 0.65, 0.72, 0.8, 1.0} with n = 11 and median 0.55. If we set G1 = 3, then we can consider sets X′ of size 11 with fewer than m points that are either greater than 3 or less than −2. This means in X′ there are at most m points which are greater than 3 or less than −2, and all other n −m points are in [−2, 3]. Under these conditions, we can (conservatively) set G2 = 4, and know that for values of m as 1, 2, 3, 4, or 5, then the median of X′ must be between −3.45 and 4.55; and this holds no matter where we set those m points (e.g., at 20 or at 1000). This does not hold for m ≥6, so gE(11) = 5. 3 Asymptotic Breakdown Point. If the limit limn→∞ gE(n) n exists, then we define this limit β = lim n→∞ gE(n) n (4) as the asymptotic breakdown point, or breakdown point for short, of the estimator E. Remark 1. It is not hard to see that many common estimators satisfy the conditions. For example, the median, L1-median [1], and Siegel estimators [11] all have asymptotic breakdown points of 0.5. Asymptotic Onto-Breakdown Point. For an estimator E given in (1) and positive integer n, if f M = {0 ≤m ≤n | ∀X ∈A , |X| = n, ∀y ∈X ′, ∃X′ ∈A s.t. |X′| = n, |X ∩X′| = n −m, E(X′) = y} is not empty, we define fE(n) = min(f M). (5) The definition of fE(n) implies, if we change fE(n) elements in X, we can make E become any value in X ′: it is onto. In contrast gE(n) only requires E(X′) to become far from E(X), perhaps only in one direction. Then the asymptotic onto-breakdown point is defined as the following limit if it exists lim n→∞ fE(n) n . (6) Remark 2. For a quantile estimator E that returns a percentile other than the 50th, then limn→∞ gE(n) n ̸= limn→∞ fE(n) n . For instance, if E returns the 25th percentile of a ranked set, setting only 25% of the data points to −∞causes E to return −∞; hence limn→∞ gE(n) n = 0.25. And while any value less than the original 25th percentile can also be obtained; to return a value larger than the largest element in the original set, at least 75% of the data must be modified, thus limn→∞ fE(n) n = 0.75. As we will observe in Section 3, this nuance in definition regarding percentile estimators will allow for some interesting composite estimator design. 2.2 Definition of E1-E2 Estimators, and their Robustness We consider the following two estimators: E1 : A1 ⊂{X ⊂X1 | 0 < |X| < ∞} 7→X2, (7) E2 : A2 ⊂{X ⊂X2 | 0 < |X| < ∞} 7→X ′ 2, (8) where any finite subset of E1(A1), the range of E1, belongs to A2. Suppose Pi ∈A1, |Pi| = k for i = 1, 2, · · · , n and Pflat = ⊎n i=1Pi, where ⊎means if x appears n1 times in X1 and n2 times in X2 then x appears n1 + n2 times in X1 ⊎X2. We define E(Pflat) = E2 (E1(P1), E1(P2), · · · , E1(Pn)) . (9) Theorem 1. Suppose gE1(k) and gE2(n) are the finite sample breakdown points of estimators E1 and E2 which are given by (7) and (8) respectively. If gE(nk) is the finite sample breakdown point of E given by (9), then we have gE2(n)gE1(k) ≤gE(nk). If β1 = limk→∞ gE1(k) k , β2 = limn→∞ gE2(n) n and β = limn,k→∞ gE(nk) nk all exist, then we have β1β2 ≤β. The proof of Theorem 1 and other theorems can be found in the full version of this paper [12]. Remark 3. Under the condition of Theorem 1, we cannot guarantee β = β1β2. For example, suppose E1 and E2 take the 25th percentile and the 75th percentile of a ranked set of real numbers respectively. So, we have β1 = β2 = 1 4. However, β = 1 4 · 3 4 = 3 16. In fact, the limit of gE(nk) nk as n, k →∞may even not exist. For example, suppose E1 takes the 25th percentile of a ranked set of real numbers. When n is odd E2 takes the the 25th percentile of a ranked set of n real numbers, and when n is even E2 takes the the 75th percentile of a ranked set of n real numbers. Thus, β1 = β2 = 1 4, but gE(nk) ≈1 4nk if n is odd, and gE(nk) ≈1 4 · 3 4nk if n is even, which implies limn,k→∞ gE(nk) nk does not exist. Therefore, to guarantee β exist and β = β1β2, we introduce the definition of asymptotic ontobreakdown point in (6). As shown in Remark 2, the values of (4) and (6) may be not equal. However, with the condition of the asymptotic breakdown point and asymptotic onto-breakdown point of E1 being the same, we can finally state our desired clean result. 4 Theorem 2. For estimators E1, E2 and E given by (7), (8) and (9) respectively, suppose gE1(k), gE2(n) and gE(nk) are defined by (2), and fE1(k) is defined by (5). Moreover, E1 is an onto function and for any fixed positive integer n we have ∃X ∈A2, |X| = n, G1 > 0, s.t. ∀G2 > 0, ∃X′ ∈A2 satisfying |X′| = n, |X′ \ X| = gE2(n) + 1, and d′ 2(E2(X), E2(X′)) > G2, (10) where d′ 2 is the metric of space X ′ 2. If β1 = limk→∞ gE1(k) k = limk→∞ fE1(k) k , and β2 = limn→∞ gE2(n) n both exist, then β = limn,k→∞ gE(nk) nk exists, and β = β1β2. Remark 4. Without the introduction of fE(n), we cannot even guarantee β ≤β1 or β ≤β2 only under the condition of Theorem 1, even if E1 and E2 are both onto functions. For example, for any P = {p1, p2, · · · , pk} ⊂R and X = {x1, x2, · · · , xn} ⊂R, we define E1(P) = 1/median(P) (if median(P) ̸= 0, otherwise define E1(P) = 0) and E2(X) = median(y1, y2, · · · , yn), where yi (1 ≤y ≤n) is given by yi = 1/xi (if xi ̸= 0, otherwise define yi = 0). Since gE1(k) = gE2(n) = 0 for all n, k, we have β1 = β2 = 0. However, in order to make E2(E1(P1), E1(P2), · · · , E1(Pn)) → +∞, we need to make about n 2 elements in {E(P1), E(P2), · · · , E(Pn)} go to 0+. To make E1(Pi) →0+, we need to make about k 2 points in Pi go to +∞. Therefore, we have gE(nk) ≈n 2 · k 2 and β = 1 4. 2.3 Multi-level Composition of Estimators To study the breakdown point of composite estimators with more than two levels, we introduce the following estimator: E3 : A3 ⊂{X ⊂X ′ 2 | 0 < |X| < ∞} 7→X ′ 3, (11) where any finite subset of E2(A2), the range of E2, belongs to A3. Suppose Pi,j ∈A1, |Pi,j| = k for i = 1, 2, · · · , n, j = 1, 2, · · · , m and P j flat = ⊎n i=1Pi,j, Pflat = ⊎m j=1P j flat. We define E(Pflat) = E3 E2( eP 1 flat), E2( eP 2 flat), · · · , E2( eP m flat) , (12) where eP j flat = {E1(P1,j), E1(P2,j), · · · , E1(Pn,j)}, for j = 1, 2, · · · , m. From Theorem 2, we can obtain the following theorem about the breakdown point of E in (12). Theorem 3. For estimators E1, E2, E3 and E given by (7), (8), (11) and (12) respectively, suppose gE1(k), gE2(n), gE3(m) and gE(mnk) are defined by (2), and fE1(k), fE2(n) are defined by (5). Moreover, E1 and E2 are both onto functions, and for any fixed positive integer m we have ∃X ∈A3, |X| = m, G1 > 0, s.t. ∀G2 > 0, ∃X′ ∈A3 satisfying |X′| = m, |X′ \ X| = gE3(m) + 1, and d′ 3(E3(X), E3(X′)) > G2, where d′ 3 is the metric of space X ′ 3. If β1 = limk→∞ gE1(k) k = limk→∞ fE1(k) k , β2 = limn→∞ gE2(n) n = limn→∞ fE2(n) n and β3 = limm→∞ gE3(m) m all exist, then we have β = limm,n,k→∞ gE(mnk) mnk exists, and β = β1β2β3 . 3 Applications 3.1 Application 1 : Balancing Percentiles For n companies, for simplicity, assume each company has k employees. We are interested in the income of the regular employees of all companies, not the executives who may have much higher pay. Let pi,j represents the income of the jth employee in the ith company. Set Pflat = ⊎n i=1Pi where the ith company has a set Pi = {pi,1, pi,2, · · · , pi,k} ⊂R and for notational convenience pi,1 ≤pi,2 ≤ · · · ≤pi,k for i ∈{1, 2, · · · , n}. Suppose the income data Pi of each company is preprocessed by a 45-percentile estimator E1 (median of lowest 90% of incomes), with breakdown point β1 = 0.45. In theory E1(Pi) can better reflect the income of regular employees in a company, since there may be about 10% of employees in the management of a company and their incomes are usually much higher than that of common employees. So, the preprocessed data is X = {E1(P1), E1(P2), · · · , E1(Pn)}. 5 If we define E2(X) = median(X) and E(Pflat) = E2(X), then the breakdown point of E2 is β2 = 0.5, and the breakdown points of E is β = β1β2 = 0.225. However, if we use another E2, then E can be more robust. For example, for X = {x1, x2, · · · , xn} where x1 ≤x2 ≤· · · ≤xn, we can define E2 as the 55-percentile estimator (median of largest 90% of incomes). In order to make E(Pflat) = E2(X) = E2(E1(P1), E1(P2), · · · , E1(Pn)) go to infinity, we need to either move 55% points of X to −∞or move 45% points of X to +∞. In either case, we need to move about 0.45 · 0.55nk points of Pflat to infinity. This means the breakdown point of E is β = 0.45 · 0.55 = 0.2475 which is greater than 0.225. This example implies if we know how the raw data is preprocessed by estimator E1, we can choose a proper estimator E2 to make the E1-E2 estimator more robust. 3.2 Application 2 : Regression of L1 Medians Suppose we want to use linear regression to robustly predict the weight of a person from his or her height, and we have multiple readings of each person’s height and weight. The raw data is Pflat = ⊎n i=1Pi where for the ith person we have a set Pi = {pi,1, pi,2, · · · , pi,k} ⊂R2 and pi,j = (xi,j, yi,j) for i ∈{1, 2, · · · , n}, j ∈{1, 2, · · · , k}. Here, xi,j and yi,j are the height and weight respectively of the ith person in their jth measurement. One “robust” way to process this data, is to first pre-process each Pi with its L1-median [1]: (¯xi, ¯yi) ←E1(Pi), where E1(Pi) = L1-median(Pi) has breakdown point β1 = 0.5. Then we could generate a linear model to predict weight ˆyi = ax+b from the Siegel Estimator [11]: E2(Z) = (a, b), with breakdown point β2 = 0.5. From Theorem 2 we immediately know the breakdown point of E(Pflat) = E2(E1(P1), E1(P2), · · · , E1(Pn)) is β = β1β2 = 0.5 · 0.5 = 0.25. Alternatively, taking the Siegel estimator of Pflat (i.e., returning E2(Pflat)) would have a much larger breakdown point of 0.5. So a seemingly harmless operation of normalizing the data with a robust estimator (with optimal 0.5 breakdown point) drastically decreases the robustness of the process. 3.3 Application 3 : Significance Thresholds Suppose we are studying the distribution of the wingspread of fruit flies. There are n = 500 flies, and the variance of the true wingspread among these flies is on the order of 0.1 units. Our goal is to estimate the 0.05 significance level of this distribution of wingspread among normal flies. To obtain a measured value of the wingspread of the ith fly, denoted Fi, we measure the wingspread of ith fly k = 100 times independently, and obtain the measurement set Pi = {pi,1, pi,2, · · · , pi,k}. The measurement is carried out by a machine automatically and quickly, which implies the variance of each Pi is typically very small, perhaps only 0.0001 units, but there are outliers in Pi with small chance due to possible machine malfunction. This malfunction may be correlated to individual flies because of anatomical issues, or it may have autocorrelation (the machine jams for a series of consecutive measurements). To perform hypothesis testing we desire the 0.05 significance level, so we are interested in the 95th percentile of the set F = {F1, F2, · · · , Fn}. So a post processing estimator E2 returns the 95th percentile of F and has a breakdown point of β2 = 0.05 [6]. Now, we need to design an estimator E1 to process the raw data Pflat = ⊎n i=1Pi to obtain F = {F1, F2, · · · , Fn}. For example, we can define E1 as Fi = E1(Pi) = median(Pi) and estimator E as E(Pflat) = E2(E1(P1), E1(P2), · · · , E1(Pn)). Then, the breakdown point of E1 is 0.5. Since the breakdown point of E2 is 0.05, the breakdown point of the composite estimator E is β = β1β2 = 0.5 · 0.05 = 0.025. This means if the measurement machine malfunctioned only 2.5% of the time, we could have an anomalous significant level, leading to false discovery. Can we make this process more robust by adjusting E1? Actually, yes!, we can use another pre-processing estimator to get a more robust E. Since the variance of each Pi is only 0.0001, we can let E1 return the 5th percentile of a ranked set of real numbers, then there is not much difference between E1(Pi) and the median of Pi. (Note: this introduces a small amount of bias that can likely be accounted for in other ways.) In order to make E(Pflat) = E2(F) go to infinity we need to move 5% points of X to −∞(causing E2 to give an anomalous value) or 95% points of X to +∞(causing many, 95%, of the E1 values, to give anomalous values). In either case, we need to move about 5% · 95% points of Pflat to infinity. So, the breakdown points of E is 6 β = 0.05 · 0.95 = 0.0475 which is greater than 0.025. That is, we can now sustain up to 4.75% of the measurement machine’s reading to be anomalous, almost double than before, without leading to an anomalous significance threshold value. This example implies if we know the post-processing estimator E2, we can choose a proper method to preprocess the raw data to make the E1-E2 estimator more robust. 3.4 Application 4 : 3-Level Composition Suppose we want to use a single value to represent the temperature of the US in a certain day. There are m = 50 states in the country. Suppose each state has n = 100 meteorological stations, and the station i in state j measures the local temperature k = 24 times to get the data Pi,j = {ti,j,1, ti,j,2, · · · , ti,j,k}. We define P j flat = ⊎n i=1Pi,j, Pflat = ⊎m j=1P j flat and E1(Pi,j) = median(Pi,j), E2(P j flat) = median (E1(P1,j), E1(P1,j), · · · , E1(Pn,j)) E(Pflat) = E3(E2(P 1 flat), E2(P 2 flat), · · · , E2(P m flat)) = median(E2(P 1 flat), E2(P 2 flat), · · · , E2(P m flat)). So, the break down points of E1, E2 and E3 are β1 = β2 = β3 = 0.5. From Theorem 3, we know the break down point of E is β = β1β2β3 = 0.125. Therefore, we know the estimator E is not very robust, and it may be not a good choice to use E(Pflat) to represent the temperature of the US in a certain day. This example illustrates how the more times the raw data is aggregated, the more unreliable the final result can become. 4 Simulation: Estimator Manipulation In this simulation we actually construct a method to relocate an estimator by modifying the smallest number of points possible. We specifically target the L1-median of L1-medians since its somewhat non-trivial to solve for the new location of data points. In particular, given a target point p0 ∈ R2 and a set of nk points Pflat = ⊎n i=1Pi, where Pi = {pi,1, pi,2, · · · , pi,k} ⊂ R2, we use simulation to show that we only need to change ˜n˜k points of Pflat, then we can get a new set ePflat = ⊎n i=1 ePi such that median(median( eP1), median( eP2), · · · , median( ePn)) = p0. Here, the "median" means L1-median, and ˜n = 1 2n if n is even 1 2(n + 1) if n is odd , ˜k = 1 2k if k is even 1 2(k + 1) if k is odd . To do this, we first show that, given k points S = {(xi, yi) | 1 ≤i ≤k} in R2, and a target point (x0, y0), we can change ˜k points of S to make (x0, y0) as the L1-median of the new set. As n and k grow, then ˜n˜k/(nk) = 0.25 is the asymptotic breakdown point of this estimator, as a consequence of Theorem 2, and thus we may need to move this many points to get the result. If (x0, y0) is the L1-median of the set {(xi, yi) | 1 ≤i ≤k}, then we have [13]: k X i=1 xi −x0 p (xi −x0)2 + (yi −y0)2 = 0, k X i=1 yi −y0 p (xi −x0)2 + (yi −y0)2 = 0. (13) We define ⃗x = (x1, x2, · · · , x˜k), ⃗y = (y1, y2, · · · , y˜k) and h(⃗x, ⃗y) = k X i=1 xi −x0 p (xi −x0)2 + (yi −y0)2 !2 + k X i=1 yi −y0 p (xi −x0)2 + (yi −y0)2 !2 . Since (13) is the sufficient and necessary condition for L1-median, if we can find ⃗x and ⃗y such that h(⃗x, ⃗y) = 0, then (x0, y0) is the L1-median of the new set. Since ∂xih(⃗x, ⃗y) =2 k X j=1 xj −x0 p (xj −x0)2 + (yj −y0)2 (yi −y0)2 (xi −x0)2 + (yi −y0)2 3 2 −2 k X j=1 yj −y0 p (xj −x0)2 + (yj −y0)2 (xi −x0)(yi −y0) (xi −x0)2 + (yi −y0)2 3 2 , 7 ∂yih(⃗x, ⃗y) = −2 k X j=1 xj −x0 p (xj −x0)2 + (yj −y0)2 (xi −x0)(yi −y0) (xi −x0)2 + (yi −y0)2 3 2 + 2 k X j=1 yj −y0 p (xj −x0)2 + (yj −y0)2 (xi −x0)2 (xi −x0)2 + (yi −y0)2 3 2 , we can use gradient descent to compute ⃗x, ⃗y to minimize h. For the input S = {(xi, yi)|1 ≤i ≤k}, we choose the initial value ⃗x0 = {x1, x2, · · · , x˜k}, ⃗y0 = {y1, y2, · · · , y˜k}, and then update ⃗x and ⃗y along the negative gradient direction of h, until the Euclidean norm of gradient is less than 0.00001. The algorithm framework is then as follows, using the above gradient descent formulation at each step. We first compute the L1-median mi for each Pi, and then change ˜n points in {m1, m2, · · · , mn} to obtain {m′ 1, m′ 2, · · · , m′ ˜n, m˜n+1, · · · , mn} such that median(m′ 1, m′ 2, · · · , m′ ˜n, m˜n+1, · · · , mn) = p0. For each m′ i, we change ˜k points in Pi to obtain ePi = {p′ i,1, p′ i,2, · · · , p′ i,˜k, pi,˜k+1, · · · , pi,k} such that median( ePi) = m′ i. Thus, we have median median( eP1), · · · , median( eP˜n), median(P˜n+1), · · · , median(Pn) = p0. (14) To show a simulation of this process, we use a uniform distribution to randomly generate nk points in the region [−10, 10] × [−10, 10], and generate a target point p0 = (x0, y0) in the region [−20, 20] × [−20, 20], and then use our algorithm to change ˜n˜k points in the given set, to make the new set satisfy (14). Table 1 shows the result of running this experiment for different n and k, where (x′ 0, y′ 0) is the median of medians for the new set obtained by our algorithm. It lists the various values n and k, the corresponding values ˜n and ˜k of points modified, and the target point and result of our algorithm. If we reduce the terminating condition, which means increasing the number of iteration, we can obtain a more accurate result, but only requiring the Euclidean norm of gradient to be less than 0.00001, we get very accurate results, within about 0.01 in each coordinate. We illustrate the results of this process graphically for a example in Table 1: for the cases n = 5, −10 −5 0 5 10 15 −10 −5 0 5 10 15 20 25 The given points that are not changed The given points that are changed The new locations for those changed points The medians of old subsets The medians of new subsets The median of medians for the given points The target point Figure 1: The running result for the case n = 5, k = 8, (x0, y0) = (0.99, 1.01) in Table 1. n k ˜n ˜k (x0, y0) (x′ 0, y′ 0) 5 8 3 4 (0.99, 1.01) (0.99, 1.01) 5 8 3 4 (10.76, 11.06) (10.70 11.06) 10 5 5 3 (-13.82, -4.74) (-13.83, -4.74) 50 20 25 10 ( -14.71, -13.67) (-14.72, -13.67) 100 50 50 25 ( -14.07, 18.36) ( -14.07, 18.36) 500 100 250 50 (-15.84, -6.42) (-15.83, -6.42) 1000 200 500 100 (18.63, -12.10) (18.78, -12.20) Table 1: The running result of simulation. k = 8, (x0, y0) = (0.99, 1.01), wihch is shown in Figure 1. In this figure, the green star is the target point. Since n = 5, we use five different markers (circle, square, upward-pointing triangle, downward-pointing triangle, and diamond) to represent five kinds of points. The given data Pflat are shown by black points and unfilled points. Our algorithm changes those unfilled points to the blue ones, and the green points are the medians of the new subsets. The red star is the median of medians for Pflat, and other red points are the median of old subsets. So, we only changed 12 points out of 40, and the median of medians for the new data set is very close to the target point. 5 Conclusion We define the breakdown point of the composition of two or more estimators. These definitions are technical but necessary to understand the robustness of composite estimators. Generally, the composition of two of more estimators is less robust than each individual estimator. We highlight a few applications and believe many more exist. These results already provide important insights for complex data analysis pipelines common to large-scale automated data analysis. 8 References [1] G. Aloupis. Geometric measures of data depth. In Data Depth: Robust Multivariate Analysis, Computational Geometry and Applications. AMS, 2006. [2] G. Cormode and A. McGregor. Approximation algorithms for clustering uncertain data. In PODS, 2008. [3] P. Davies and U. Gather. The breakdown point: Examples and counterexamples. REVSTAT – Statitical Journal, 5:1–17, 2007. [4] F. R. Hampel. A general qualitative definition mof robustness. Annals of Mathematical Statistics, 42:1887– 1896, 1971. [5] F. R. Hampel, E. M. Ronchetti, P. J. Rousseeuw, and W. A. Stahel. Robust Statistics: The Approach Based on Influence Functions. Wiley, 1986. [6] X. He, D. G. Simplson, and S. L. Portnoy. Breakdown robustness of tests. Journal of the Maerican Statistical Association, 85:446–452, 1990. [7] P. J. Huber. Robust Statistics. Wiley, 1981. [8] P. J. Huber and E. M. Ronchetti. Breakdown point. In Robust Statistics, page 8. John Wiley & Sons, Inc., 2009. [9] A. G. Jørgensen, M. Löffler, and J. M. Phillips. Geometric computation on indecisive points. In WADS, 2011. [10] A. D. Sarma, O. Benjelloun, A. Halevy, S. Nabar, and J. Widom. Representing uncertain data: models, properties, and algorithms. VLDBJ, 18:989–1019, 2009. [11] A. F. Siegel. Robust regression using repeated medians. Biometrika, 82:242–244, 1982. [12] P. Tang and J. M. Phillips. The robustness of estimator composition. Technical report, arXiv:1609.01226, 2016. [13] E. Weiszfeld and F. Plastria. On the point for which the sum of the distances to n given points is minimum. Annals of Operations Research, 167:7–41, 2009. [14] A. H. Welsh. The standard deviation. In Aspects of Statistical Inference, page 245. Wiley-Interscience;, 1996. 9 | 2016 | 500 |
6,440 | Active Learning from Imperfect Labelers Songbai Yan University of California, San Diego yansongbai@eng.ucsd.edu Kamalika Chaudhuri University of California, San Diego kamalika@cs.ucsd.edu Tara Javidi University of California, San Diego tjavidi@eng.ucsd.edu Abstract We study active learning where the labeler can not only return incorrect labels but also abstain from labeling. We consider different noise and abstention conditions of the labeler. We propose an algorithm which utilizes abstention responses, and analyze its statistical consistency and query complexity under fairly natural assumptions on the noise and abstention rate of the labeler. This algorithm is adaptive in a sense that it can automatically request less queries with a more informed or less noisy labeler. We couple our algorithm with lower bounds to show that under some technical conditions, it achieves nearly optimal query complexity. 1 Introduction In active learning, the learner is given an input space X, a label space L, and a hypothesis class H such that one of the hypotheses in the class generates ground truth labels. Additionally, the learner has at its disposal a labeler to which it can pose interactive queries about the labels of examples in the input space. Note that the labeler may output a noisy version of the ground truth label (a flipped label). The goal of the learner is to learn a hypothesis in H which is close to the hypothesis that generates the ground truth labels. There has been a significant amount of literature on active learning, both theoretical and practical. Previous theoretical work on active learning has mostly focused on the above basic setting [2, 4, 7, 10, 25] and has developed algorithms under a number of different models of label noise. A handful of exceptions include [3] which allows class conditional queries, [5] which allows requesting counterexamples to current version spaces, and [23, 26] where the learner has access to a strong labeler and one or more weak labelers. In this paper, we consider a more general setting where, in addition to providing a possibly noisy label, the labeler can sometimes abstain from labeling. This scenario arises naturally in difficult labeling tasks and has been considered in computer vision by [11, 15]. Our goal in this paper is to investigate this problem from a foundational perspective, and explore what kind of conditions are needed, and how an abstaining labeler can affect properties such as consistency and query complexity of active learning algorithms. The setting of active learning with an abstaining noisy labeler was first considered by [24], who looked at learning binary threshold classifiers based on queries to an labeler whose abstention rate is higher closer to the decision boundary. They primarily looked at the case when the abstention rate at a distance ∆from the decision boundary is less than 1 −Θ(∆α), and the rate of label flips at the same distance is less than 1 2 −Θ(∆β); under these conditions, they provided an active learning algorithm that given parameters α and β, outputs a classifier with error ǫ using ˜O(ǫ−α−2β) queries to the labeler. 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. However, there are several limitations to this work. The primary limitation is that parameters α and β need to be known to the algorithm, which is not usually the case in practice. A second major limitation is that even if the labeler has nice properties, such as, the abstention rates increase sharply close to the boundary, their algorithm is unable to exploit these properties to reduce the number of queries. A third and final limitation is that their analysis only applies to one dimensional thresholds, and not to more general decision boundaries. In this work, we provide an algorithm which is able to exploit nice properties of the labeler. Our algorithm is statistically consistent under very mild conditions — when the abstention rate is nondecreasing as we get closer to the decision boundary. Under slightly stronger conditions as in [24], our algorithm has the same query complexity. However, if the abstention rate of the labeler increases strictly monotonically close to the decision boundary, then our algorithm adapts and does substantially better. It simply exploits the increasing abstention rate close to the decision boundary, and does not even have to rely on the noisy labels! Specifically, when applied to the case where the noise rate is at most 1 2 −Θ(∆β) and the abstention rate is 1 −Θ(∆α) at distance ∆from the decision boundary, our algorithm can output a classifier with error ǫ based on only ˜O(ǫ−α) queries. An important property of our algorithm is that the improvement of query complexity is achieved in a completely adaptive manner; unlike previous work [24], our algorithm needs no information whatsoever on the abstention rates or rates of label noise. Thus our result also strengthens existing results on active learning from (non-abstaining) noisy labelers by providing an adaptive algorithm that achieves that same performance as [6] without knowledge of noise parameters. We extend our algorithm so that it applies to any smooth d-dimensional decision boundary in a non-parametric setting, not just one-dimensional thresholds, and we complement it with lower bounds on the number of queries that need to be made to any labeler. Our lower bounds generalize the lower bounds in [24], and shows that our upper bounds are nearly optimal. We also present an example that shows that at least a relaxed version of the monotonicity property is necessary to achieve this performance gain; if the abstention rate plateaus around the decision boundary, then our algorithm needs to query and rely on the noisy labels (resulting in higher query complexity) in order to find a hypothesis close to the one generating the ground truth labels. 1.1 Related work There has been a considerable amount of work on active learning, most of which involves labelers that are not allowed to abstain. Theoretical work on this topic largely falls under two categories — the membership query model [6, 13, 18, 19], where the learner can request label of any example in the instance space, and the PAC model, where the learner is given a large set of unlabeled examples from an underlying unlabeled data distribution, and can request labels of a subset of these examples. Our work and also that of [24] builds on the membership query model. There has also been a lot of work on active learning under different noise models. The problem is relatively easy when the labeler always provides the ground truth labels – see [8, 9, 12] for work in this setting in the PAC model, and [13] for the membership query model. Perhaps the simplest setting of label noise is random classification noise, where each label is flipped with a probability that is independent of the unlabeled instance. [14] shows how to address this kind of noise in the PAC model by repeatedly querying an example until the learner is confident of its label; [18, 19] provide more sophisticated algorithms with better query complexities in the membership query model. A second setting is when the noise rate increases closer to the decision boundary; this setting has been studied under the membership query model by [6] and in the PAC model by [10, 4, 25]. A final setting is agnostic PAC learning — when a fixed but arbitrary fraction of labels may disagree with the label assigned by the optimal hypothesis in the hypothesis class. Active learning is known to be particularly difficult in this setting; however, algorithms and associated label complexity bounds have been provided by [1, 2, 4, 10, 12, 25] among others. Our work expands on the membership query model, and our abstention and noise models are related to a variant of the Tsybakov noise condition. A setting similar to ours was considered by [6, 24]. [6] considers a non-abstaining labeler, and provides a near-optimal binary search style active learning algorithm; however, their algorithm is non-adaptive. [24] gives a nearly matching lower and upper query complexity bounds for active learning with abstention feedback, but they only give a nonadaptive algorithm for learning one dimensional thresholds, and only study the situation where the 2 abstention rate is upper-bounded by a polynomial function. Besides [24] , [11, 15] study active learning with abstention feedback in computer vision applications. However, these works are based on heuristics and do not provide any theoretical guarantees. 2 Settings Notation. 1 [A] is the indicator function: 1 [A] = 1 if A is true, and 0 otherwise. For x = (x1, . . . , xd) ∈Rd (d > 1), denote (x1, . . . , xd−1) by ˜x. Define ln x = loge x, log x = log 4 3 x, [ln ln]+ (x) = ln ln max{x, ee}. We use ˜O and ˜Θ to hide logarithmic factors in 1 ǫ , 1 δ , and d. Definition. Suppose γ ≥ 1. A function g : [0, 1]d−1 → R is (K, γ)-Hölder smooth, if it is continuously differentiable up to ⌊γ⌋-th order, and for any x, y ∈ [0, 1]d−1, g(y) −P⌊γ⌋ m=0 ∂mg(x) m! (y −x)m ≤K ∥y −x∥γ. We denote this class of functions by Σ(K, γ). We consider active learning for binary classification. We are given an instance space X = [0, 1]d and a label space L = {0, 1}. Each instance x ∈X is assigned to a label l ∈{0, 1} by an underlying function h∗: X →{0, 1} unknown to the learning algorithm in a hypothesis space H of interest. The learning algorithm has access to any x ∈X, but no access to their labels. Instead, it can only obtain label information through interactions with a labeler, whose relation to h∗is to be specified later. The objective of the algorithm is to sequentially select the instances to query for label information and output a classifier ˆh that is close to h∗while making as few queries as possible. We consider a non-parametric setting as in [6, 17] where the hypothesis space is the smooth boundary fragment class H = {hg(x) = 1 [xd > g(˜x)] | g : [0, 1]d−1 →[0, 1] is (K, γ)-Hölder smooth}. In other words, the decision boundaries of classifiers in this class are epigraph of smooth functions (see Figure 1 for example). We assume h∗(x) = 1 [xd > g∗(˜x)] ∈H. When d = 1, H reduces to the space of threshold functions {hθ(x) = 1 [x > θ] : θ ∈[0, 1]}. The performance of a classifier h(x) = 1 [xd > g(˜x)] is evaluated by the L1 distance between the decision boundaries ∥g −g∗∥= ´ [0,1]d−1 |g(˜x) −g∗(˜x)| d˜x. The learning algorithm can only obtain label information by querying a labeler who is allowed to abstain from labeling or return an incorrect label (flipping between 0 and 1). For each query x ∈[0, 1]d, the labeler L will return y ∈Y = {0, 1, ⊥} (⊥means that the labeler abstains from providing a 0/1 label) according to some distribution PL(Y = y | X = x). When it is clear from the context, we will drop the subscript from PL(Y | X). Note that while the labeler can declare its indecision by outputting ⊥, we do not allow classifiers in our hypothesis space to output ⊥. In our active learning setting, our goal is to output a boundary g that is close to g∗while making as few interactive queries to the labeler as possible. In particular, we want to find an algorithm with low query complexity Λ(ǫ, δ, A, L, g∗), which is defined as the minimum number of queries that Algorithm A, acting on samples with ground truth g∗, should make to a labeler L to ensure that the output classifier hg(x) = 1 [xd > g(˜x)] has the property ∥g −g∗∥= ´ [0,1]d−1 |g(˜x) −g∗(˜x)| d˜x ≤ǫ with probability at least 1 −δ over the responses of L. 2.1 Conditions We now introduce three conditions on the response of the labeler with increasing strictness. Later we will provide an algorithm whose query complexity improves with increasing strictness of conditions. Condition 1. The response distribution of the labeler P(Y | X) satisfies: • (abstention) For any ˜x ∈[0, 1]d−1, xd, x′ d ∈[0, 1], if |xd −g∗(˜x)| ≥|x′ d −g∗(˜x)| then P(⊥| (˜x, xd)) ≤P(⊥| (˜x, x′ d)); • (noise) For any x ∈[0, 1]d, P(Y ̸= 1 [xd > g∗(˜x)] | x, Y ̸=⊥) ≤1 2. Condition 1 means that the closer x is to the decision boundary (˜x, g∗(˜x)), the more likely the labeler is to abstain from labeling. This complies with the intuition that instances closer to the decision boundary are harder to classify. We also assume the 0/1 labels can be flipped with probability as large as 1 2. In other words, we allow unbounded noise. 3 1 0 1 x2 x1 Figure 1: A classifier with boundary g(˜x) = (x1 −0.4)2 + 0.1 for d = 2. Label 1 is assigned to the region above, 0 to the below (red region) 0.5 1 0 0.5 1 P(Y | X) X P(Y =⊥| X = x) P(Y = 1 | X = x) P(Y = 0 | X = x) Figure 2: The distributions above satisfy Conditions 1 and 2, but the abstention feedback is useless since P(⊥| x) is flat between x = 0.2 and 0.4 0.5 1 0 0.5 1 P(Y | X) X P(Y =⊥| X = x) P(Y = 1 | X = x) P(Y = 0 | X = x) Figure 3: Distributions above satisfy Conditions 1, 2, and 3. Condition 2. Let C, β be non-negative constants, and f : [0, 1] →[0, 1] be a nondecreasing function. The response distribution P(Y | X) satisfies: • (abstention) P(⊥| x) ≤1 −f (|xd −g∗(˜x)|); • (noise) P(Y ̸= 1 [xd > g∗(˜x)] | x, Y ̸=⊥) ≤1 2 1 −C |xd −g∗(˜x)|β . Condition 2 requires the abstention and noise probabilities to be upper-bounded, and these upper bounds decrease as x moves further away from the decision boundary. The abstention rate can be 1 at the decision boundary, so the labeler may always abstain at the decision boundary. The condition on the noise satisfies the popular Tsybakov noise condition [22]. Condition 3. Let f : [0, 1] →[0, 1] be a nondecreasing function such that ∃0 < c < 1, ∀0 < a ≤1 ∀0 ≤b ≤2 3a, f(b) f(a) ≤1 −c. The response distribution satisfies: P(⊥| x) = 1 −f (|xd −g∗(˜x)|). An example where Condition 3 holds is P(⊥| x) = 1 −(x −0.3)α (α > 0). Condition 3 requires the abstention rate to increase monotonically close to the decision boundary as in Condition 1. In addition, it requires the abstention probability P(⊥|(˜x, xd)) not to be too flat with respect to xd. For example, when d = 1, P(⊥| x) = 0.68 for 0.2 ≤x ≤0.4 (shown as Figure 2) does not satisfy Condition 3, and abstention responses are not informative since this abstention rate alone yields no information on the location of the decision boundary. In contrast, P(⊥| x) = 1 − p |x −0.3| (shown as Figure 3) satisfies Condition 3, and the learner could infer it is getting close to the decision boundary when it starts receiving more abstention responses. Note that here c, f, C, β are unknown and arbitrary parameters that characterize the complexity of the learning task. We want to design an algorithm that does not require knowledge of these parameters but still achieves nearly optimal query complexity. 3 Learning one-dimensional thresholds In this section, we start with the one dimensional case (d = 1) to demonstrate the main idea. We will generalize these results to multidimensional instance space in the next section. When d = 1, the decision boundary g∗becomes a point in [0, 1], and the corresponding classifier is a threshold function over [0,1]. In other words the hypothesis space becomes H = {fθ(x) = 1 [x > θ] : θ ∈[0, 1]}). We denote the ground truth decision boundary by θ∗∈[0, 1]. We want to find a ˆθ ∈[0, 1] such that |ˆθ −θ∗| is small while making as few queries as possible. 3.1 Algorithm The proposed algorithm is a binary search style algorithm shown as Algorithm 1. (For the sake of simplicity, we assume log 1 2ǫ is an integer.) Algorithm 1 takes a desired precision ǫ and confidence 4 Algorithm 1 The active learning algorithm for learning thresholds 1: Input: δ, ǫ 2: [L0, R0] ←[0, 1] 3: for k = 0, 1, 2, . . . , log 1 2ǫ −1 do 4: Define three quartiles: Uk ←3Lk+Rk 4 , Mk ←Lk+Rk 2 , Vk ←Lk+3Rk 4 5: A(u), A(m), A(v), B(u), B(v) ←Empty Array 6: for n = 1, 2, . . . do 7: Query at Uk, Mk, Vk, and receive labels X(u) n , X(m) n , X(v) n 8: for w ∈{u, m, v} do 9: ⊲We record whether X(w) =⊥in A(w), and the 0/1 label (as -1/1) in B(w) if X(w) ̸=⊥ 10: if X(w) ̸=⊥then 11: A(w) ←A(w).append(1) , B(w) ←B(w).append(21 X(w) = 1 −1) 12: else 13: A(w) ←A(w).append(0) 14: end if 15: end for 16: ⊲Check if the differences of abstention responses are statistically significant 17: if CHECKSIGNIFICANT-VAR( n A(u) i −A(m) i on i=1, δ 4 log 1 2ǫ ) then 18: [Lk+1, Rk+1] ←[Uk, Rk]; break 19: else if CHECKSIGNIFICANT-VAR( n A(v) i −A(m) i on i=1, δ 4 log 1 2ǫ ) then 20: [Lk+1, Rk+1] ←[Lk, Vk]; break 21: end if 22: ⊲Check if the differences between 0 and 1 labels are statistically significant 23: if CHECKSIGNIFICANT( n −B(u) i oB(u).length i=1 , δ 4 log 1 2ǫ ) then 24: [Lk+1, Rk+1] ←[Uk, Rk]; break 25: else if CHECKSIGNIFICANT( n B(v) i oB(v).length i=1 , δ 4 log 1 2ǫ ) then 26: [Lk+1, Rk+1] ←[Lk, Vk]; break 27: end if 28: end for 29: end for 30: Output: ˆθ = Llog 1 2ǫ + Rlog 1 2ǫ /2 level δ as its input, and returns an estimation ˆθ of the decision boundary θ∗. The algorithm maintains an interval [Lk, Rk] in which θ∗is believed to lie, and shrinks this interval iteratively. To find the subinterval that contains θ∗, Algorithm 1 relies on two auxiliary functions (marked in Procedure 2) to conduct adaptive sequential hypothesis tests regarding subintervals of interval [Lk, Rk]. Suppose θ∗∈[Lk, Rk]. Algorithm 1 tries to shrink this interval to a 3 4 of its length in each iteration by repetitively querying on quartiles Uk = 3Lk+Rk 4 , Mk = Lk+Rk 2 , Vk = Lk+3Rk 4 . To determine which specific subinterval to choose, the algorithm uses 0/1 labels and abstention responses simultaneously. Since the ground truth labels are determined by 1 [x > θ∗], one can infer that if the number of queries that return label 0 at Uk (Vk) is statistically significantly more (less) than label 1, then θ∗should be on the right (left) side of Uk (Vk). Similarly, from Condition 1, if the number of non-abstention responses at Uk (Vk) is statistically significantly more than non-abstention responses at Mk, then θ∗ should be closer to Mk than Uk (Vk). Algorithm 1 relies on the ability to shrink the search interval via statistically comparing the numbers of obtained labels at locations Uk, Mk, Vk. As a result, a main building block of Algorithm 1 is to test whether i.i.d. bounded random variables Yi are greater in expectation than i.i.d. bounded random variables Zi with statistical significance. In Procedure 2, we have two test functions CheckSignificant and CheckSignificant-Var that take i.i.d. random variables {Xi = Yi −Zi} (|Xi| ≤1) and confidence level δ as their input, and output whether it is statistically significant to conclude EXi > 0. 5 Procedure 2 Adaptive sequential testing 1: ⊲D0, D1 are absolute constants defined in Proposition 1 and Proposition 2 2: ⊲{Xi} are i.i.d. random variables bounded by 1. δ is the confidence level. Detect if EX > 0 3: function CHECKSIGNIFICANT({Xi}n i=1 , δ) 4: p(n, δ) ←D0 1 + ln 1 δ + q 4n [ln ln]+ 4n + ln 1 δ 5: Return Pn i=1 Xi ≥p(n, δ) 6: end function 7: function CHECKSIGNIFICANT-VAR({Xi}n i=1 , δ) 8: Calculate the empirical variance Var = n n−1 Pn i=1 Xi 2 −1 n (Pn i=1 Xi)2 9: q(n, Var, δ) ←D1 1 + ln 1 δ + q Var + ln 1 δ + 1 [ln ln]+ Var + ln 1 δ + 1 + ln 1 δ 10: Return n ≥ln 1 δ AND Pn i=1 Xi ≥q(n, Var, δ) 11: end function CheckSignificant is based on the following uniform concentration result regarding the empirical mean: Proposition 1. Suppose X1, X2, . . . are a sequence of i.i.d. random variables with X1 ∈[−2, 2], EX1 = 0. Take any 0 < δ < 1. Then there is an absolute constant D0 such that with probability at least 1 −δ, for all n > 0 simultaneously, n X i=1 Xi ≤D0 1 + ln 1 δ + s 4n [ln ln]+ 4n + ln 1 δ ! In Algorithm 1, we use CheckSignificant to detect whether the expected number of queries that return label 0 at location Uk (Vk) is more/less than the expected number of label 1 with a statistical significance. CheckSignificant-Var is based on the following uniform concentration result which further utilizes the empirical variance Vn = n n−1 Pn i=1 X2 i −1 n (Pn i=1 Xi)2 : Proposition 2. There is an absolute constant D1 such that with probability at least 1 −δ, for all n ≥ln 1 δ simultaneously, n X i=1 Xi ≤D1 1 + ln 1 δ + s 1 + ln 1 δ + Vn [ln ln]+ (1 + ln 1 δ + Vn) + ln 1 δ ! The use of variance results in a tighter bound when Var(Xi) is small. In Algorithm 1, we use CheckSignificant-Var to detect the statistical significance of the relative order of the number of queries that return non-abstention responses at Uk (Vk) compared to the number of non-abstention responses at Mk. This results in a better query complexity than using CheckSignificant under Condition 3, since the variance of the number of abstention responses approaches 0 when the interval [Lk, Rk] zooms in on θ∗.1 3.2 Analysis For Algorithm 1 to be statistically consistent, we only need Condition 1. Theorem 1. Let θ∗be the ground truth. If the labeler L satisfies Condition 1 and Algorithm 1 stops to output ˆθ, then θ∗−ˆθ ≤ǫ with probability at least 1 −δ 2. 1We do not apply CheckSignificant-Var to 0/1 labels, because unlike the difference between the numbers of abstention responses at Uk (Vk) and Mk, the variance of the difference between the numbers of 0 and 1 labels stays above a positive constant. 6 Under additional Conditions 2 and 3, we can derive upper bounds of the query complexity for our algorithm. (Recall f and β are defined in Conditions 2 and 3.) Theorem 2. Let θ∗be the ground truth, and ˆθ be the output of Algorithm 1. Under Conditions 1 and 2, with probability at least 1 −δ, Algorithm 1 makes at most ˜O 1 f( ǫ 2 )ǫ−2β queries. Theorem 3. Let θ∗be the ground truth, and ˆθ be the output of Algorithm 1. Under Conditions 1 and 3, with probability at least 1 −δ, Algorithm 1 makes at most ˜O 1 f( ǫ 2 ) queries. The query complexity given by Theorem 3 is independent of β that decides the flipping rate, and consequently smaller than the bound in Theorem 2. This improvement is due to the use of abstention responses, which become much more informative under Condition 3. 3.3 Lower Bounds In this subsection, we give lower bounds of query complexity in the one-dimensional case and establish near optimality of Algorithm 1. We will give corresponding lower bounds for the highdimensional case in the next section. The lower bound in [24] can be easily generalized to Condition 2: Theorem 4. ([24]) There is a universal constant δ0 ∈(0, 1) and a labeler L satisfying Conditions 1 and 2, such that for any active learning algorithm A, there is a θ∗∈[0, 1], such that for small enough ǫ, Λ(ǫ, δ0, A, L, θ∗) ≥Ω 1 f(ǫ)ǫ−2β . Our query complexity (Theorem 3) for the algorithm is also almost tight under Conditions 1 and 3 with a polynomial abstention rate. Theorem 5. There is a universal constant δ0 ∈(0, 1) and a labeler L satisfying Conditions 1, 2, and 3 with f(x) = C′xα (C′ > 0 and 0 < α ≤2 are constants), such that for any active learning algorithm A, there is a θ∗∈[0, 1], such that for small enough ǫ, Λ(ǫ, δ0, A, L, θ∗) ≥Ω(ǫ−α). 3.4 Remarks Our results confirm the intuition that learning with abstention is easier than learning with noisy labels. This is true because a noisy label might mislead the learning algorithm, but an abstention response never does. Our analysis shows, in particular, that if the labeler never abstains, and outputs completely noisy labels with probability bounded by 1 −|x −θ∗|γ (i.e., P(Y ̸= I [x > θ∗] | x) ≤ 1 2 (1 −|x −θ∗|γ)), then the near optimal query complexity of ˜O ǫ−2γ is significantly larger than the near optimal ˜O (ǫ−γ) query complexity associated with a labeler who only abstains with probability P(Y =⊥| x) ≤1 −|x −θ∗|γ and never flips a label. More precisely, while in both cases the labeler outputs the same amount of corrupted labels, the query complexity of the abstention-only case is significantly smaller than the noise-only case. Note that the query complexity of Algorithm 1 consists of two kinds of queries: queries which return 0/1 labels and are used by function CheckSignificant, and queries which return abstention and are used by function CheckSignificant-Var. Algorithm 1 will stop querying when the responses of one of the two kinds of queries are statistically significant. Under Condition 2, our proof actually shows that the optimal number of queries is dominated by the number of queries used by CheckSignificant function. In other words, a simplified variant of Algorithm 1 which excludes use of abstention feedback is near optimal. Similarly, under Condition 3, the optimal query complexity is dominated by the number of queries used by CheckSignificant-Var function. Hence the variant of Algorithm 1 which disregards 0/1 labels would be near optimal. 4 The multidimensional case We follow [6] to generalize the results from one-dimensional thresholds to the d-dimensional (d > 1) smooth boundary fragment class Σ(K, γ). 7 Algorithm 3 The active learning algorithm for the smooth boundary fragment class 1: Input: δ, ǫ, γ 2: M ←Θ ǫ−1/γ . L ← 0 M , 1 M , . . . , M−1 M d−1 3: For each l ∈L, apply Algorithm 1 with parameter (ǫ, δ/M d−1) to learn a threshold gl that approximates g∗(l) 4: Partition the instance space into cells {Iq} indexed by q ∈ n 0, 1, . . . , M γ −1 od−1 , where Iq = q1γ M , (q1 + 1)γ M × · · · × qd−1γ M , (qd−1 + 1)γ M 5: For each cell Iq, perform a polynomial interpolation: gq(˜x) = P l∈Iq∩L glQq,l(˜x), where Qq,l(˜x) = d−1 Y i=1 γ Y j=0,j̸=Mli−γqi ˜xi −(γqi + j)/M li −(γqi + j)/M 6: Output: g(˜x) = P q∈{0,1,..., M γ −1} d−1 gq(˜x)1 [˜x ∈q] 4.1 Lower bounds Theorem 6. There are universal constants δ0 ∈(0, 1), c0 > 0, and a labeler L satisfying Conditions 1 and 2, such that for any active learning algorithm A, there is a g∗∈Σ(K, γ), such that for small enough ǫ, Λ(ǫ, δ0, A, L, g∗) ≥Ω 1 f(c0ǫ)ǫ−2β−d−1 γ . Theorem 7. There is a universal constant δ0 ∈(0, 1) and a labeler L satisfying Conditions 1, 2, and Condition 3 with f(x) = C′xα (C′ > 0 and 0 < α ≤2 are constants), such that for any active learning algorithm A, there is a g∗∈Σ(K, γ), such that for small enough ǫ, Λ(ǫ, δ0, A, L, g∗) ≥ Ω ǫ−α−d−1 γ . 4.2 Algorithm and Analysis Recall the decision boundary of the smooth boundary fragment class can be seen as the epigraph of a smooth function [0, 1]d−1 →[0, 1]. For d > 1, we can reduce the problem to the one-dimensional problem by discretizing the first d−1 dimensions of the instance space and then perform a polynomial interpolation. The algorithm is shown as Algorithm 3. For the sake of simplicity, we assume γ, M/γ in Algorithm 3 are integers. We have similar consistency guarantee and upper bounds as in the one-dimensional case. Theorem 8. Let g∗be the ground truth. If the labeler L satisfies Condition 1 and Algorithm 3 stops to output g, then ∥g∗−g∥≤ǫ with probability at least 1 −δ 2. Theorem 9. Let g∗be the ground truth, and g be the output of Algorithm 3. Under Conditions 1 and 2, with probability at least 1 −δ, Algorithm 3 makes at most ˜O d f(ǫ/2)ǫ−2β−d−1 γ queries. Theorem 10. Let g∗be the ground truth, and g be the output of Algorithm 3. Under Conditions 1 and 3, with probability at least 1 −δ, Algorithm 3 makes at most ˜O d f(ǫ/2)ǫ−d−1 γ queries. Acknowledgments. We thank NSF under IIS-1162581, CCF-1513883, and CNS-1329819 for research support. References [1] M.-F. Balcan and P. M. Long. Active and passive learning of linear separators under log-concave distributions. In COLT, 2013. [2] Maria-Florina Balcan, Alina Beygelzimer, and John Langford. Agnostic active learning. In Proceedings of the 23rd international conference on Machine learning, pages 65–72. ACM, 2006. 8 [3] Maria-Florina Balcan and Steve Hanneke. Robust interactive learning. In Proceedings of The 25th Conference on Learning Theory, 2012. [4] A. Beygelzimer, D. Hsu, J. Langford, and T. Zhang. Agnostic active learning without constraints. In NIPS, 2010. [5] Alina Beygelzimer, Daniel Hsu, John Langford, and Chicheng Zhang. Search improves label for active learning. arXiv preprint arXiv:1602.07265, 2016. [6] Rui M. Castro and Robert D. Nowak. Minimax bounds for active learning. IEEE Transactions on Information Theory, 54(5):2339–2353, 2008. [7] Yuxin Chen, S Hamed Hassani, Amin Karbasi, and Andreas Krause. Sequential information maximization: When is greedy near-optimal? In Proceedings of The 28th Conference on Learning Theory, pages 338–363, 2015. [8] D. A. Cohn, L. E. Atlas, and R. E. Ladner. Improving generalization with active learning. Machine Learning, 15(2), 1994. [9] S. Dasgupta. Coarse sample complexity bounds for active learning. In NIPS, 2005. [10] S. Dasgupta, D. Hsu, and C. Monteleoni. A general agnostic active learning algorithm. In NIPS, 2007. [11] Meng Fang and Xingquan Zhu. I don’t know the label: Active learning with blind knowledge. In Pattern Recognition (ICPR), 2012 21st International Conference on, pages 2238–2241. IEEE, 2012. [12] Steve Hanneke. Teaching dimension and the complexity of active learning. In Learning Theory, pages 66–81. Springer, 2007. [13] Tibor Heged˝us. Generalized teaching dimensions and the query complexity of learning. In Proceedings of the eighth annual conference on Computational learning theory, pages 108–117. ACM, 1995. [14] M. Kääriäinen. Active learning in the non-realizable case. In ALT, 2006. [15] Christoph Kading, Alexander Freytag, Erik Rodner, Paul Bodesheim, and Joachim Denzler. Active learning and discovery of object categories in the presence of unnameable instances. In Computer Vision and Pattern Recognition (CVPR), 2015 IEEE Conference on, pages 4343–4352. IEEE, 2015. [16] Yuan-Chuan Li and Cheh-Chih Yeh. Some equivalent forms of bernoulli’s inequality: A survey. Applied Mathematics, 4(07):1070, 2013. [17] Stanislav Minsker. Plug-in approach to active learning. Journal of Machine Learning Research, 13(Jan):67– 90, 2012. [18] Mohammad Naghshvar, Tara Javidi, and Kamalika Chaudhuri. Bayesian active learning with non-persistent noise. IEEE Transactions on Information Theory, 61(7):4080–4098, 2015. [19] R. D. Nowak. The geometry of generalized binary search. IEEE Transactions on Information Theory, 57(12):7893–7906, 2011. [20] Maxim Raginsky and Alexander Rakhlin. Lower bounds for passive and active learning. In Advances in Neural Information Processing Systems, pages 1026–1034, 2011. [21] Aaditya Ramdas and Akshay Balsubramani. Sequential nonparametric testing with the law of the iterated logarithm. In Proceedings of the Conference on Uncertainty in Artificial Intelligence, 2016. [22] A. B. Tsybakov. Optimal aggregation of classifiers in statistical learning. Annals of Statistics, 32:135–166, 2004. [23] Ruth Urner, Shai Ben-david, and Ohad Shamir. Learning from weak teachers. In International Conference on Artificial Intelligence and Statistics, pages 1252–1260, 2012. [24] Songbai Yan, Kamalika Chaudhuri, and Tara Javidi. Active learning from noisy and abstention feedback. In Communication, Control, and Computing (Allerton), 2015 53th Annual Allerton Conference on. IEEE, 2015. [25] Chicheng Zhang and Kamalika Chaudhuri. Beyond disagreement-based agnostic active learning. In Advances in Neural Information Processing Systems, pages 442–450, 2014. [26] Chicheng Zhang and Kamalika Chaudhuri. Active learning from weak and strong labelers. In Advances in Neural Information Processing Systems, pages 703–711, 2015. 9 | 2016 | 501 |
6,441 | Improved Variational Inference with Inverse Autoregressive Flow Diederik P. Kingma dpkingma@openai.com Tim Salimans tim@openai.com Rafal Jozefowicz rafal@openai.com Xi Chen peter@openai.com Ilya Sutskever ilya@openai.com Max Welling⇤ M.Welling@uva.nl Abstract The framework of normalizing flows provides a general strategy for flexible variational inference of posteriors over latent variables. We propose a new type of normalizing flow, inverse autoregressive flow (IAF), that, in contrast to earlier published flows, scales well to high-dimensional latent spaces. The proposed flow consists of a chain of invertible transformations, where each transformation is based on an autoregressive neural network. In experiments, we show that IAF significantly improves upon diagonal Gaussian approximate posteriors. In addition, we demonstrate that a novel type of variational autoencoder, coupled with IAF, is competitive with neural autoregressive models in terms of attained log-likelihood on natural images, while allowing significantly faster synthesis. 1 Introduction Stochastic variational inference (Blei et al., 2012; Hoffman et al., 2013) is a method for scalable posterior inference with large datasets using stochastic gradient ascent. It can be made especially efficient for continuous latent variables through latent-variable reparameterization and inference networks, amortizing the cost, resulting in a highly scalable learning procedure (Kingma and Welling, 2013; Rezende et al., 2014; Salimans et al., 2014). When using neural networks for both the inference network and generative model, this results in class of models called variational autoencoders (Kingma and Welling, 2013) (VAEs). A general strategy for building flexible inference networks, is the framework of normalizing flows (Rezende and Mohamed, 2015). In this paper we propose a new type of flow, inverse autoregressive flow (IAF), which scales well to high-dimensional latent space. At the core of our proposed method lie Gaussian autoregressive functions that are normally used for density estimation: functions that take as input a variable with some specified ordering such as multidimensional tensors, and output a mean and standard deviation for each element of the input variable conditioned on the previous elements. Examples of such functions are autoregressive neural density estimators such as RNNs, MADE (Germain et al., 2015), PixelCNN (van den Oord et al., 2016b) or WaveNet (van den Oord et al., 2016a) models. We show that such functions can often be turned into invertible nonlinear transformations of the input, with a simple Jacobian determinant. Since the transformation is flexible and the determinant known, it can be used as a normalizing flow, transforming a tensor with relatively simple known density, into a new tensor with more complicated density that is still cheaply computable. In contrast with most previous work on ⇤University of Amsterdam, University of California Irvine, and the Canadian Institute for Advanced Research (CIFAR). 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. (a) Prior distribution (b) Posteriors in standard VAE (c) Posteriors in VAE with IAF Figure 1: Best viewed in color. We fitted a variational auto-encoder (VAE) with a spherical Gaussian prior, and with factorized Gaussian posteriors (b) or inverse autoregressive flow (IAF) posteriors (c) to a toy dataset with four datapoints. Each colored cluster corresponds to the posterior distribution of one datapoint. IAF greatly improves the flexibility of the posterior distributions, and allows for a much better fit between the posteriors and the prior. improving inference models including previously used normalizing flows, this transformation is well suited to high-dimensional tensor variables, such as spatio-temporally organized variables. We demonstrate this method by improving inference networks of deep variational auto-encoders. In particular, we train deep variational auto-encoders with latent variables at multiple levels of the hierarchy, where each stochastic variable is a three-dimensional tensor (a stack of featuremaps), and demonstrate improved performance. 2 Variational Inference and Learning Let x be a (set of) observed variable(s), z a (set of) latent variable(s) and let p(x, z) be the parametric model of their joint distribution, called the generative model defined over the variables. Given a dataset X = {x1, ..., xN} we typically wish to perform maximum marginal likelihood learning of its parameters, i.e. to maximize log p(X) = N X i=1 log p(x(i)), (1) but in general this marginal likelihood is intractable to compute or differentiate directly for flexible generative models, e.g. when components of the generative model are parameterized by neural networks. A solution is to introduce q(z|x), a parametric inference model defined over the latent variables, and optimize the variational lower bound on the marginal log-likelihood of each observation x: log p(x) ≥Eq(z|x) [log p(x, z) −log q(z|x)] = L(x; ✓) (2) where ✓indicates the parameters of p and q models. Keeping in mind that Kullback-Leibler divergences DKL(.) are non-negative, it’s clear that L(x; ✓) is a lower bound on log p(x) since it can be written as follows ): L(x; ✓) = log p(x) −DKL(q(z|x)||p(z|x)) (3) There are various ways to optimize the lower bound L(x; ✓); for continuous z it can be done efficiently through a re-parameterization of q(z|x), see e.g. (Kingma and Welling, 2013; Rezende et al., 2014). As can be seen from equation (3), maximizing L(x; ✓) w.r.t. ✓will concurrently maximize log p(x) and minimize DKL(q(z|x)||p(z|x)). The closer DKL(q(z|x)||p(z|x)) is to 0, the closer L(x; ✓) will be to log p(x), and the better an approximation our optimization objective L(x; ✓) is to our true objective log p(x). Also, minimization of DKL(q(z|x)||p(z|x)) can be a goal in itself, if we’re interested in using q(z|x) for inference after optimization. In any case, the divergence DKL(q(z|x)||p(z|x)) is a function of our parameters through both the inference model and the generative model, and increasing the flexibility of either is generally helpful towards our objective. 2 Note that in models with multiple latent variables, the inference model is typically factorized into partial inference models with some ordering; e.g. q(za, zb|x) = q(za|x)q(zb|za, x). We’ll write q(z|x, c) to denote such partial inference models, conditioned on both the data x and a further context c which includes the previous latent variables according to the ordering. 2.1 Requirements for Computational Tractability Requirements for the inference model, in order to be able to efficiently optimize the bound, are that it is (1) computationally efficient to compute and differentiate its probability density q(z|x), and (2) computationally efficient to sample from, since both these operations need to be performed for each datapoint in a minibatch at every iteration of optimization. If z is high-dimensional and we want to make efficient use of parallel computational resources like GPUs, then parallelizability of these operations across dimensions of z is a large factor towards efficiency. This requirement restrict the class of approximate posteriors q(z|x) that are practical to use. In practice this often leads to the use of diagonal posteriors, e.g. q(z|x) ⇠N(µ(x), σ2(x)), where µ(x) and σ(x) are often nonlinear functions parameterized by neural networks. However, as explained above, we also need the density q(z|x) to be sufficiently flexible to match the true posterior p(z|x). 2.2 Normalizing Flow Normalizing Flow (NF), introduced by (Rezende and Mohamed, 2015) in the context of stochastic gradient variational inference, is a powerful framework for building flexible posterior distributions through an iterative procedure. The general idea is to start off with an initial random variable with a relatively simple distribution with known (and computationally cheap) probability density function, and then apply a chain of invertible parameterized transformations ft, such that the last iterate zT has a more flexible distribution2: z0 ⇠q(z0|x), zt = ft(zt−1, x) 8t = 1...T (4) As long as the Jacobian determinant of each of the transformations ft can be computed, we can still compute the probability density function of the last iterate: log q(zT |x) = log q(z0|x) − T X t=1 log det """" dzt dzt−1 """" (5) However, (Rezende and Mohamed, 2015) experiment with only a very limited family of such invertible transformation with known Jacobian determinant, namely: ft(zt−1) = zt−1 + uh(wT zt−1 + b) (6) where u and w are vectors, wT is w transposed, b is a scalar and h(.) is a nonlinearity, such that uh(wT zt−1 +b) can be interpreted as a MLP with a bottleneck hidden layer with a single unit. Since information goes through the single bottleneck, a long chain of transformations is required to capture high-dimensional dependencies. 3 Inverse Autoregressive Transformations In order to find a type of normalizing flow that scales well to high-dimensional space, we consider Gaussian versions of autoregressive autoencoders such as MADE (Germain et al., 2015) and the PixelCNN (van den Oord et al., 2016b). Let y be a variable modeled by such a model, with some chosen ordering on its elements y = {yi}D i=1. We will use [µ(y), σ(y)] to denote the function of the vector y, to the vectors µ and σ. Due to the autoregressive structure, the Jacobian is lower triangular with zeros on the diagonal: @[µi, σi]/@yj = [0, 0] for j ≥i. The elements [µi(y1:i−1), σi(y1:i−1)] are the predicted mean and standard deviation of the i-th element of y, which are functions of only the previous elements in y. Sampling from such a model is a sequential transformation from a noise vector ✏⇠N(0, I) to the corresponding vector y: y0 = µ0 + σ0 ⊙✏0, and for i > 0, yi = µi(y1:i−1) + σi(y1:i−1) · ✏i. The 2where x is the context, such as the value of the datapoint. In case of models with multiple levels of latent variables, the context also includes the value of the previously sampled latent variables. 3 Algorithm 1: Pseudo-code of an approximate posterior with Inverse Autoregressive Flow (IAF) Data: x: a datapoint, and optionally other conditioning information ✓: neural network parameters EncoderNN(x; ✓): encoder neural network, with additional output h AutoregressiveNN[⇤](z, h; ✓): autoregressive neural networks, with additional input h sum(.): sum over vector elements sigmoid(.): element-wise sigmoid function Result: z: a random sample from q(z|x), the approximate posterior distribution l: the scalar value of log q(z|x), evaluated at sample ’z’ [µ, σ, h] EncoderNN(x; ✓) ✏⇠N(0, I) z σ ⊙✏+ µ l −sum(log σ + 1 2✏2 + 1 2 log(2⇡)) for t 1 to T do [m, s] AutoregressiveNN[t](z, h; ✓) σ sigmoid(s) z σ ⊙z + (1 −σ) ⊙m l l −sum(log σ) end computation involved in this transformation is clearly proportional to the dimensionality D. Since variational inference requires sampling from the posterior, such models are not interesting for direct use in such applications. However, the inverse transformation is interesting for normalizing flows, as we will show. As long as we have σi > 0 for all i, the sampling transformation above is a one-to-one transformation, and can be inverted: ✏i = yi−µi(y1:i−1) σi(y1:i−1) . We make two key observations, important for normalizing flows. The first is that this inverse transformation can be parallelized, since (in case of autoregressive autoencoders) computations of the individual elements ✏i do not depend on eachother. The vectorized transformation is: ✏= (y −µ(y))/σ(y) (7) where the subtraction and division are elementwise. The second key observation, is that this inverse autoregressive operation has a simple Jacobian determinant. Note that due to the autoregressive structure, @[µi, σi]/@yj = [0, 0] for j ≥i. As a result, the transformation has a lower triangular Jacobian (@✏i/@yj = 0 for j > i), with a simple diagonal: @✏i/@yi = σi. The determinant of a lower triangular matrix equals the product of the diagonal terms. As a result, the log-determinant of the Jacobian of the transformation is remarkably simple and straightforward to compute: log det """" d✏ dy """" = D X i=1 −log σi(y) (8) The combination of model flexibility, parallelizability across dimensions, and simple log-determinant, make this transformation interesting for use as a normalizing flow over high-dimensional latent space. 4 Inverse Autoregressive Flow (IAF) We propose a new type normalizing flow (eq. (5)), based on transformations that are equivalent to the inverse autoregressive transformation of eq. (7) up to reparameterization. See algorithm 1 for pseudo-code of an appproximate posterior with the proposed flow. We let an initial encoder neural network output µ0 and σ0, in addition to an extra output h, which serves as an additional input to each subsequent step in the flow. We draw a random sample ✏⇠N(0, I), and initialize the chain with: z0 = µ0 + σ0 ⊙✏ (9) 4 × Autoregressive NN + IAF Step σ μ Approximate Posterior with Inverse Autoregressive Flow (IAF) z z Encoder NN ··· z Autoregressive NN z IAF Step σ μ IAF step Posterior with Inverse Autoregressive Flow (IAF) x zT z1 Encoder
NN z0 IAF step ··· zt Autoregres IAF Step Context (e.g. Encoder NN) μt IAF step x zT Inference model z0 Normalizing Flow x Generative model z μ σ h × + z h IAF step ε x Approximate Posterior with Inverse Autoregressive Flow (IAF) Encoder NN z μ σ × + ε x z IAF step h × Autoregressive NN + σ μ Initial Network ··· z ··· ··· × + Figure 2: Like other normalizing flows, drawing samples from an approximate posterior with Inverse Autoregressive Flow (IAF) consists of an initial sample z drawn from a simple distribution, such as a Gaussian with diagonal covariance, followed by a chain of nonlinear invertible transformations of z, each with a simple Jacobian determinants. The flow consists of a chain of T of the following transformations: zt = µt + σt ⊙zt−1 (10) where at the t-th step of the flow, we use a different autoregressive neural network with inputs zt−1 and h, and outputs µt and σt. The neural network is structured to be autoregressive w.r.t. zt−1, such that for any choice of its parameters, the Jacobians dµt dzt−1 and dσt dzt−1 are triangular with zeros on the diagonal. As a result, dzt dzt−1 is triangular with σt on the diagonal, with determinant QD i=1 σt,i. (Note that the Jacobian w.r.t. h does not have constraints.) Following eq. (5), the density under the final iterate is: log q(zT |x) = − D X i=1 1 2✏2 i + 1 2 log(2⇡) + T X t=0 log σt,i ! (11) The flexibility of the distribution of the final iterate zT , and its ability to closely fit to the true posterior, increases with the expressivity of the autoregressive models and the depth of the chain. See figure 2 for an illustration. A numerically stable version, inspired by the LSTM-type update, is where we let the autoregressive network output [mt, st], two unconstrained real-valued vectors: [mt, st] AutoregressiveNN[t](zt, h; ✓) (12) and compute zt as: σt = sigmoid(st) (13) zt = σt ⊙zt−1 + (1 −σt) ⊙mt (14) This version is shown in algorithm 1. Note that this is just a particular version of the update of eq. (10), so the simple computation of the final log-density of eq. (11) still applies. We found it beneficial for results to parameterize or initialize the parameters of each AutoregressiveNN[t] such that its outputs st are, before optimization, sufficiently positive, such as close to +1 or +2. This leads to an initial behaviour that updates z only slightly with each step of IAF. Such a parameterization is known as a ’forget gate bias’ in LSTMs, as investigated by Jozefowicz et al. (2015). Perhaps the simplest special version of IAF is one with a simple step, and a linear autoregressive model. This transforms a Gaussian variable with diagonal covariance, to one with linear dependencies, i.e. a Gaussian distribution with full covariance. See appendix A for an explanation. Autoregressive neural networks form a rich family of nonlinear transformations for IAF. For nonconvolutional models, we use the family of masked autoregressive networks introduced in (Germain et al., 2015) for the autoregressive neural networks. For CIFAR-10 experiments, which benefits more from scaling to high dimensional latent space, we use the family of convolutional autoregressive autoencoders introduced by (van den Oord et al., 2016b,c). We found that results improved when reversing the ordering of the variables after each step in the IAF chain. This is a volume-preserving transformation, so the simple form of eq. (11) remains unchanged. 5 5 Related work Inverse autoregressive flow (IAF) is a member of the family of normalizing flows, first discussed in (Rezende and Mohamed, 2015) in the context of stochastic variational inference. In (Rezende and Mohamed, 2015) two specific types of flows are introduced: planar flows and radial flows. These flows are shown to be effective to problems relatively low-dimensional latent space (at most a few hundred dimensions). It is not clear, however, how to scale such flows to much higher-dimensional latent spaces, such as latent spaces of generative models of /larger images, and how planar and radial flows can leverage the topology of latent space, as is possible with IAF. Volume-conserving neural architectures were first presented in in (Deco and Brauer, 1995), as a form of nonlinear independent component analysis. Another type of normalizing flow, introduced by (Dinh et al., 2014) (NICE), uses similar transformations as IAF. In contrast with IAF, this type of transformations updates only half of the latent variables z1:D/2 per step, adding a vector f(zD/2+1:D) which is a neural network based function of the remaining latent variables zD/2+1:D. Such large blocks have the advantage of computationally cheap inverse transformation, and the disadvantage of typically requiring longer chains. In experiments, (Rezende and Mohamed, 2015) found that this type of transformation is generally less powerful than other types of normalizing flow, in experiments with a low-dimensional latent space. Concurrently to our work, NICE was extended to high-dimensional spaces in (Dinh et al., 2016) (Real NVP). An empirical comparison would be an interesting subject of future research. A potentially powerful transformation is the Hamiltonian flow used in Hamiltonian Variational Inference (Salimans et al., 2014). Here, a transformation is generated by simulating the flow of a Hamiltonian system consisting of the latent variables z, and a set of auxiliary momentum variables. This type of transformation has the additional benefit that it is guided by the exact posterior distribution, and that it leaves this distribution invariant for small step sizes. Such as transformation could thus take us arbitrarily close to the exact posterior distribution if we can apply it for a sufficient number of times. In practice, however, Hamiltonian Variational Inference is very demanding computationally. Also, it requires an auxiliary variational bound to account for the auxiliary variables, which can impede progress if the bound is not sufficiently tight. An alternative method for increasing the flexiblity of the variational inference, is the introduction of auxiliary latent variables (Salimans et al., 2014; Ranganath et al., 2015; Tran et al., 2015) and corresponding auxiliary inference models. Latent variable models with multiple layers of stochastic variables, such as the one used in our experiments, are often equivalent to such auxiliary-variable methods. We combine deep latent variable models with IAF in our experiments, benefiting from both techniques. 6 Experiments We empirically evaluate IAF by applying the idea to improve variational autoencoders. Please see appendix C for details on the architectures of the generative model and inference models. Code for reproducing key empirical results is available online3. 6.1 MNIST In this expermiment we follow a similar implementation of the convolutional VAE as in (Salimans et al., 2014) with ResNet (He et al., 2015) blocks. A single layer of Gaussian stochastic units of dimension 32 is used. To investigate how the expressiveness of approximate posterior affects performance, we report results of different IAF posteriors with varying degrees of expressiveness. We use a 2-layer MADE (Germain et al., 2015) to implement one IAF transformation, and we stack multiple IAF transformations with ordering reversed between every other transformation. Results: Table 1 shows results on MNIST for these types of posteriors. Results indicate that as approximate posterior becomes more expressive, generative modeling performance becomes better. Also worth noting is that an expressive approximate posterior also tightens variational lower bounds as expected, making the gap between variational lower bounds and marginal likelihoods smaller. By making IAF deep and wide enough, we can achieve best published log-likelihood on dynamically 3https://github.com/openai/iaf 6 Table 1: Generative modeling results on the dynamically sampled binarized MNIST version used in previous publications (Burda et al., 2015). Shown are averages; the number between brackets are standard deviations across 5 optimization runs. The right column shows an importance sampled estimate of the marginal likelihood for each model with 128 samples. Best previous results are reproduced in the first segment: [1]: (Salimans et al., 2014) [2]: (Burda et al., 2015) [3]: (Kaae Sønderby et al., 2016) [4]: (Tran et al., 2015) Model VLB log p(x) ⇡ Convolutional VAE + HVI [1] -83.49 -81.94 DLGM 2hl + IWAE [2] -82.90 LVAE [3] -81.74 DRAW + VGP [4] -79.88 Diagonal covariance -84.08 (± 0.10) -81.08 (± 0.08) IAF (Depth = 2, Width = 320) -82.02 (± 0.08) -79.77 (± 0.06) IAF (Depth = 2, Width = 1920) -81.17 (± 0.08) -79.30 (± 0.08) IAF (Depth = 4, Width = 1920) -80.93 (± 0.09) -79.17 (± 0.08) IAF (Depth = 8, Width = 1920) -80.80 (± 0.07) -79.10 (± 0.07) Deep generative model x z3 z2 z1 Bidirectional
inference model VAE with bidirectional inference + = z3 z2 z1 x … … z3 z2 z1 x … … x … ELU ELU + ELU ELU + Bottom-Up ResNet Block Top-Down ResNet Block Layer Prior:
z ~ p(zi|z>i) + Identity Layer Posterior:
z ~ q(zi|z>i,x) = Convolution ELU = Nonlinearity = Identity Figure 3: Overview of our ResNet VAE with bidirectional inference. The posterior of each layer is parameterized by its own IAF. binarized MNIST: -79.10. On Hugo Larochelle’s statically binarized MNIST, our VAE with deep IAF achieves a log-likelihood of -79.88, which is slightly worse than the best reported result, -79.2, using the PixelCNN (van den Oord et al., 2016b). 6.2 CIFAR-10 We also evaluated IAF on the CIFAR-10 dataset of natural images. Natural images contain a much greater variety of patterns and structure than MNIST images; in order to capture this structure well, we experiment with a novel architecture, ResNet VAE, with many layers of stochastic variables, and based on residual convolutional networks (ResNets) (He et al., 2015, 2016). Please see our appendix for details. Log-likelihood. See table 2 for a comparison to previously reported results. Our architecture with IAF achieves 3.11 bits per dimension, which is better than other published latent-variable models, and almost on par with the best reported result using the PixelCNN. See the appendix for more experimental results. We suspect that the results can be further improved with more steps of flow, which we leave to future work. Synthesis speed. Sampling took about 0.05 seconds/image with the ResNet VAE model, versus 52.0 seconds/image with the PixelCNN model, on a NVIDIA Titan X GPU. We sampled from the PixelCNN naïvely by sequentially generating a pixel at a time, using the full generative model at each iteration. With custom code that only evaluates the relevant part of the network, PixelCNN sampling could be sped up significantly; however the speedup will be limited on parallel hardware due to the 7 Table 2: Our results with ResNet VAEs on CIFAR-10 images, compared to earlier results, in average number of bits per data dimension on the test set. The number for convolutional DRAW is an upper bound, while the ResNet VAE log-likelihood was estimated using importance sampling. Method bits/dim Results with tractable likelihood models: Uniform distribution (van den Oord et al., 2016b) 8.00 Multivariate Gaussian (van den Oord et al., 2016b) 4.70 NICE (Dinh et al., 2014) 4.48 Deep GMMs (van den Oord and Schrauwen, 2014) 4.00 Real NVP (Dinh et al., 2016) 3.49 PixelRNN (van den Oord et al., 2016b) 3.00 Gated PixelCNN (van den Oord et al., 2016c) 3.03 Results with variationally trained latent-variable models: Deep Diffusion (Sohl-Dickstein et al., 2015) 5.40 Convolutional DRAW (Gregor et al., 2016) 3.58 ResNet VAE with IAF (Ours) 3.11 sequential nature of the sampling operation. Efficient sampling from the ResNet VAE is a parallel computation that does not require custom code. 7 Conclusion We presented inverse autoregressive flow (IAF), a new type of normalizing flow that scales well to high-dimensional latent space. In experiments we demonstrated that autoregressive flow leads to significant performance gains compared to similar models with factorized Gaussian approximate posteriors, and we report close to state-of-the-art log-likelihood results on CIFAR-10, for a model that allows much faster sampling. Acknowledgements We thank Jascha Sohl-Dickstein, Karol Gregor, and many others at Google Deepmind for interesting discussions. We thank Harri Valpola for referring us to Gustavo Deco’s relevant pioneering work on a form of inverse autoregressive flow applied to nonlinear independent component analysis. References Blei, D. M., Jordan, M. I., and Paisley, J. W. (2012). Variational Bayesian inference with Stochastic Search. In Proceedings of the 29th International Conference on Machine Learning (ICML-12), pages 1367–1374. Bowman, S. R., Vilnis, L., Vinyals, O., Dai, A. M., Jozefowicz, R., and Bengio, S. (2015). Generating sentences from a continuous space. arXiv preprint arXiv:1511.06349. Burda, Y., Grosse, R., and Salakhutdinov, R. (2015). Importance weighted autoencoders. arXiv preprint arXiv:1509.00519. Clevert, D.-A., Unterthiner, T., and Hochreiter, S. (2015). Fast and accurate deep network learning by Exponential Linear Units (ELUs). arXiv preprint arXiv:1511.07289. Deco, G. and Brauer, W. (1995). Higher order statistical decorrelation without information loss. Advances in Neural Information Processing Systems, pages 247–254. Dinh, L., Krueger, D., and Bengio, Y. (2014). Nice: non-linear independent components estimation. arXiv preprint arXiv:1410.8516. Dinh, L., Sohl-Dickstein, J., and Bengio, S. (2016). Density estimation using Real NVP. arXiv preprint arXiv:1605.08803. 8 Germain, M., Gregor, K., Murray, I., and Larochelle, H. (2015). Made: Masked autoencoder for distribution estimation. arXiv preprint arXiv:1502.03509. Gregor, K., Besse, F., Rezende, D. J., Danihelka, I., and Wierstra, D. (2016). Towards conceptual compression. arXiv preprint arXiv:1604.08772. Gregor, K., Mnih, A., and Wierstra, D. (2013). Deep AutoRegressive Networks. arXiv preprint arXiv:1310.8499. He, K., Zhang, X., Ren, S., and Sun, J. (2015). Deep residual learning for image recognition. arXiv preprint arXiv:1512.03385. He, K., Zhang, X., Ren, S., and Sun, J. (2016). Identity mappings in deep residual networks. arXiv preprint arXiv:1603.05027. Hoffman, M. D., Blei, D. M., Wang, C., and Paisley, J. (2013). Stochastic variational inference. The Journal of Machine Learning Research, 14(1):1303–1347. Jozefowicz, R., Zaremba, W., and Sutskever, I. (2015). An empirical exploration of recurrent network architectures. In Proceedings of the 32nd International Conference on Machine Learning (ICML-15), pages 2342–2350. Kaae Sønderby, C., Raiko, T., Maaløe, L., Kaae Sønderby, S., and Winther, O. (2016). How to train deep variational autoencoders and probabilistic ladder networks. arXiv preprint arXiv:1602.02282. Kingma, D. P. and Welling, M. (2013). Auto-encoding variational Bayes. Proceedings of the 2nd International Conference on Learning Representations. Ranganath, R., Tran, D., and Blei, D. M. (2015). Hierarchical variational models. arXiv preprint arXiv:1511.02386. Rezende, D. and Mohamed, S. (2015). Variational inference with normalizing flows. In Proceedings of The 32nd International Conference on Machine Learning, pages 1530–1538. Rezende, D. J., Mohamed, S., and Wierstra, D. (2014). Stochastic backpropagation and approximate inference in deep generative models. In Proceedings of the 31st International Conference on Machine Learning (ICML-14), pages 1278–1286. Salimans, T. (2016). A structured variational auto-encoder for learning deep hierarchies of sparse features. arXiv preprint arXiv:1602.08734. Salimans, T. and Kingma, D. P. (2016). Weight normalization: A simple reparameterization to accelerate training of deep neural networks. arXiv preprint arXiv:1602.07868. Salimans, T., Kingma, D. P., and Welling, M. (2014). Markov chain Monte Carlo and variational inference: Bridging the gap. arXiv preprint arXiv:1410.6460. Sohl-Dickstein, J., Weiss, E. A., Maheswaranathan, N., and Ganguli, S. (2015). Deep unsupervised learning using nonequilibrium thermodynamics. arXiv preprint arXiv:1503.03585. Tran, D., Ranganath, R., and Blei, D. M. (2015). Variational gaussian process. arXiv preprint arXiv:1511.06499. van den Oord, A., Dieleman, S., Zen, H., Simonyan, K., Vinyals, O., Graves, A., Kalchbrenner, N., Senior, A., and Kavukcuoglu, K. (2016a). Wavenet: A generative model for raw audio. arXiv preprint arXiv:1609.03499. van den Oord, A., Kalchbrenner, N., and Kavukcuoglu, K. (2016b). Pixel recurrent neural networks. arXiv preprint arXiv:1601.06759. van den Oord, A., Kalchbrenner, N., Vinyals, O., Espeholt, L., Graves, A., and Kavukcuoglu, K. (2016c). Conditional image generation with pixelcnn decoders. arXiv preprint arXiv:1606.05328. van den Oord, A. and Schrauwen, B. (2014). Factoring variations in natural images with deep gaussian mixture models. In Advances in Neural Information Processing Systems, pages 3518–3526. Zagoruyko, S. and Komodakis, N. (2016). Wide residual networks. arXiv preprint arXiv:1605.07146. Zeiler, M. D., Krishnan, D., Taylor, G. W., and Fergus, R. (2010). Deconvolutional networks. In Computer Vision and Pattern Recognition (CVPR), 2010 IEEE Conference on, pages 2528–2535. IEEE. 9 | 2016 | 502 |
6,442 | Select-and-Sample for Spike-and-Slab Sparse Coding Abdul-Saboor Sheikh Technical University of Berlin, Germany, and Cluster of Excellence Hearing4all University of Oldenburg, Germany, and SAP Innovation Center Network, Berlin sheikh.abdulsaboor@gmail.com Jörg Lücke Research Center Neurosensory Science and Cluster of Excellence Hearing4all and Dept. of Medical Physics and Acoustics University of Oldenburg, Germany joerg.luecke@uol.de Abstract Probabilistic inference serves as a popular model for neural processing. It is still unclear, however, how approximate probabilistic inference can be accurate and scalable to very high-dimensional continuous latent spaces. Especially as typical posteriors for sensory data can be expected to exhibit complex latent dependencies including multiple modes. Here, we study an approach that can efficiently be scaled while maintaining a richly structured posterior approximation under these conditions. As example model we use spike-and-slab sparse coding for V1 processing, and combine latent subspace selection with Gibbs sampling (selectand-sample). Unlike factored variational approaches, the method can maintain large numbers of posterior modes and complex latent dependencies. Unlike pure sampling, the method is scalable to very high-dimensional latent spaces. Among all sparse coding approaches with non-trivial posterior approximations (MAP or ICAlike models), we report the largest-scale results. In applications we firstly verify the approach by showing competitiveness in standard denoising benchmarks. Secondly, we use its scalability to, for the first time, study highly-overcomplete settings for V1 encoding using sophisticated posterior representations. More generally, our study shows that very accurate probabilistic inference for multi-modal posteriors with complex dependencies is tractable, functionally desirable and consistent with models for neural inference. 1 Introduction The sensory data that enters our brain through our sensors has a high intrinsic dimensionality and it is complex and ambiguous. Image patches or small snippets of sound, for instance, often do not contain sufficient information to identify edges or phonemes with high degrees of certainty. Probabilistic models are therefore very well suited to maintain uncertainty encodings. Given an image patch, for instance, high probabilities for an edge in one location impacts the probabilities for other components resulting in complex dependencies commonly known as "explaining-away" effects. Such dependencies in general include (anti-)correlations, higher-order dependencies and multiple posterior modes (i.e., alternative interpretations of a patch). Furthermore, sensory data is typically composed of many different elementary constituents (e.g., an image patch contains some of a potentially very large number of components) resulting in sparse coding models aiming at increasing overcompleteness [1]. If sensory data gives rise to complex posterior dependencies and has high intrinsic dimensionality, how can we study inference and learning in such settings? To date most studies, e.g. of V1 encoding models, have avoided the treatment of complex latent dependencies by assuming standard sparse models with Laplace priors [2, 3, 1]; high-dimensional problems can then be addressed by applying maximum a-posteriori (MAP) approximations for the resulting mono-modal posteriors. Other scalable approaches such as independent component analysis (ICA) or singular value decomposition (K-SVD) [4, 5] do not encode for data uncertainty, which 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. avoids posterior estimations altogether. For advanced data models, which we expect to be required, e.g., for visual data, neither MAP nor a non-probabilistic treatment can be expected to be sufficient. It was, for example, in a number of studies shown that sparse coding models with more flexible spike-and-slab priors are (A) more closely aligned with the true generative process e.g. for images, and are (B) resulting in improved functional performance [6, 7]. Spike-and-slab priors do, however, result in posteriors with complex dependencies including many modes [8, 7]. Inference w.r.t. to spike-and-slab sparse coding is therefore well suited to, in general, study efficient inference and learning with complex posteriors in high-dimensions. Results for spike-and-slab sparse coding are, furthermore, of direct interest for other important models such as hierarchical communities of experts [9], deep Boltzmann Machines (see [6]), or convolutional neural networks [10]. Also for these typically deep systems very high-dimensional inference and learning is of crucial importance. So far, intractable inference for spike-and-slab sparse coding was approximated using sampling or factored variational approaches. While sampling approaches can in principle model any dependencies including multiple modes, they have been found challenging to train at scale, with the largest scale applications going to few hundred of latents [11, 12]. Compared to sampling, approaches using factored variational approximations can not model as complex posterior dependencies because they assume posterior independence (no correlations etc), however, they can capture multiple modes and are scalable to several hundreds up to thousands of latents [8, 6]. In this work we combine the accuracy of sampling approaches and the scalability of variational approaches by applying select-andsample [13] to scale spike-and-slab sparse coding to very high latent dimensions. In contrast to using a factored approximation, we here select low dimensional subspaces of the continuous hidden space, and then apply sampling to approximate posteriors within these lower dimensional spaces. 2 The Spike-and-Slab Sparse Coding Model and Parameter Optimization The spike-and-slab sparse coding model (see [8, 6] and citations therein) used for our study assumes a Bernoulli prior over all H components of the the binary latent vectorb ∈{0, 1}H, with a Gaussian prior (the ‘slab’) for the continuous latent vector z ∈RH: p(b | Θ) = h πbh (1 −π)1−bh, p(z | Θ) = h N(zh; µh, ψ2 h), (1) where π defines the probability of bh being equal to one and where µ ∈RH and ψ ∈RH parameterize the Gaussian slab. A spike-and-slab hidden variable s ∈RH is then generated by a pointwise multiplication: s = (b z), i.e., sh = bh zh. Given the hidden variable s, we follow standard sparse coding by linearly superimposing a set of latent components (i.e., Ws = h Whsh) to initialize the mean of a Gaussian noise model: p(y |s, Θ) = d N(yd; h Wdhsh, σ2 d), (2) which then generates us the observed data y ∈RD. Here the columns of the matrix W ∈RD×H are each a latent component Wh that is associated with a spike-and-slab latent variable sh. We use σ ∈RD to parameterize the observation noise. The parameters of the generative model (1) to (2) are together denoted by Θ = (π, µ, ψ, W,σ). To find the values of Θ, we seek to maximize the data likelihood L = N n=1 p(y (n) | Θ) under the spike-and-slab data model and given a set of N data points {y (n)}n=1,...,N. To derive a learning algorithm, we apply expectation maximization (EM) in its free-energy formulation. In our case the free-energy is given by: F(q, Θ) = N n=1 log p(y (n),s | Θ) n + H(q(n)), where f(s) n = q(n)(s) f(s)ds is the expectation under q(n), a distribution over the latent space and H( · ) denotes the Shannon entropy. Given the free-energy, the parameter updates are canonically derived by setting the partial derivatives of F(q, Θ) w.r.t. the parameters to zero. For the spike-and-slab sparse coding model (1) and (2), we obtain (similar to [8, 6, 7]) the following closed-form M-step equations: π = 1 NH n |b| n , ψ2 h = n (sh −µhbh)2 n n bh n , (3) W = n y (n) s T n n ssT n , µ = n s n n b n , and σ2 d = 1 N n ( h Wdhsh −y(n) d )2 n (4) 2 with sh = bh zh and |x| = h xh as defined above. 3 Approximate Inference With Select-and-Sample The optimal choices for the distributions q(n)(s) for the expectations in (3) and (4) are the posteriors p(s | y (n), Θ), but neither the posteriors nor their corresponding expectation values are computationally tractable for high dimensions. However, a crucial observation that we exploit in our work is that for observed data such as natural sensory input or data generated by a sparse coding model, the activity of latent components (or causes) can be expected to be concentrated in low-dimensional subspaces. In other words, for a given observed data point, all except for a very small fraction of the latent components can be assumed to be non-causal or irrelevant, hence the corresponding latent space can be neglected for the integration over s. For a sparse initiation (i.e., π 1) of the spike-and-slab model (1) to (2), we consider such low dimensional subspaces to be spanned by a few (approximately πH) of the H latent space coordinates. If we denote by J (n) the subspace containing the large majority of posterior mass for a given data point y (n), an approximation to p(s | y (n), Θ) is then given by the following truncated distribution: q(n)(s; Θ) = p(s | y (n), Θ) s ∈J (n)p(s | y (n), Θ) ds δ(s ∈J (n)), (5) where δ(s ∈J (n)) is an indicator function, taking the value δ(s ∈J (n)) = 1 only if s ∈J (n) and zero otherwise. Truncated approximations have previously been shown to work efficiently and accurately for challenging data models [14, 15, 16]. Latents were restricted to be binary, however, and scalability was previously limited by the combinatorics within the selected latent subsets. For our aim of very large scale applications, we therefore apply the select-and-sample approach [13] and use a sampling approximation that operates within the subspaces J (n). Unlike [13] who used binary latents, we here apply the approximation to the continuous latent space of spike-and-slab sparse coding. Formally, this means that we first use the posterior approximation q(n)(s) in Eqn. 5 and then approximate the expectation values w.r.t. q(n)(s) using sampling (see illustration of Alg. 1): f(s) n = q(n)(s) f(s) ds ≈ 1 M M m=1 f(s (m)), where s (m) ∼q(n)(s) , (6) M is the number of samples and f(s) can be any argument of the expectation values in (3) and (4). It remains to be shown how difficult sampling from q(n)(s) is compared to directly sampling form the full posterior p(s | y (n), Θ). The index function δ(s ∈J (n)) means that we can clamp all values of s to zero but we have to answer the question how the remaining sh are sampled. A closer analysis of the problem shows that the distribution to sample in the reduced space is given by the posterior w.r.t. a truncated generative model. To show this, let us first introduce some notation: Let us denote by I a subset of the indices of the latent variables s, i.e., I ⊆{1, . . . , H}, and let us use H\I as an abbreviation for {1, . . . , H}\I. The vector sI w.r.t. I is then, as customary, a vector in R|I| defined by those entries sh with h ∈I. In analogy, we take a matrix WI ∈RD×|I| to be defined by row vectors (wT d )I where wT d are the row vectors of W ∈RD×H. Proposition 1. Consider the spike-and-slab generative model (1) to (2) with parameters Θ, and let ΘI(n) = (π, µI(n), ψI(n), WI(n),σ) be the parameters of a truncated spike-and-slab model with H = dim(I(n)) dimensional latent space. Then it applies that sampling from the truncated distribution in (5) is equivalent to sampling from the posterior p(sI(n) | y (n), ΘI(n)) of the truncated spike-and-slab model, while all values sh with h ∈I(n) are clamped to zero. Proof. If I(n) denotes the indices of those latents sh that span the subspace in which the posterior mass of p(s | y (n), Θ) is concentrated, then these subsets are given by J (n) = {s ∈RH |sH\I(n) = 0}, i.e., δ(s ∈J (n)) can be rewritten as h∈I(n) δ(sh = 0). Considering (5), we can therefore set the corresponding values sH\I(n) = 0. We now drop the 3 superscript n for readability and first derive: p(sI,sH\I = 0, y | Θ) = N(y; WIsI + WH\I0,σ) h∈I Bern(bh; π)N(zh; µh, ψh) h∈I Bern(bh = 0; π)N(zh; µh, ψh) = p(sI, y | ΘI) U(sH\I = 0, Θ) with U(sH\I, Θ) = p(sH\I | ΘH\I), i.e., the joint with sH\I = 0 is given by the joint of the truncated model multiplied by a term not depending on sI such that: q(s; Θ) = p(sI,sH\I = 0, y | Θ) δ(s ∈J ) s ∈J p(s I,s H\I = 0, y | Θ) ds = p(sI, y | ΘI) U(sH\I = 0, Θ) δ(s ∈J ) s ∈J p(s I, y | ΘI) ds U(sH\I = 0, Θ) = p(sI, y | ΘI) s p(s I, y | ΘI) ds I h∈I δ(sh = 0) = p(sI | y, ΘI) h∈I δ(sh = 0) . (7) Following the proof, Proposition 1 applies for any generative model p(s, y | Θ) for which applies p(sI,sH\I = 0, y | Θ) = p(sI, y | ΘI) U(sH\I = 0, y, Θ). This includes a large class of models such as linear and non-linear spike-and-slab models, and potentially hierarchical models such as SBNs. Proposition 1 does not apply in general, however (we exploit specific model properties). Sampling. In previous work [7], posteriors for spike-and-slab sparse coding have been evaluated exhaustively within selected I(n) which resulted in scalability to be strongly limited by the dimensionality of I(n). Based on Proposition 1, we can now overcome this bottleneck by using sampling approximations within the subspaces J (n), and we have shown that such sampling is equivalent to sampling w.r.t. to a much lower dimensional spike-and-slab model. The dimensionality of J (n) is still non-trivial, however, and we use a Markov chain Monte Carlo (MCMC) approach, namely Gibbs sampling for efficient scalability. Following Proposition 1 we derive a sampler for the spike-and-slab model (1) to (2) and later apply it for the needed (low) dimensionality. While the result of sampling from posteriors of truncated models applies for a broad class of spikeand-slab models (Proposition 1), we can here exploit a further specific property of the model (1) to (2). As has previously been observed and exploited in different contexts [8, 12, 17], the Gaussian slab and the Gaussian noise model can be combined using Gaussian identities such that integrals over the continuous latents z are solvable analytically. Here we can use this observation for the derivation of a Gibbs sampler. For this we first devise a latent variable Markov chain such that its target density is given by the following conditional posterior distribution: p(sh|sH\h, y, θ) ∝p(sh|θ) d p(yd|sh,sH\h, θ) = (1 −π) ˜δ(sh) + π N(sh; µh, ψ2 h) d N(sh; νd, ϕ2 d) , (8) where ˜δ(.) is the Dirac delta to represent the spike at zero and where νd = (yd − h\h Wdhsh)/Wdh and ϕ2 d = σ2 d/W 2 dh. Using Gaussian identities we obtain: p(sh|sH\h, y, θ) ∝ (1 −π) N(sh; υ, φ2) ˜δ(sh) + π N(sh; τ, ω2) , (9) where υ = φ2 d νd/ϕ2 d and φ2 = ( d 1/ϕ2 d)−1, whereas τ = ω2 (υ/φ2 + µh/ψ2 h) and ω2 = (1/φ2 + 1/ψ2 h)−1. We can observe that the conditional posterior (9) of sh retains the form of a spike-and-slab distribution. We can therefore simply compute the cumulative distribution function (CDF) of (9) to simulate sh from the exact conditional distribution (sh ∼p(sh|sH\h , y, θ)) by means of inverse transform sampling. Selecting. The Gibbs sampler can now be applied to generate posterior samples for a truncated spike-and-slab model (defined using parameters ΘI(n)). We also obtain a valid approximation, of course, without selection (I = {1,...,H}) but MCMC samplers in very high dimensional spaces 4 Algorithm 1: Select-and-sample for spike-and-slab sparse coding (S5C) init Θ; repeat for (n = 1, ..., N) do for (h = 1, ..., H) do compute Sh(y (n)) as in (10); define I(n) as in (11); for (m = 1, . . . , M) do draw s(m) I(n) ∼p(sI(n) | y (n), ΘI(n)) using (9); compute f(s) n = 2 M M m= M 2 +1 f(s (m)); compute M-step with arguments f(s) as in (3) and (4); until (until Θ have converged); Illustration of general application. with complex posterior structure are known to be challenging (convergence to target distributions can be very slow). The problems typically increase superlinearly with hidden dimensionality but for intermediate dimensions, a Gibbs sampler can be very fast and accurate. By using subspaces J (n) with intermediate dimensionality, therefore, results in very efficient and accurate sampling approximations within these spaces. An overall very accurate approximation is then obtained if the subspaces are well selected and if they do contain the large majority of posterior mass. By using exact EM it was indeed previously shown for spike-and-slab sparse coding [7] that almost all posterior mass, e.g., for naturally mixed sound sources, is concentrated in collections of low-dimensional subspaces (also compare [18]). To define a subspace J (n) given a data point y (n), we follow earlier approaches [15, 14] and first define an efficiently computable selection function to choose those latents that are the most likely to have generated the data point. We use the selection function in [7] which is given by: Sh(y (n), Θ) = d N(y (n) d ; Wdhµh, σd + W 2 dh/ψh) ∝p(y (n) |b = bh, Θ), (10) wherebh represents a singleton state with only component h being equal to one. The subsets are then defined as follows: I(n) is the set of H indices such that ∀h ∈I(n) ∀h ∈I(n) : Sh(y (n), Θ) > Sh(y (n), Θ). (11) We then use J (n) = {s |sH\I(n) = 0} as above. In contrast to previous approaches with H typically < 10, H can be chosen relatively large here because the Gibbs sampler is still very efficient and precise for H > 10 (we will go up H = 40). By combining selection procedure and the Gibbs sampler using Proposition 1, we obtain the efficient approximate EM algorithm summarized in Alg. 1. It will be referred to as S5C (see Alg. 1 caption). Note that we will, for all experiments, always discard the first half of the drawn samples as burn-in. 4 Numerical Experiments In all the experiments, the initial values of π were drawn from a uniform distribution on the interval [0.1, 0.5] (i.e., intermediately sparse), µ was initialized with normally distributed random values, ψh was set to 1 and σd was initialized with the standard deviation of yd. The elements of W were iid drawn from a normal distribution with zero mean and a standard deviation of 5.0. We used a multi-core parallelized implementation and executed the algorithm on up to 1000 CPU cores. Verification of functional accuracy. We first investigate the accuracy and convergence properties of our method on ground-truth data which was generated by the spike-and-slab data model (1) and (2) itself. We used H = 10 hidden variables and D = 5 × 5 and generative fields Wh in the form of five horizontal and five vertical bars. As is customary for such bars like data (e.g., [15] and cites therein) we take each field to contribute to a data point with probability π = 2 H . We then randomly make each of the 5 vertical and 5 horizontal bars positive or negative by assigning them a value of 5 5 Figure 1: Functional accuracy of S5C. A Artificial ground-truth data. B Likelihoods during learning (Alg. 1) for different H. C Denoising performance of S5C on the ‘house’ benchmark as used for other methods (MTMKL [8], K-SVD [4], Beta process [11] and GSC-ET [7]. Bold values highlight the best performing algorithm. ∗Value not bold-faced as noise variance is assumed known a-priori[4]. D Top: Noisy image with σ = 25. Bottom: State-of-the art denoising result after S5C was applied. or −5, while the non-bar pixels are assigned zero value. The parameters of the latent slabs µh and ψh are set to 0.0 and 1.0, respectively, and we set the observation noise to σd = 1.0. We generate N = 5000 data points with this setting (see Fig. 1A for examples). We apply the S5C algorithm (Alg. 1) with H = 10 latents and M = 40 samples per data point and use two settings for preselection: (A) no preselection (H = H = 10) and (B) subspace preselection using H = 5. We did ten runs per setting using different initializations per run as above. For setting (A), i.e. pure Gibbs sampling, the algorithm recovered, after 150 EM iterations, the generating bars in 2 of the 10 runs. For setting (B) convergence was faster and in 9 of the 10 runs all bars were recovered after 50 EM iterations. Fig. 1B shows for all 20 runs likelihoods during learning (which are still tractable for H = 10). These empirical results show the same effect for a continuous latent variable model as was previously reported for non-continuous latents [19, 20]: preselection helps avoiding local optima (presumably because poor non-sparse solutions are destabilized using subspace selection). After having verified the functioning of S5C on artificial data, we turned to verifying the approach on a denoising benchmark, which is standard for sparse coding. We applied S5C using a noisy “house” image [following 11, 4, 8, 7]. We used three different levels of added Gaussian noise (σ = 15, 25, 50). For each setting we extract 8 × 8 patches from 256 × 256 noisy image, visiting a whole grid of 250 × 250 pixels by shifting (vertically and horizontally) 1 pixel at a time. In total we obtained N = 62, 001 overlapping image patches as data points. We applied the S5C algorithm with H = 256, select subspaces with H = 40 and used M = 100 samples per subspace. Fig. 1C,D show the obtained results and a comparison to alternative approaches. As can be observed, S5C is competitive to other approaches and results in higher peak signal-to-noise ratios (PSNRs) (see [7] for details) than, e.g., K-SVD or factored variational EM approaches (MTMKL) for σ = 25 and 50. Even though S5C uses the additional sampling approximation in the selected subspaces, it is also competitive to ET-GSC [7], which is less efficient as it sums exhaustively within subspaces. For σ = 25 S5C even outperforms ET-GSC presumably because S5C allows for selecting larger subspaces. In general we observed increased improvement with the number of samples, but improvements with H saturated after about H = 256. Large-scale application and V1 encoding. Since sparse coding was first suggested as coding model for primary visual cortex [21], a main goal has been its application to very high latent dimensions because V1 is believed to be highly overcomplete [1]. Furthermore, for very large hidden dimensions, non-standard generative fields were observed [1], a finding which is of significant relevance for the ongoing debate of how and where increasingly complex structures in the visual system may be processed. Here we applied S5C with H = 10 000 hidden dimensions to demonstrate scalability of the method, and to study highly-overcomplete V1 encoding based on a posterior approximation capturing rich structure. For our application we used the standard van Hateren database [22], extracted N = 106 image patches of size 16 × 16, and applied pseudo-whitening following [21]. We applied 6 Figure 2: Selection of different types of generative fields as learned by S5C using H = 10, 000 latent dimensions (see Suppl. for all fields). Gabor-like fields are the most frequent type (Gabors, ridgelets, gratings), followed by globular fields, curved fields and corner-like fields. We also observed textures other than gratings. Gabors, curved and corner fields were almost all among the 30% most frequently activated fields. Ridgelets, globular fields and gratings were typically among the 30-80% most used fields. S5C for 50 EM iterations to the data using H = 20 dimensional subspaces and M = 50 samples per data point. After learning we observed a large number of generative fields specialized to image components. Like in recent large-scale applications of standard sparse coding [1] we found fields that did not specialize (about 1% in [1] and about 12% for S5C). The higher percentage for S5C may be due to the five-fold higher dimensionality used here. For the fields specialized to components, we observed a large number of Gabor-like fields including ridgelets and gratings (names follow [1]). Furthermore, we observed globular fields that have been observed experimentally [23] and are subject of a number of recent theoretical studies (e.g., [14, 3]). Notably, we also observed a number of curved fields and fields sensitive to corner-like structures (Fig. 2 shows some examples). Curved fields have so far only been described to emerge from sparse coding once before [1] and for convolutional sparse coding in two cases [24, 25] (to the knowledge of the authors) but have been suggested for technical applications much earlier [26] (a link that was not made, so far). Corner-like structures have previously not been observed for sparse coding presumably because of lower dimensional latent spaces (also not in [1] but compare convolutional extensions [24, 16, 25]). The numbers of curved (a few hundred) and corner-like fields (a few tens) are small but we almost exclusively find those fields among the 20% most frequently used fields (we order according to average approx. posterior, see supplement). Neural responses to corner-like sensitivities are typically associated with higher-level processing in the visual pathway. Our results may be evidence for such structures to emerge together, e.g., with Gabors for very large latent dimensionality (as expected for V1). In general, the statistics of generative field shapes can be influenced by many factors including preprocessing details, sparsity, local optima or details of the learning algorithms. However, because of the applied approximation, S5C can avoid the for MAP based approaches required choice of the sparsity penalty [1]. Instead we statistically infer the sparsity level which is well interpretable for hard sparsity, and which corresponds for our application to Hπ = 6.2 components per patch (also compare [14, 20]). In the supplement we provide the full set of the H = 10 000 learned generative fields. Figure 3: The y-axis shows the highest reported latent dimensionality for different sparse coding algorithms (cont. latents), and the xaxis the accuracy of posterior approximations. Within each column, entries are ordered (left-to-right) w.r.t. the publication year. 1st column: Sparse coding systems using one latent state for inference (eg., MAP-like [27, 28, 1] or SAILnet [3] or KSVD [4, 5]). 2nd: Approximate posteriors in the form of factored variational distributions that can capture multiple modes but assume posterior independence among the latents sh (MTMKL [8], S3C [6]). 3rd: Sampling based approximations [11, 12] and truncated approximations (ssMCA [20], GSC-ET [7]) that capture multiple posterior modes and complex latent dependencies. Following [6] we also included ssRBM for comparison. 4th: Full posterior with exact EM [17]. 7 5 Discussion In this study we have applied a select-and-sample approach [13] to derive and study an approximate EM algorithm applicable to models with very large-scale latent spaces. Select-and-sample combines sampling with subspace preselection [15, 14] and has previously been applied as model for neural inference using binary latents [13]. Furthermore, it has been used to overcome analytical intractabilities of a non-linear sparse coding model [20]. Here, we for the first time apply select-and-sample to scale a standard linear sparse coding model with spike-and-slab prior up to very large hidden dimensions. Spike-and-slab sparse coding is hereby not only more expressive than standard Laplace or binary priors [8, 12, 7, 20] but results in properties that we can exploit for our approximation. We have thus analytically shown (Proposition 1) that select-and-sample is applicable to a large class of models with hard sparsity (giving justification also to earlier applications [20]). Empirically, we have, firstly, shown that select-and-sample for spike-and-slab sparse coding (S5C) maintains the functional competitiveness of alternative approaches (Fig. 1). Secondly, we demonstrated efficiency by scaling S5C up to very high-dimensional latent spaces (we go up to 10 000). For comparison, Fig. 3 shows the largest reported latent spaces of different sparse coding approaches depending on the posterior structure that can be captured. Non-probabilistic approaches (e.g., K-SVD [4, 5]) are known to scale relatively well, and, likewise, approaches using MAP approximations [2, 3, 1] have been shown to be applicable to large scales. None of these approaches captures posterior dependencies or multiple posterior modes given a data point, however. Factored variational approaches can be scaled to very high-dimensional latent spaces and can capture multiple posterior modes. No latent dependencies in the posterior are modeled, however, which has previously been reported to result in disadvantageous behavior (e.g. [29, 7]). In contrast to MAP-based or factored approaches, sampling approaches can model both multiple posterior modes and complex latent dependencies. Some models hereby additionally include a more Bayesian treatment of parameters [11, 12] (also compare [8]) which can be considered more general than approaches followed in other work (see Fig. 3). The scalability of sampling based approaches has been limited, however. Among those models capturing the crucial posterior structure, S5C shows, to the knowledge of the authors, the largest scale applicability. This is even the case if approaches using factored posteriors are included. Notably there is also little reported for very large hidden dimensions for MAP based or deterministic approaches (compare, e.g., [5]), although scalability should be less of an issue. In general it may well be that a method is scalable to larger than the reported latent spaces but that such increases do not result in functional benefits. For probabilistic approaches, the requirement for approximations with high accuracy have been identified also in other very promising work [30, 31] which uses different approaches that were, so far, applied to much smaller scales. For the select-and-sample method and the spike-and-slab sparse coding model, the high-dimensional applicability means that this or similar approaches are a promising candidate for models such as DBNs, SBNs or CNNs because of their close relation to spike-and-slab models and their typically similarly large scale settings. Here we have studied an application of S5C to standard image patches, primarily to demonstrate scalability. The obtained non-standard generative fields may by themselves, however, be of relevance for V1 encoding (Fig. 2) and they show that spike-and-slab models may be very suitable generalized V1 models. From a probabilistic view on neural processing, the accuracy that can be provided by select-and-sample inference is hereby very desirable and is consistent, e.g., with sampling-based interpretations of neural variability [32]. Here we have shown that such probabilistic approximations are also functionally competitive and scalable to very large hidden dimensions. Acknowledgements. We thank E. Guiraud for help with Alg. 1 (illustration) and acknowledge funding by the DFG: Cluster of Excellence EXC 1077/1 (Hearing4all) and grant LU 1196/5-1. References [1] B. Olshausen. Highly overcomplete sparse coding. In Proc. SPIE, 8651, 2013. [2] B. Olshausen and D. Field. Sparse coding with an overcomplete basis set: A strategy employed by V1? Vision Research, 37(23):3311–3325, 1997. [3] J. Zylberberg, J. Murphy, and M. DeWeese. A Sparse Coding Model with Synaptically Local Plasticity and Spiking Neurons Can Account for the Diverse Shapes of V1 Simple Cell Receptive Fields. PLoS Comp. Bio., 7(10):e1002250, 2011. [4] H. Li and F. Liu. Image denoising via sparse and redundant representations over learned dictionaries in wavelet domain. In ICIG, pages 754–758, 2009. 8 [5] A. Mensch, J. Mairal, B. Thirion, and G. Varoquaux. Dictionary learning for massive matrix factorization. ICML, 2016. [6] I. J. Goodfellow, A. Courville, and Y. Bengio. Scaling up spike-and-slab models for unsupervised feature learning. TPAMI, 35(8):1902–1914, 2013. [7] A. S. Sheikh, J. A. Shelton, and J. Lücke. A truncated EM approach for spike-and-slab sparse coding. JMLR, 15:2653–2687, 2014. [8] M. Titsias and M. Lazaro-Gredilla. Spike and slab variational inference for multi-task and multiple kernel learning. In NIPS, pages 2339–2347, 2011. [9] G. E. Hinton, B. Sallans, and Z. Ghahramani. A hierarchical community of experts. In Learning in graphical models, pages 479–494. Springer, 1998. [10] Ankit B Patel, Tan Nguyen, and Richard G Baraniuk. A probabilistic theory of deep learning. In Advances in Neural Information Processing Systems (NIPS), 2016. in press, preprint arXiv:1504.00641. [11] M. Zhou, H. Chen, J. Paisley, L. Ren, G. Sapiro, and L. Carin. Non-parametric Bayesian dictionary learning for sparse image representations. In NIPS, pages 2295–2303, 2009. [12] S. Mohamed, K. Heller, and Z. Ghahramani. Evaluating Bayesian and L1 approaches for sparse unsupervised learning. In ICML, 2012. [13] J. Shelton, J. Bornschein, A.-S. Sheikh, P. Berkes, and J. Lücke. Select and sample — a model of efficient neural inference and learning. In NIPS, pages 2618–2626, 2011. [14] G. Puertas, J. Bornschein, and J. Lücke. The maximal causes of natural scenes are edge filters. In NIPS, volume 23, pages 1939–47, 2010. [15] J. Lücke and J. Eggert. Expectation truncation and the benefits of preselection in training generative models. JMLR, 11:2855–2900, 2010. [16] Z. Dai, G. Exarchakis, and J. Lücke. What are the invariant occlusive components of image patches? A probabilistic generative approach. In NIPS 26, pages 243–251. 2013. [17] J. Lücke and A.-S. Sheikh. Closed-form EM for sparse coding and its application to source separation. In LVA, pages 213–221, 2012. [18] K. Schnass. Local identification of overcomplete dictionaries. JMLR, 16:1211–1242, 2015. [19] G. Exarchakis, M. Henniges, J. Eggert, and J. Lücke. Ternary sparse coding. In LVA/ICA, pages 204–212, 2012. [20] J. A. Shelton, A. S. Sheikh, J. Bornschein, P. Sterne, and J. Lücke. Nonlinear spike-and-slab sparse coding for interpretable image encoding. PLoS ONE, 10:e0124088, 05 2015. [21] B. Olshausen and D. Field. Emergence of simple-cell receptive field properties by learning a sparse code for natural images. Nature, 381:607–609, 1996. [22] J. H. van Hateren and A. van der Schaaf. Independent component filters of natural images compared with simple cells in primary visual cortex. Proceedings of the Royal Society of London B, 265:359 – 366, 1998. [23] D. L. Ringach. Spatial structure and symmetry of simple-cell receptive fields in macaque primary visual cortex. Journal of Neurophysiology, 88:455 – 463, 2002. [24] P. Jost, P. Vandergheynst, S. Lesage, and R. Gribonval. Motif: an efficient algorithm for learning translation invariant dictionaries. In IEEE Int. Conf. Acoustics Speech and Sig. Processing, volume 5, 2006. [25] J. Mairal, F. Bach, and J. Ponce. Sparse modeling for image and vision processing. Foundations and Trends in Computer Graphics and Vision, 8(2-3):85–283, 2014. [26] N. Krüger and G. Peters. Object recognition with banana wavelets. In Eur. Symp. ANNs, 1997. [27] P. Garrigues and B. A. Olshausen. Learning horizontal connections in a sparse coding model of natural images. In NIPS, 2007. [28] A. Coates and A. Y. Ng. The importance of encoding versus training with sparse coding and vector quantization. In Proc. ICML, pages 921–928, 2011. [29] A. Ilin and H. Valpola. On the effect of the form of the posterior approximation in variational learning of ICA models. Neural Processing Letters, 22(2):183–204, 2005. [30] T. Salimans, D. Kingma, and M. Welling. Markov chain monte carlo and variational inference: Bridging the gap. ICML, 2015. [31] D. Rezende and S. Mohamed. Variational inference with normalizing flows. ICML, 2015. [32] P. Berkes, G. Orban, M. Lengyel, and J. Fiser. Spontaneous Cortical Activity Reveals Hallmarks of an Optimal Internal Model of the Environment. Science, 331(6013):83–87, January 2011. 9 | 2016 | 503 |
6,443 | Learning Infinite RBMs with Frank-Wolfe Wei Ping∗ Qiang Liu† Alexander Ihler∗ ∗Computer Science, UC Irvine †Computer Science, Dartmouth College {wping,ihler}@ics.uci.edu qliu@cs.dartmouth.edu Abstract In this work, we propose an infinite restricted Boltzmann machine (RBM), whose maximum likelihood estimation (MLE) corresponds to a constrained convex optimization. We consider the Frank-Wolfe algorithm to solve the program, which provides a sparse solution that can be interpreted as inserting a hidden unit at each iteration, so that the optimization process takes the form of a sequence of finite models of increasing complexity. As a side benefit, this can be used to easily and efficiently identify an appropriate number of hidden units during the optimization. The resulting model can also be used as an initialization for typical state-of-the-art RBM training algorithms such as contrastive divergence, leading to models with consistently higher test likelihood than random initialization. 1 Introduction Restricted Boltzmann machines (RBMs) are two-layer latent variable models that use a layer of hidden units h to model the distribution of visible units v [Smolensky, 1986, Hinton, 2002]. RBMs have been widely used to capture complex distributions in numerous application domains, including image modeling [Krizhevsky et al., 2010], human motion capture [Taylor et al., 2006] and collaborative filtering [Salakhutdinov et al., 2007], and are also widely used as building blocks for deep generative models, such as deep belief networks [Hinton et al., 2006] and deep Boltzmann machines [Salakhutdinov and Hinton, 2009]. Due to the intractability of the likelihood function, RBMs are usually learned using the contrastive divergence (CD) algorithm [Hinton, 2002, Tieleman, 2008], which approximates the gradient of the likelihood using a Gibbs sampler. One practical problem when using a RBM is that we need to decide the size of the hidden layer (number of hidden units) before performing learning, and it can be challenging to decide what is the optimal size. One simple heuristic is to search the ‘best” number of hidden units using cross validation or testing likelihood within a pre-defined candidate set. Unfortunately, this is extremely time consuming; it involves running a full training algorithm (e.g., CD) for each possible size, and thus we can only search over a relatively small set of sizes using this approach. In addition, because the log-likelihood of the RBM is highly non-convex, its performance is sensitive to the initialization of the learning algorithm. Although random initializations (to relatively small values) are routinely used in practice with algorithms like CD, it would be valuable to explore more robust algorithms that are less sensitive to the initialization, as well as smarter initialization strategies to obtain better results. In this work, we propose a fast, greedy algorithm for training RBMs by inserting one hidden unit at each iteration. Our algorithm provides an efficient way to determine the size of the hidden layer in an adaptive fashion, and can also be used as an initialization for a full CD-like learning algorithm. Our method is based on constructing a convex relaxation of the RBM that is parameterized by a distribution over the weights of the hidden units, for which the training problem can be framed as a convex functional optimization and solved using an efficient Frank-Wolfe algorithm [Frank and Wolfe, 1956, Jaggi, 2013] that effectively adds one hidden unit at each iteration by solving a relatively fast inner loop optimization. 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. Related Work Our contributions connect to a number of different themes of existing work within machine learning and optimization. Here we give a brief discussion of prior related work. There have been a number of works on convex relaxations of latent variable models in functional space, which are related to the gradient boosting method [Friedman, 2001]. In supervised learning, Bengio et al. [2005] propose a convex neural network in which the number of hidden units is unbounded and can be learned, and Bach [2014] analyzes the appealing theoretical properties of such a model. For clustering problems, several works on convex functional relaxation have also been proposed [e.g., Nowozin and Bakir, 2008, Bradley and Bagnell, 2009]. Other forms of convex relaxation have also been developed for two layer latent variable models [e.g., Aslan et al., 2013]. There has also been considerable work on extending directed/hierarchical models into “infinite” models such that the dimensionality of the latent space can be automatically inferred during learning. Most of these methods are Bayesian nonparametric models, and a brief overview can be found in Orbanz and Teh [2011]. A few directions have been explored for undirected models, particularly RBMs. Welling et al. [2002] propose a boosting algorithm in the feature space of the model; a new feature is added into the RBM at each boosting iteration, instead of a new hidden unit. Nair and Hinton [2010] conceptually tie the weights of an infinite number of binary hidden units, and connect these sigmoid units with noisy rectified linear units (ReLUs). Recently, Côté and Larochelle [2015] extend an ordered RBM model with infinite number of hidden units, and Nalisnick and Ravi [2015] use the same technique for word embedding. The ordered RBM is sensitive to the ordering of its hidden units and can be viewed as an mixture of RBMs. In contrast, our model incorporates regular RBMs as a special case, and enables model selection for standard RBMs. The Frank-Wolfe method [Frank and Wolfe, 1956] (a.k.a. conditional gradient) is a classical algorithm to solve constrained convex optimization. It has recently received much attention because it unifies a large variety of sparse greedy methods [Jaggi, 2013], including boosting algorithms [e.g., Beygelzimer et al., 2015], learning with dual structured SVM [Lacoste-Julien et al., 2013] and marginal inference using MAP in graphical models [e.g., Belanger et al., 2013, Krishnan et al., 2015]. Verbeek et al. [2003] proposed a greedy learning algorithm for Gaussian mixture models, which inserts a new component at each step and resembles our algorithm in its procedure. As one benefit, it provides a better initialization for EM than random initialization. Likas et al. [2003] investigate greedy initialization in k-means clustering. 2 Background A restricted Boltzmann machine (RBM) is an undirected graphical model that defines a joint distribution over the vectors of visible units v ∈{0, 1}|v|×1 and hidden units h ∈{0, 1}|h|×1, p(v, h | θ) = 1 Z(θ) exp v⊤Wh + b⊤v ; Z(θ) = X v X h exp v⊤Wh + b⊤v , (1) where |v| and |h| are the dimensions of v and h respectively, and θ := {W, b} are the model parameters including the pairwise interaction term W ∈R|v|×|h| and the bias term b ∈R|v|×1 for the visible units. Here we drop the bias term for the hidden units h, since it can be achieved by introducing a dummy visible unit whose value is always one. The partition function Z(θ) serves to normalize the probability to sum to one, and is typically intractable to calculate exactly. Because RBMs have a bipartite structure, the conditional distributions p(v|h; θ) and p(h|v; θ) are fully factorized and can be calculated in closed form, p(h|v, θ) = |h| Y i=1 p(hi|v), with p(hi = 1|v) = σ vT W•i , p(v|h, θ) = |v| Y j=1 p(vj|h), with p(vj = 1|h) = σ Wj•h + bj , (2) where σ(u) = 1/(1 + exp(−u)) is the logistic function, and W•i and Wj• and are the i-th column and j-th row of W respectively. Eq. (2) allows us to derive an efficient blocked Gibbs sampler that iteratively alternates between drawing v and h. 2 The marginal log-likelihood of the RBM is log p(v | θ) = |h| X i=1 log 1 + exp(w⊤ i v) + b⊤v −log Z(θ), (3) where wi := W•i is the i-th column of W and corresponds to the weights connected to the i-th hidden unit. Because we assume each hidden unit hi takes values in {0, 1}, we get the softplus function log(1 + exp(w⊤ i v)) when we marginalize hi. This form shows that the (marginal) free energy of the RBM is a sum of a linear term b⊤v and a set of softplus functions with different weights wi; this provides a foundation for our development. Given a dataset {vn}N n=1, the gradient of the log-likelihood for each data point vn is ∂log p(vn|θ) ∂W = Ep(h|vn;θ) vnh⊤ −Ep(v,h|θ) vh⊤ = vn(µn)⊤−Ep(v,h|θ) vh⊤ , (4) where µn = σ(W ⊤vn) and the logistic function σ is applied in an element-wise manner. The positive part of the gradient can be calculated exactly, since the conditional distribution p(h|vn) is fully factorized. The negative part arises from the derivatives of the log-partition function and is intractable. Stochastic optimization algorithms, such as CD [Hinton, 2002] and persistent CD [Tieleman, 2008], are popular methods to approximate the intractable expectation using Gibbs sampling. 3 RBM with Infinite Hidden Units In this section, we first generalize the RBM model defined in Eq. (3) to a model with an infinite number of hidden units, which can also be viewed as a convex relaxation of the RBM in functional space. Then, we describe the learning algorithm. 3.1 Model Definition Our general model is motivated by Eq. (3), in which the first term can be treated as an empirical average of the softplus function log(1 + exp(w⊤v)) under an empirical distribution over the weights {wi}. To extend this, we define a general distribution q(w) over the weight w, and replace the empirical averaging with the expectation under q(w); this gives the following generalization of an RBM with an infinite (possibly uncountable) number of hidden units, log p(v | q, ϑ) = αEq(w) log(1 + exp(w⊤v)) + b⊤v −log Z(q, ϑ), (5) Z(q, ϑ) = X v exp αEq(w) log(1 + exp(w⊤v)) + b⊤v , where ϑ := {b, α} and α > 0 is a temperature parameter which controls the “effective number” of hidden units in the model, and Eq(w)[f(w)] := R w q(w)f(w)dw. Note that q(w) is assumed to be properly normalized, i.e., R w q(w)dw = 1. Intuitively, (5) defines a semi-parametric model whose log probability is a sum of a linear bias term parameterized by b, and a nonlinear term parameterized by the weight distribution w and α that controls the magnitude of the nonlinear term. This model can be regarded as a convex relaxation of the regular RBM, as shown in the following result. Proposition 3.1. The model in Eq. (5) includes the standard RBM (3) as special case by constraining q(w) = 1 |h| P|h| i=1 I(w = wi) and α = |h|. Moreover, the log-likelihood of the model is concave w.r.t. the function q(w), α and b respectively, and is jointly concave with q(w) and b. We should point out that the parameter α plays a special role in this model: we reduce to the standard RBM only when α equals the number |h| of particles in q(w) = 1 |h| P|h| i=1 I(w = wi), and would otherwise get a fractional RBM. The fractional RBM leads to a more challenging inference problem than a standard RBM, since the standard Gibbs sampler is no longer directly applicable. We discuss this point further in Section 3.3. Given a dataset {vn}N n=1, we learn the parameters q and ϑ using a penalized maximum likelihood estimator (MLE) that involves a convex functional optimization: arg max q∈M, ϑ L(q, ϑ) ≡1 N N X n=1 log p(vn | q, ϑ) −λ 2 Eq(w)[||w||2] , (6) 3 where M is the set of valid distributions and we introduce a functional L2 norm regularization Eq(w)[||w||2] to penalize the likelihood for large values of w. Alternatively, we could equivalently optimize the likelihood on MC = {q | q(w) ≥0 and R ||w||2≤C q(w) = 1}, which restricts the probability mass to a 2-norm ball ||w||2 ≤C. 3.2 Learning Infinite RBMs with Frank-Wolfe It is challenging to directly solve the optimization in Eq. (6) by standard gradient descent methods, because it involves optimizing the function q(w) with infinite dimensions. Instead, we propose to solve it using the Frank-Wolfe algorithm [Jaggi, 2013], which is projection-free and provides a sparse solution. Assume we already have qt at the iteration t; then Frank-Wolfe finds the qt+1 by maximizing the linearization of the objective function : qt+1 ←(1 −βt+1)qt + βt+1rt+1, where rt+1 ←arg max q∈M ⟨q, ∇qL(qt, ϑt)⟩, (7) where βt+1 ∈[0, 1] is a step size parameter, and the convex combination step guarantees the new qt+1 remains a distribution after the update. A typical step-size is βt = 1/t, in which case we have qt(w) = 1 t Pt s=1 rs(w), that is, qt equals the average of all the earlier solutions obtained by the linear program. To apply Frank-Wolfe to solve our problem, we need to calculate the functional gradient ∇qL(qt, ϑt) in E.q. (7). We can show that (see details in Appendix), ∇qL(qt, ϑt) = −λ 2 ||w||2 + αt 1 N N X n=1 log(1 + exp(w⊤vn)) − X v p(v | qt, ϑt) log(1 + exp(w⊤v)) , where p(v | qt, ϑt) is the distribution parametrized by the weight density qt(w) and parameter ϑt, p(v | qt, ϑt) = exp αtEqt(w)[log(1 + exp(w⊤v))] + b⊤ t v Z(qt, ϑt) . (8) The (functional) linear program in Eq. (7) is equivalent to an optimization over weight vector w : max q∈M⟨q, ∇qL(qt, ϑt)⟩= max q∈M Eq(w)[∇qL(qt, ϑt)] = −min w λ 2 ||w||2 + X v p(v | qt, ϑt) log(1 + exp(w⊤v)) −1 N N X n=1 log(1 + exp(w⊤vn)) (9) The gradient of the objective (9) is, ∇w = λw + Ep(v|qt,ϑt) σ(w⊤v) · v −1 N N X n=1 σ(w⊤vn) · vn, where the expectation over p(v | qt, ϑt) can be intractable to calculate, and one may use stochastic optimization and draw samples using MCMC. Note that the second two terms in the gradient enforce an intuitive moment matching condition: the optimal w introduces a set of “importance weights” σ(w⊤v) that adjust the empirical data and the previous model, such that their moments match with each other. Now, suppose w∗ t is the optimum of Eq. (9) at iteration t, the item rt(w) we added can be shown to be the delta over w∗ t , that is, rt(w) = I(w = w∗ t ); in addition, we have qt(w) = 1 t Pt s=1 I(w = w∗ s) when the step size is taken to be βt = 1 t . Therefore, this Frank-Wolfe update can be naturally interpreted as greedily inserting a hidden unit into the current model p(v | qt, ϑt). In particular, if we update the temperature parameter as αt ←t, according to Proposition 3.1, we can directly transform our model p(v | qt, ϑt) to a regular RBM after each Frank-Wolfe step, which enables the convenient blocked Gibbs sampling for inference. Compared with the (regularized) MLE of the standard RBM (e.g. in Eq. (4)), the optimization in Eq. (9) has the following nice properties: (1) The current model p(v | qt, ϑt) does not depend on 4 Algorithm 1 Frank-Wolfe Learning Algorithm Input: training data {vn}N n=1; step size η; regularization λ. Output: sparse solution q∗(w), and ϑ∗ Initialize q0(w) = I(w = w′) at random w′; b0 = 0; α0 = 1; for t = 1 : T [or, stopping criterion] do Draw sample {vs}S s=1 from p(v | qt−1, ϑt−1); w∗ t = argminw n λ 2 ||w||2 + 1 S PS s=1 log(1+exp(w⊤vs))−1 N PN n=1 log(1+exp(w⊤vn)) o ; Update qt(w) ←(1 −1 t ) · qt−1(w) + 1 t · I(w = w∗ t ); Update αt ←t (optional: gradient descent); Set bt = bt−1; repeat Draw a mini-batch samples {vm}M m=1 from p(v | qt, ϑt) Update bt ←bt + η · ( 1 N PN n=1 vn − 1 M PM m=1 vm) until end for Return q∗(w) = qt(w); ϑ∗= {bt, αt}; w, which means we can draw enough samples from p(v | qt, ϑt) at each iteration t, and reuse them during the optimization of w. (2) The objective function in Eq. (9) can be evaluated explicitly given a set of samples, and hence efficient off-the-shelf optimization tools such as L-BFGS can be used to solve the optimization very efficiently. (3) Each iteration of our method involves much fewer parameters (only the weights for a single hidden unit, which is |v| × 1 instead of the full |v| × |h| weight matrix are updated), and hence defines a series of easier problems that can be less sensitive to initialization. We note that a similar greedy learning strategy has been successfully applied for learning mixture models [Verbeek et al., 2003], in which one greedily inserts a component at each step, and that this approach can provide better initialization for EM optimization than using multiple random initializations. Once we obtain qt+1, we can update the bias parameter bt by gradient descent, ∇bL(qt+1, ϑt) = 1 N N X n=1 vn − X v p(v|qt+1, ϑt)v. (10) One can further optimize αt by gradient descent,1 but we find simply updating αt ←t is more efficient and works well in practice. We summarize our Frank-Wolfe learning algorithm in Algorithm 1. Adding hidden units on RBM. Besides initializing q(w) to be a delta function at some random w′ and learning the model from scratch, one can also adapt Algorithm 1 to incrementally add hidden units into an existing RBM in Eq. (3) (e.g. have been learned by CD). According to Proposition 3.1, one can simply initialize qt(w) = 1 |h| P|h| i=1 I(w = wi), αt = |h|, and continue the Frank-Wolfe iterations at t = |h| + 1. Removing hidden units. Since the hidden units are added in a greedy manner, one may want to remove an old hidden unit during the Frank-Wolfe learning, provided it is bad with respect to our objective Eq. (9) after more hidden units have been added. A variant of Frank-Wolfe with away-steps [Guélat and Marcotte, 1986] fits this requirement and can be directly applied. As shown by [Clarkson, 2010], it can improve the sparsity of the final solution (i.e., fewer hidden units in the learned model). 3.3 MCMC Inference for Fractional RBMs As we point out in Section 3.1, we need to take α equal to the number of particles in q(w) (that is, αt ←t in Algorithm 1) in order to have our model reduce to the standard RBM. If α takes a more general real number, we obtain a more general fractional RBM model, for which inference is 1see Appendix for the definition of ∇αL(qt, ϑt) 5 more challenging because the standard block Gibbs sampler is not directly applicable. In practice, we find that setting αt ←t to correspond to a regular RBM seems to give the best performance, but for completeness, we discuss the fractional RBM in more detail in this section, and propose a Metropolis-Hastings algorithm to draw samples from the fractional RBM. We believe that this fractional RBM framework provides an avenue for further improvements in future work. To frame the problem, let us assume αq(w) = P i ci · I(w = wi), where ci is a general real number; the corresponding model is log p(v | q, ϑ) = X i ci log(1 + exp(w⊤ i v)) + b⊤v −log Z(q, ϑ), (11) which differs from the standard RBM in (3) because each softplus function is multiplied by ci. Nevertheless, one may push the ci into the softplus function, and obtain a standard RBM that forms an approximation of (11): log ep(v | q, ϑ) = X i log(1 + exp(ci · w⊤ i v)) + b⊤v −log eZ(q, ϑ). (12) This approximation can be justified by considering the special case when the magnitude of the weights w is very large, so that the softplus function essentially reduces to a ReLU function, that is, log(1 + exp(w⊤ i v)) ≈max(0, w⊤ i v). In this case, (11) and (12) become equivalent because ci max(0, x) = max(0, cix). More concretely, we can guarantee the following bound: Proposition 3.2. For any 0 < ci ≤1,we have 1 21−ci (1 + exp(ci · w⊤ i v)) ≤(1 + exp(w⊤ i v))ci ≤1 + exp(ci · w⊤ i v). The proof can be found in the Appendix. Note that we apply the bound when ci > 1 by splitting ci into the sum of its integer part and fractional remainder, and apply the bound to the fractional part. Therefore, the fractional RBM (11) can be well approximated by the standard RBM (12), and this can be leveraged to design an inference algorithm for (11). As one example, we can use the Gibbs update of (12) as a proposal for a Metropolis-Hastings update for (11). To be specific, given a configuration v, we perform Gibbs update in RBM ep(v | q, ϑ) to get v′, and accept it with probability min(1, A(v →v′)), A(v →v′) = p(v′) eT(v′ →v) p(v) eT(v →v′) , where eT(v →v′) is the Gibbs transition of RBM ep(v | q, ϑ). Because the acceptance probability of a Gibbs sampler equals one, we have ep(v) e T (v→v′) ep(v′) e T (v′→v) = 1 . This gives A(v →v′) = p(v′)ep(v) p(v)ep(v′) = Q i(1 + exp(w⊤ i v′))ci · Q i(1 + exp(ci · w⊤ i v)) Q i(1 + exp(w⊤ i v))ci · Q i(1 + exp(ci · w⊤ i v′)) . 4 Experiments In this section, we test the performance of our Frank-Wolfe (FW) learning algorithm on two datasets: MNIST [LeCun et al., 1998] and Caltech101 Silhouettes [Marlin et al., 2010]. The MNIST handwritten digits database contains 60,000 images in the training set and 10,000 test set images, where each image vn includes 28 × 28 pixels and is associated with a digit label yn. We binarize the grayscale images by thresholding the pixels at 127, and randomly select 10,000 images from training as the validation set. The Caltech101 Silhouettes dataset [Marlin et al., 2010] has 8,671 images with 28×28 binary pixels, where each image represents objects silhouette and has a class label (overall 101 classes). The dataset is divided into three subsets: 4,100 examples for training, 2,264 for validation and 2,307 for testing. 6 0 100 200 300 400 500 600 700 −160 −140 −120 −100 −80 Number of hidden units Avg. test log−likelihood FW CD(rand init.) CD(FW init.) 100 200 300 400 500 600 700 −220 −200 −180 −160 −140 −120 Number of hidden units Avg. test log−likelihood FW CD(rand init.) CD(FW init.) (a) MNIST (b) Caltech101 Silhouettes Figure 1: Average test log-likelihood on the two datasets as we increase the number of hidden units. We can see that FW can correctly identify an appropriate hidden layer size with high test log-likelihood (marked by the green dashed line). In addition, CD initialized by FW gives higher test likelihood than random initialization for the same number of hidden units. Best viewed in color. Training algorithms We train RBMs with CD-10 algorithm. 2 A fixed learning rate is selected from the set {0.05, 0.02, 0.01, 0.005} using the validation set, and the mini-batch size is selected from the set {10, 20, 50, 100, 200}. We use 200 epochs for training on MINIST and 400 epochs on Caltech101. Early stopping is applied by monitoring the difference of average log-likelihood between training and validation data, so that the intractable log-partition function is cancelled [Hinton, 2010]. We train RBMs with {20, 50, 100, 200, 300, 400, 500, 600, 700} hidden units. We incrementally train a RBM model by Frank-Wolfe (FW) algorithm 1. A fixed step size η is selected from the set {0.05, 0.02, 0.01, 0.005} using the validation data, and a regularization strength λ is selected from the set {1, 0.5, 0.1, 0.05, 0.01}. We set T = 700 in Algorithm 1, and use the same early stopping criterion as CD. We randomly initialize the CD algorithm 5 times and select the best one on the validation set; meanwhile, we also initialize CD by the model learned from Frank-Wolfe. Test likelihood To evaluate the test likelihood of the learned models, we estimate the partition function using annealed importance sampling (AIS) [Salakhutdinov and Murray, 2008]. The temperature parameter is selected following the standard guidance: first 500 temperatures spaced uniformly from 0 to 0.5, and 4,000 spaced uniformly from 0.5 to 0.9, and 10,000 spaced uniformly from 0.9 to 1.0; this gives a total of 14,500 intermediate distributions. We summarize the averaged test log-likelihood of MNIST and Caltech101 Silhouettes in Figure 1, where we report the result averaged over 500 AIS runs in all experiments, with the error bars indicating the 3 standard deviations of the estimations. We evaluate the test likelihood of the model in FW after adding every 20 hidden units. We perform early stopping when the gap of average log-likelihood between training and validation data largely increases. As shown in Figure 1, this procedure selects 460 hidden units on MNIST (as indicated by the green dashed lines), and 550 hidden units on Caltech101; purely for illustration purposes, we continue FW in the experiment until reaching T = 700 hidden units. We can see that the identified number of hidden units roughly corresponds to the maximum of the test log-likelihood of all the three algorithms, suggesting that FW can identify the appropriate number of hidden units during the optimization. We also use the model learned by FW as an initialization for CD (the blue lines in Figure 2), and find it consistently performs better than the best result of CD with 5 random initializations. In our implementation, the running time of the FW procedure is at most twice as CD for the same number of hidden units. Therefore, FW initialized CD provides a practical strategy for learning RBMs: it requires approximately three times of computation time as a single run of CD, while simultaneously identifying the proper number of hidden units and obtaining better test likelihood. 2CD-k refers to using k-step Gibbs sampler to approximate the gradient of the log-partition function. 7 300 400 500 600 700 2 2.5 3 3.5 Number of hidden units Test error (%) FW CD(rand init.) CD(FW init.) 300 400 500 600 700 34 36 38 40 42 Number of hidden units Test error (%) FW CD(rand init.) CD(FW init.) (a) MNIST (b) Caltech101 Silhouettes Figure 2: Classification error when using the learned hidden representations as features. Classification The performance of our method is further evaluated using discriminant image classification tasks. We take the hidden units’ activation vectors Ep(h|vn)[h] generated by the three algorithms in Figure 1 and use it as the feature in a multi-class logistic regression on the class labels yn in MNIST and Caltech101. From Figure 2, we find that our basic FW tends to be worse than the fully trained CD (best in 5 random initializations) when only small numbers of hidden units are added, but outperforms CD when more hidden units (about 450 in both cases) are added. Meanwhile, the CD initialized by FW outperforms CD using the best of 5 random initializations. 5 Conclusion In this work, we propose a convex relaxation of the restricted Boltzmann machine with an infinite number of hidden units, whose MLE corresponds to a constrained convex program in a function space. We solve the program using Frank-Wolfe, which provides a sparse greedy solution that can be interpreted as inserting a single hidden unit at each iteration. Our new method allows us to easily identify the appropriate number of hidden units during the progress of learning, and can provide an advanced initialization strategy for other state-of-the-art training methods such as CD to achieve higher test likelihood than random initialization. Acknowledgements This work is sponsored in part by NSF grants IIS-1254071 and CCF-1331915. It is also funded in part by the United States Air Force under Contract No. FA8750-14-C-0011 under the DARPA PPAML program. Appendix Derivation of gradients The functional gradient of L(q, ϑ) w.r.t. the density function q(w) is ∇qL(q, ϑ) = −λ 2 ||w||2 + α 1 N N X n=1 log(1 + exp(w⊤vn)) − P v exp αEq(w)[log(1 + exp(w⊤v))] + b⊤v · log(1 + exp(w⊤v)) Z(q, b, α) = −λ 2 ||w||2 + α 1 N N X n=1 log(1 + exp(w⊤vn)) − X v p(v | q, ϑ) log(1 + exp(w⊤v)) . The gradient of L(q, ϑ) w.r.t. the temperature parameter α is ∇αL(q, ϑ) = 1 N N X n=1 Eq(w) log(1 + exp(w⊤vn)) − X v p(v | q, ϑ) Eq(w) log(1 + exp(w⊤v)) . 8 Proof of Proposition 4.2 Proof. For any 0 < c ≤1, we have following classical inequality, X k xk ≤( X k xc k)1/c, and 1 2 X k xk ≤(1 2 X k xc k)1/c Let x1 = 1 and x2 = exp(w⊤ i v), and the proposition is a direct result of above two inequalities. References Ö. Aslan, H. Cheng, X. Zhang, and D. Schuurmans. Convex two-layer modeling. In NIPS, 2013. F. Bach. Breaking the curse of dimensionality with convex neural networks. arXiv:1412.8690, 2014. D. Belanger, D. Sheldon, and A. McCallum. Marginal inference in MRFs using Frank-Wolfe. In NIPS Workshop on Greedy Optimization, Frank-Wolfe and Friends, 2013. Y. Bengio, N. L. Roux, P. Vincent, O. Delalleau, and P. Marcotte. Convex neural networks. In NIPS, 2005. A. Beygelzimer, E. Hazan, S. Kale, and H. Luo. Online gradient boosting. In NIPS, 2015. D. M. Bradley and J. A. Bagnell. Convex coding. In UAI, 2009. K. L. Clarkson. Coresets, sparse greedy approximation, and the Frank-Wolfe algorithm. ACM Transactions on Algorithms, 2010. M.-A. Côté and H. Larochelle. An infinite restricted Boltzmann machine. Neural Computation, 2015. M. Frank and P. Wolfe. An algorithm for quadratic programming. Naval Research Logistics Quarterly, 1956. J. H. Friedman. Greedy function approximation: a gradient boosting machine. Annals of Statistics, 2001. J. Guélat and P. Marcotte. Some comments on Wolfe’s ‘away step’. Mathematical Programming, 1986. G. Hinton. A practical guide to training restricted Boltzmann machines. UTML TR, 2010. G. Hinton, S. Osindero, and Y.-W. Teh. A fast learning algorithm for deep belief nets. Neural Computation, 2006. G. E. Hinton. Training products of experts by minimizing contrastive divergence. Neural Computation, 2002. M. Jaggi. Revisiting Frank-Wolfe: Projection-free sparse convex optimization. In ICML, 2013. R. G. Krishnan, S. Lacoste-Julien, and D. Sontag. Barrier Frank-Wolfe for marginal inference. In NIPS, 2015. A. Krizhevsky, G. E. Hinton, et al. Factored 3-way restricted Boltzmann machines for modeling natural images. In AISTATS, 2010. S. Lacoste-Julien, M. Jaggi, M. Schmidt, and P. Pletscher. Block-coordinate Frank-Wolfe optimization for structural SVMs. In ICML, 2013. Y. LeCun, L. Bottou, Y. Bengio, and P. Haffner. Gradient-based learning applied to document recognition. Proceedings of the IEEE, 1998. A. Likas, N. Vlassis, and J. J. Verbeek. The global k-means clustering algorithm. Pattern recognition, 2003. B. M. Marlin, K. Swersky, B. Chen, and N. D. Freitas. Inductive principles for restricted Boltzmann machine learning. In AISTATS, 2010. V. Nair and G. E. Hinton. Rectified linear units improve restricted Boltzmann machines. In ICML, 2010. E. Nalisnick and S. Ravi. Infinite dimensional word embeddings. arXiv:1511.05392, 2015. S. Nowozin and G. Bakir. A decoupled approach to exemplar-based unsupervised learning. In ICML, 2008. P. Orbanz and Y. W. Teh. Bayesian nonparametric models. In Encyclopedia of Machine Learning. 2011. R. Salakhutdinov and G. E. Hinton. Deep Boltzmann machines. In AISTATS, 2009. R. Salakhutdinov and I. Murray. On the quantitative analysis of deep belief networks. In ICML, 2008. R. Salakhutdinov, A. Mnih, and G. Hinton. Restricted Boltzmann machines for collaborative filtering. In ICML, 2007. P. Smolensky. Information processing in dynamical systems: Foundations of harmony theory. Technical report, DTIC Document, 1986. G. W. Taylor, G. E. Hinton, and S. Roweis. Modeling human motion using binary latent variables. In NIPS, 2006. T. Tieleman. Training restricted Boltzmann machines using approximations to the likelihood gradient. In ICML, 2008. J. J. Verbeek, N. Vlassis, and B. Kröse. Efficient greedy learning of Gaussian mixture models. Neural Computation, 2003. M. Welling, R. S. Zemel, and G. E. Hinton. Self supervised boosting. In NIPS, 2002. 9 | 2016 | 504 |
6,444 | Faster Projection-free Convex Optimization over the Spectrahedron Dan Garber Toyota Technological Institute at Chicago dgarber@ttic.edu Abstract Minimizing a convex function over the spectrahedron, i.e., the set of all d ⇥d positive semidefinite matrices with unit trace, is an important optimization task with many applications in optimization, machine learning, and signal processing. It is also notoriously difficult to solve in large-scale since standard techniques require to compute expensive matrix decompositions. An alternative is the conditional gradient method (aka Frank-Wolfe algorithm) that regained much interest in recent years, mostly due to its application to this specific setting. The key benefit of the CG method is that it avoids expensive matrix decompositions all together, and simply requires a single eigenvector computation per iteration, which is much more efficient. On the downside, the CG method, in general, converges with an inferior rate. The error for minimizing a β-smooth function after t iterations scales like β/t. This rate does not improve even if the function is also strongly convex. In this work we present a modification of the CG method tailored for the spectrahedron. The per-iteration complexity of the method is essentially identical to that of the standard CG method: only a single eigenvector computation is required. For minimizing an ↵-strongly convex and β-smooth function, the expected error of the method after t iterations is: O 0 @min{β t , β p rank(X⇤) ↵1/4t !4/3 , ✓ β p↵λmin(X⇤)t ◆2 } 1 A , where rank(X⇤), λmin(X⇤) are the rank of the optimal solution and smallest nonzero eigenvalue, respectively. Beyond the significant improvement in convergence rate, it also follows that when the optimum is low-rank, our method provides better accuracy-rank tradeoff than the standard CG method. To the best of our knowledge, this is the first result that attains provably faster convergence rates for a CG variant for optimization over the spectrahedron. We also present encouraging preliminary empirical results. 1 Introduction Minimizing a convex function over the set of positive semidefinite matrices with unit trace, aka the spectrahedron, is an important optimization task which lies at the heart of many optimization, machine learning, and signal processing tasks such as matrix completion [1, 13], metric learning [21, 22], kernel matrix learning [16, 9], multiclass classification [2, 23], and more. Since modern applications are mostly of very large scale, first-order methods are the obvious choice to deal with this optimization problem. However, even these are notoriously difficult to apply, since most of the popular gradient schemes require the computation of an orthogonal projection on each iteration to enforce feasibility, which for the spectraheron, amounts to computing a full eigen-decomposition 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. of a real symmetric matrix. Such a decomposition requires O(d3) arithmetic operations for a d ⇥d matrix and thus is prohibitive for high-dimensional problems. An alternative is to use first-order methods that do not require expensive decompositions, but rely only on computationally-cheap leading eigenvector computations. These methods are mostly based on the conditional gradient method, also known as the Frank-Wolfe algorithm [3, 12], which is a generic method for constrained convex optimization given an oracle for minimizing linear functions over the feasible domain. Indeed, linear minimization over the spectrahedron amounts to a single leading eigenvector computation. While the CG method has been discovered already in the 1950’s [3], it has regained much interest in recent years in the machine learning and optimization communities, in particular due to its applications to semidefinite optimization and convex optimization with a nuclear norm constraint / regularization1, e.g., [10, 13, 17, 19, 22, 2, 11]. This regained interest is not surprising: while a full eigen-decomposition for d ⇥d matrix requires O(d3) arithmetic operations, leading eigenvecor computations can be carried out, roughly speaking, in worst-case time that is only linear in the number of non-zeros in the input matrix multiplied by either ✏−1 for the popular Power Method or by ✏−1/2 for the more efficient Lanczos method, where ✏is the target accuracy. These running times improve exponentially to only depend on log(1/✏) when the eigenvalues of the input matrix are well distributed [14]. Indeed, in several important machine learning applications, such as matrix completion, the CG method requires eigenvector computations of very sparse matrices [13]. Also, very recently, new eigenvector algorithms with significantly improved performance guarantees were introduced which are applicable for matrices with certain popular structure [5, 8, 20]. The main drawback of the CG method is that its convergence rate is, in general, inferior compared to projection-based gradient methods. The convergence rate for minimizing a smooth function, roughly speaking, scales only like 1/t. In particular, this rate does not improve even when the function is also strongly convex. On the other hand, the convergence rate of optimal projection-based methods, such as Nesterov’s accelerated gradient method, scales like 1/t2 for smooth functions, and can be improved exponentially to exp(−⇥(t)) when the objective is also strongly convex. Very recently, several successful attempts were made to devise natural modifications of the CG method that retain the overall low per-iteration complexity, while enjoying provably faster convergence rates, usually under a strong-convexity assumption, or a slightly weaker one. These results exhibit provablyfaster rates for optimization over polyhedral sets [7, 15] and strongly-convex sets [6], but do not apply to the spectrahedron. For the specific setting considered in this work, several heuristic improvements of the CG method were suggested which show promising empirical evidence, however, non of them provably improve over the rate of the standard CG method [19, 17, 4]. In this work we present a new non-trivial variant of the CG method, which, to the best of our knowledge, is the first to exhibit provably faster convergence rates for optimization over the spectrahedron, under standard smoothness and strong convexity assumptions. The per-iteration complexity of the method is essentially identical to that of the standard CG method, i.e., only a single leading eigenvector computation per iteration is required. Our method is tailored for optimization over the spectrahedron, and can be seen as a certain hybridization of the standard CG method and the projected gradient method. From a high-level view, we take advantage of the fact that solving a `2-regularized linear problem over the set of extreme points of the spectrahedron is equivalent to linear optimization over this set, i.e., amounts to a single eigenvector computation. We then show via a novel and non-trivial analysis, that includes new decomposition concepts for positive semidefinite matrices, that such an algorithmically-cheap regularization is sufficient, in presence of strong convexity, to derive faster convergence rates. 2 Preliminaries and Notation For vectors we let k · k denote the standard Euclidean norm, while for matrices we let k · k denote the spectral norm, k·kF denote the Frobenius norm, and k · k⇤denote the nuclear norm. We denote by Sd the space of d ⇥d real symmetric matrices, and by Sd the spectrahedron in Sd, i.e., Sd := {X 2 Sd | X ⌫0, Tr(X) = 1}. We let Tr(·) and rank(·) denote the trace and rank of a given matrix in Sd, respectively. We let • denote the standard inner-product for matrices. Given a matrix X 2 Sd, we let λmin(X) denote the smallest non-zero eigenvalue of X. 1minimizing a convex function subject to a nuclear norm constraint is efficiently reducible to the minimization of the function over the spectrahedron, as fully detailed in [13]. 2 Given a matrix A 2 Sd, we denote by EV(A) an eigenvector of A that corresponds to the largest (signed) eigenvalue of A, i.e., EV(A) 2 arg maxv:kvk=1 v>Av. Given a scalar ⇠> 0, we also denote by EV⇠(A) an ⇠-approximation to the largest (in terms of eigenvalue) eigenvector of A, i.e., EV⇠(A) returns a unit vector v such that v>Av ≥λmax(A) −⇠. Definition 1. We say that a function f(X) : Rm⇥n ! R is ↵-strongly convex w.r.t. a norm k · k, if for all X, Y 2 Rm⇥n it holds that f(Y) ≥f(X) + (Y −X) • rf(X) + ↵ 2 kX −Yk2. Definition 2. We say that a function f(X) : Rm⇥n ! R is β-smooth w.r.t. a norm k · k, if for all X, Y 2 Rm⇥n it holds that f(Y) f(X) + (Y −X) • rf(X) + β 2 kX −Yk2. The first-order optimality condition implies that for a ↵-strongly convex f, if X⇤is the unique minimizer of f over a convex set K ⇢Rm⇥n, then for all X 2 K it holds that f(X) −f(X⇤) ≥↵ 2 kX −X⇤k2. (1) 2.1 Problem setting The main focus of this work is the following optimization problem: min X2Sd f(X), (2) where we assume that f(X) is both ↵-strongly convex and β-smooth w.r.t. k · kF . We denote the (unique) minimizer of f over Sd by X⇤. 3 Our Approach We begin by briefly describing the conditional gradient and projected-gradient methods, pointing out their advantages and short-comings for solving Problem (2) in Subsection 3.1. We then present our new method which is a certain combination of ideas from both methods in Subsection 3.2. 3.1 Conditional gradient and projected gradient descent The standard conditional gradient algorithm is detailed below in Algorithm 1. Algorithm 1 Conditional Gradient 1: input: sequence of step-sizes {⌘t}t≥1 ⇢[0, 1] 2: let X1 be an arbitrary matrix in Sd 3: for t = 1... do 4: vt EV (−rf(Xt)) 5: Xt+1 Xt + ⌘t(vtv> t −Xt) 6: end for Let us denote the approximation error of Algorithm 1 after t iterations by ht := f(Xt) −f(X⇤). The convergence result of Algorithm 1 is based on the following simple observations: ht+1 = f(Xt + ⌘t(vtv> t −Xt)) −f(X⇤) (3) ht + ⌘t(vtv> t −Xt) • rf(Xt) + ⌘2 t β 2 kvtv> t −Xtk2 F ht + ⌘t(X⇤−Xt) • rf(Xt) + ⌘2 t β 2 kvtv> t −Xtk2 F (1 −⌘t)ht + ⌘2 t β 2 kvtv> t −Xtk2 F , where the first inequality follows from the β-smoothness of f(X), the second one follows for the optimal choice of vt, and the third one follows from convexity of f(X). Unfortunately, while we 3 expect the error ht to rapidly converge to zero, the term kvtv> t −Xtk2 F in Eq. (3), in principal, might remain as large as the diameter of Sd, which, given a proper choice of step-size ⌘t, results in the well-known convergence rate of O(β/t) [12, 10]. This consequence holds also in case f(X) is not only smooth, but also strongly-convex. However, in case f is strongly convex, a non-trivial modification of Algorithm 1 can lead to a much faster convergence rate. In this case, it follows from Eq. (1), that on any iteration t, kXt −X⇤k2 F 2 ↵ht. Thus, if we consider replacing the choice of Xt+1 in Algorithm 1 with the following update rule: Vt arg min V2Sd V • rf(Xt) + ⌘tβ 2 kV −Xtk2 F , Xt+1 Xt + ⌘t(Vt −Xt), (4) then, following basically the same steps as in Eq. (3), we will have that ht+1 ht + ⌘t(X⇤−Xt) • rf(Xt) + ⌘2 t β 2 kX⇤−Xtk2 F ✓ 1 −⌘t + ⌘2 t β ↵ ◆ ht, (5) and thus by a proper choice of ⌘t, a linear convergence rate will be attained. Of course the issue now, is that computing Vt is no longer a computationally-cheap leading eigenvalue problem (in particular Vt is not rank-one), but requires a full eigen-decomposition of Xt, which is much more expensive. In fact, the update rule in Eq. (4) is nothing more than the projected gradient decent method. 3.2 A new hybrid approach: rank one-regularized conditional gradient algorithm At the heart of our new method is the combination of ideas from both of the above approaches: on one hand, solving a certain regularized linear problem in order to avoid the shortcomings of the CG method, i.e., slow convergence rate, and on the other hand, maintaining the simple structure of a leading eigenvalue computation that avoids the shortcoming of the computationally-expensive projected-gradient method. Towards this end, suppose that we have an explicit decomposition of the current iterate Xt = Pk i=1 aixix> i , where (a1, a2, ..., ak) is a probability distribution over [k], and each xi is a unit vector. Note in particular that the standard CG method (Algorithm 1) naturally produces such an explicit decomposition of Xt (provided X1 is chosen to be rank-one). Consider now the update rule in Eq. (4), but with the additional restriction that Vt is rank one, i.e, Vt arg minV2Sd, rank(V)=1V • rf(Xt) + ⌘tβ 2 kV −Xtk2 F . Note that in this case it follows that Vt is a unit trace rank-one matrix which corresponds to the leading eigenvector of the matrix −rf(Xt) + ⌘tβXt. However, when Vt is rank-one, the regularization kVt −Xtk2 F makes little sense in general, since unless X⇤is rank-one, we do not expect Xt to be such (note however, that if X⇤is rank one, this modification will already result in a linear convergence rate). However, we can think of solving a set of decoupled component-wise regularized problems: 8i 2 [k] : v(i) t arg min kvk=1 v>rf(Xt)v + ⌘tβ 2 kvv> −xix> i k2 F ⌘EV + −rf(Xt) + ⌘tβxix> i , Xt+1 Pk i=1 ai ⇣ (1 −⌘t)xix> i + ⌘tv(i) t v(i)> t ⌘ , (6) where the equivalence in the first line follows since kvv>kF = 1, and thus the minimizer of the LHS is w.l.o.g. a leading eigenvector of the matrix on the RHS. Following the lines of Eq. (3), we will now have that ht+1 ht + ⌘t k X i=1 ai(v(i) t v(i)> t −xix> i ) • rf(Xt) + ⌘2 t β 2 k k X i=1 ai(v(i) t v(i)> t −xix> i )k2 F ht + ⌘t k X i=1 ai(v(i) t v(i)> t −xix> i ) • rf(Xt) + ⌘2 t β 2 k X i=1 aikv(i) t v(i)> t −xix> i k2 F = ht + ⌘tEi⇠(a1,...,ak) (v(i) t v(i)> t −xix> i ) • rf(Xt) + ⌘tβ 2 kv(i) t v(i)> t −xix> i k2 F 1 , (7) 4 where the second inequality follows from convexity of the squared Frobenius norm, and the last equality follows since (a1, ..., ak) is a probability distribution over [k]. While the approach in Eq. (6) relies only on leading eigenvector computations, the benefit in terms of potential convergence rates is not trivial, since it is not immediate that we can get non-trivial bounds for the individual distances kv(i) t v(i)> t −xix> i kF . Indeed, the main novelty in our analysis is dedicated precisely to this issue. A motivation, if any, is that there might exists a decomposition of X⇤as X⇤= Pk i=1 bix⇤(i)x⇤(i)>, which is close in some sense to the decomposition of Xt. We can then think of the regularized problem in Eq. (6), as an attempt to push each individual component x(i) towards its corresponding component in the decomposition of X⇤, and as an overall result, bring the following iterate Xt+1 closer to X⇤. Note that Eq. (7) implicitly describes a randomized algorithm in which, instead of solving a regularized EV problem for each rank-one matrix in the decomposition of Xt, which is expensive as this decomposition grows large with the number of iterations, we pick a single rank-one component according to its weight in the decomposition, and only update it. This directly brings us to our proposed algorithm, Algorithm 2, which is given below. Algorithm 2 Randomized Rank one-regularized Conditional Gradient 1: input: sequence of step-sizes {⌘t}t≥1, sequence of error tolerances {⇠t}t≥0 2: let x0 be an arbitrary unit vector 3: X1 x1x> 1 such that x1 EV⇠0(−rf(x0x> 0 )) 4: for t = 1... do 5: suppose Xt is given by Xt = Pk i=1 aixix> i , where each xi is a unit vector, and (a1, a2, ..., ak) is a probability distribution over [k], for some integer k 6: pick it 2 [k] according to the probability distribution (a1, a2, ...ak) 7: set a new step-size ˜⌘t as follows: ˜⌘t ⇢ ⌘t/2 if ait ≥⌘t ait else 8: vt EV⇠t + −rf(Xt) + ⌘tβxitx> it , 9: Xt+1 Xt + ˜⌘t(vtv> t −xitx> it) 10: end for We have the following guarantee for Algorithm 2 which is the main result of this paper. Theorem 1. [Main Theorem] Consider the sequence of step-sizes {⌘t}t≥1 defined by ⌘t = 18/(t + 8), and suppose that ⇠0 = β and for any iteration t ≥1 it holds that ⇠t = O min{ β t , ✓ βp rank(X⇤) ↵1/4t ◆4/3 , ⇣ β p↵λmin(X⇤)t ⌘2 } ! . Then, all iterates are feasible, and 8t ≥1 : E [f(Xt) −f(X⇤)] = O 0 @min{β t , β p rank(X⇤) ↵1/4t !4/3 , ✓ β p↵λmin(X⇤)t ◆2 } 1 A . It is important to note that the step-size choice in Theorem 1 does not require any knowledge on the parameters ↵, β, rank(X⇤), and λmin(X⇤). The knowledge of β is required however for the EV computations. While it follows from Theorem 1 that the knowledge of ↵, rank(X⇤), λmin(X⇤) is needed to set the accuracy parameters - ⇠t, in practice, iterative eigenvector methods are very efficient and are much less sensitive to exact knowledge of parameters than the choice of step-size for instance. While the eigenvalue problem in Algorithm 2 is different from the one in Algorithm 1, due to the additional term in xitx> it, the efficiency of solving both problems is essentially the same since efficient EV procedures are based on iteratively multiplying the input matrix with a vector. In particular, multiplying a vector with a rank-one matrix takes O(d) time. Thus, as long as nnz(rf(Xt)) = ⌦(d), which is highly reasonable, both EV computations run in essentially the same time. Finally, note also that aside from the computation of the gradient direction and the leading eigenvector computation, all other operations on any iteration t, can be carried out in O(d2 + t) additional time. 5 4 Analysis The complete proof of Theorem 1 and all supporting lemmas are given in full detail in the appendix. Here we only detail the two main ingredients in the analysis of Algorithm 2. Throughout this section, given a matrix Y 2 Sd, we let PY,⌧2 Sd denote the projection matrix onto all eigenvectors of Y that correspond to eigenvalues of magnitude at least ⌧. Similarly, we let P? Y,⌧ denote the projection matrix onto the eigenvectors of Y that correspond to eigenvalues of magnitude smaller than ⌧(including eigenvectors that correspond to zero-valued eigenvalues). 4.1 A new decomposition for positive semidefinite matrices with locality properties The analysis of Algorithm 2 relies heavily on a new decomposition idea of matrices in Sd that suggests that given a matrix X in the form of a convex combination of rank-one matrices: X = Pk i=1 ↵ixix> i , and another matrix Y 2 Sd, roughly speaking, we can decompose Y as the sum of rank-one matrices, such that the components in the decomposition of Y are close to those in the decomposition of X in terms of the overall distance kX −YkF . This decomposition and corresponding property justifies the idea of solving rank-one regularized problems, as suggested in Eq. (6), and applied in Algorithm 2. Lemma 1. Let X, Y 2 Sd such that X is given as X = Pk i=1 aixix> i , where each xi is a unit vector, and (a1, ..., ak) is a distribution over [k], and let ⌧, γ 2 [0, 1] be scalars that satisfy γ⌧ 1−γ ≥kX −YkF . Then, Y can be written as Y = Pk i=1 biyiy> i + Pk j=1(aj −bj)W, such that 1. each yi is a unit vector and W 2 Sd 2. 8i 2 [k] : 0 bi ai and Pk j=1(aj −bj) p rank(Y) + kYP? Y,⌧kF + kX −YkF , + γ 3. Pk i=1 bikxix> i −yiy> i k2 F 2 p rank(Y) + kYP? Y,⌧kF + kX −YkF , 4.2 Bounding the per-iteration improvement The main step in the proof of Theorem 1, is understanding the per-iteration improvement, as captured in Eq. (7), achievable by applying the update rule in Eq. (6), which updates on each iteration all of the rank-one components in the decomposition of the current iterate. Lemma 2. [full deterministic update] Fix a scalar ⌘> 0. Let X 2 Sd such that X = Pk i=1 aixix> i , where each xi is a unit vector, and (a1, ..., ak) is a probability distribution over [k]. For any i 2 [k], let vi := EV + −rf(X) + ⌘βxix> i , . Then, it holds that k X i=1 ai (viv> i −xix> i ) • rf(X) + ⌘β 2 kviv> i −xix> i k2 F 1 −(f(X) −f(X⇤)) +⌘β · min{1, 5 sr 2 ↵rank(X⇤) p f(X) −f(X⇤), 3 p 2 p↵λmin(X⇤) p f(X) −f(X⇤)}. proof sketch. The proof is divided to three parts, each corresponding to a different term in the min expression in the bound in the Lemma. The first bound, at a high-level, follows from the standard conditional gradient analysis (see Eq. (3)). We continue to derive the second and third bounds. From Lemma 1 we know we can write X⇤in the following way: X⇤= k X i=1 b⇤ i y⇤ i y⇤> i + k X j=1 (aj −b⇤ j)W⇤, (8) where for all i 2 [k], b⇤ i 2 [0, ai] and y⇤ i is a unit vector, and W⇤2 Sd. 6 Using nothing more than Eq. (8), the optimality of vi for each i 2 [k], and the bounds in Lemma 1, it can be shown that k X i=1 ai (viv> i −xix> i ) • rf(X) + ⌘β 2 kviv> i −xix> i k2 F 1 (X⇤−X) • rf(X) + ⌘β 2 k X i=1 b⇤ i ky⇤ i y⇤> i −xix> i k2 F + ⌘β k X i=1 (ai −b⇤ i ) (X⇤−X) • rf(X) + ⌘β ⇣ 2 p rank(X⇤) + kX⇤P? X⇤,⌧kF + kX −X⇤kF , + γ ⌘ . (9) Now we can optimize the above bound in terms of ⌧, γ. One option is to upper bound kX⇤P? X⇤,⌧kF p rank(X⇤)⌧, which together with the choice ⌧1 = q kX−X⇤kF 2rank(X⇤) , γ1 = p 2rank(X⇤)kX −X⇤kF , give us: RHS of (9) (X⇤−X) • rf(X) + 5⌘β p rank(X⇤)kX −X⇤kF . (10) Another option, is to choose ⌧2 = λmin(X⇤), γ2 = kX−X⇤kF λmin(X⇤) which gives us kX⇤P? X⇤,⌧kF = 0. This results in the bound: RHS of (9) (X⇤−X) • rf(X) + 3⌘βkX −X⇤kF λmin(X⇤) . (11) Now, using the convexity of f to upper bound (X⇤−X) • rf(X) −(f(X) −f(X⇤)) and Eq. (1) in both Eq. (10) and (11), gives the second the third parts of the bound in the lemma. 5 Preliminary Empirical Evaluation We evaluate our method, along with other conditional gradient variants, on the task of matrix completion [13]. Setting The underlying optimization problem for the matrix completion task is the following: min Z2N Bd1,d2(✓){f(Z) := 1 2 n X l=1 (Z • Eil,jl −rl)2}, (12) where Ei,j is the indicator matrix for the entry (i, j) in Rd1⇥d2, {(il, jl, rl)}n l=1 ⇢[d1] ⇥[d2] ⇥R, and NBd1,d2(✓) denotes the nuclear-norm ball of radius ✓in Rd1⇥d2, i.e., NBd1,d2(✓) := {Z 2 Rd1⇥d2 | kZk⇤:= min{d1,d2} X i=1 σi(Z) ✓}, where we let σ(Z) denote the vector of singular values of Z. . That is, our goal is to find a matrix with bounded nuclear norm (which serves as a convex surrogate for bounded rank) which matches best the partial observations given by {(il, jl, rl)}n l=1. In order to transform Problem (12) to optimization over the spectrahedron, we use the reduction specified in full detail in [13], and also described in Section A in the appendix. The objective function in Eq. (12) is known to have a smoothness parameter β with respect to k · kF , which satisfies β = O(1), see for instance [13]. While the objective function in Eq. (12) is not strongly convex, it is known that under certain conditions, the matrix completion problem exhibit properties very similar to strong convexity, in the sense of Eq. (1) (which is indeed the only consequence of strong convexity that we use in our analysis) [18]. 7 60 80 100 120 140 160 180 200 220 #iterations 0.5 1 1.5 2 2.5 3 3.5 error ×104 CG Away-CG ROR-CG 60 80 100 120 140 160 180 200 220 240 #iterations 0.6 0.8 1 1.2 1.4 1.6 1.8 2 2.2 error ×105 CG Away-CG ROR-CG Figure 1: Comparison between conditional gradient variants for solving the matrix completion problem on the MOVIELENS100K (left) and MOVIELENS1M (right) datasets. Two modifications of Algorithm 2 We implemented our rank one-regularized conditional gradient variant, Algorithm 2 (denoted ROR-CG in our figures) with two modifications. First, on each iteration t, instead of picking an index it of a rank-one matrix in the decomposition of the current iterate at random according to the distribution (a1, a2, ..., ak), we choose it in a greedy way, i.e., we choose the rank-one component that has the largest product with the current gradient direction. While this approach is computationally more expensive, it could be easily parallelized since all dot-product computations are independent of each other. Second, after computing the eigenvector vt using the step-size ⌘t = 1/t (which is very close to that prescribed in Theorem 1), we apply a line-search, as detailed in [13], in order to the determine the optimal step-size given the direction vtv> t −xitx> it. Baselines As baselines for comparison we used the standard conditional gradient method with exact line-search for setting the step-size (denoted CG in our figures)[13], and the conditional gradient with away-steps variant, recently studied in [15] (denoted Away-CG in our figures). While the away-steps variant was studied in the context of optimization over polyhedral sets, and its formal improved guarantees apply only in that setting, the concept of away-steps still makes sense for any convex feasible set. This variant also allows the incorporation of an exact line-search procedure to choose the optimal step-size. Datasets We have experimented with two well known datasets for the matrix completion task: the MOVIELENS100K dataset for which d1 = 943, d2 = 1682, n = 105, and the MOVIELENS1M dataset for which d1 = 6040, d2 = 3952, n ⇡106. The MOVIELENS1M dataset was further sub-sampled to contain roughly half of the observations. We have set the parameter ✓in Problem (12) to ✓= 10000 for the ML100K dataset, and ✓= 35000 for the ML1M dataset. Figure 1 presents the objective (12) vs. the number of iterations executed. Each graph is the average over 5 independent experiments 2. It can be seen that our approach indeed improves significantly over the baselines in terms of convergence rate, for the setting under consideration. References [1] Emmanuel J Candès and Benjamin Recht. Exact matrix completion via convex optimization. Foundations of Computational mathematics, 9(6):717–772, 2009. [2] Miroslav Dudík, Zaïd Harchaoui, and Jérôme Malick. Lifted coordinate descent for learning with tracenorm regularization. Journal of Machine Learning Research - Proceedings Track, 22:327–336, 2012. [3] M. Frank and P. Wolfe. An algorithm for quadratic programming. Naval Research Logistics Quarterly, 3:149–154, 1956. [4] Robert M Freund, Paul Grigas, and Rahul Mazumder. An extended frank-wolfe method with" in-face" directions, and its application to low-rank matrix completion. arXiv preprint arXiv:1511.02204, 2015. 2We ran several experiments since the leading eigenvector computation in each one of the CG variants is randomized. 8 [5] Dan Garber and Elad Hazan. Fast and simple pca via convex optimization. arXiv preprint arXiv:1509.05647, 2015. [6] Dan Garber and Elad Hazan. Faster rates for the frank-wolfe method over strongly-convex sets. In Proceedings of the 32nd International Conference on Machine Learning,ICML, pages 541–549, 2015. [7] Dan Garber and Elad Hazan. A linearly convergent variant of the conditional gradient algorithm under strong convexity, with applications to online and stochastic optimization. SIAM Journal on Optimization, 26(3):1493–1528, 2016. [8] Dan Garber, Elad Hazan, Chi Jin, Sham M. Kakade, Cameron Musco, Praneeth Netrapalli, and Aaron Sidford. Faster eigenvector computation via shift-and-invert preconditioning. In Proceedings of the 33nd International Conference on Machine Learning, ICML 2016, New York City, NY, USA, pages 2626–2634, 2016. [9] Mehmet Gönen and Ethem Alpaydın. Multiple kernel learning algorithms. The Journal of Machine Learning Research, 12:2211–2268, 2011. [10] Elad Hazan. Sparse approximate solutions to semidefinite programs. In 8th Latin American Theoretical Informatics Symposium, LATIN, 2008. [11] Elad Hazan and Satyen Kale. Projection-free online learning. In Proceedings of the 29th International Conference on Machine Learning, ICML, 2012. [12] Martin Jaggi. Revisiting frank-wolfe: Projection-free sparse convex optimization. In Proceedings of the 30th International Conference on Machine Learning, ICML, 2013. [13] Martin Jaggi and Marek Sulovský. A simple algorithm for nuclear norm regularized problems. In Proceedings of the 27th International Conference on Machine Learning, ICML, 2010. [14] J. Kuczy´nski and H. Wo´zniakowski. Estimating the largest eigenvalues by the power and lanczos algorithms with a random start. SIAM J. Matrix Anal. Appl., 13:1094–1122, October 1992. [15] Simon Lacoste-Julien and Martin Jaggi. On the global linear convergence of Frank-Wolfe optimization variants. In Advances in Neural Information Processing Systems, pages 496–504, 2015. [16] Gert RG Lanckriet, Nello Cristianini, Peter Bartlett, Laurent El Ghaoui, and Michael I Jordan. Learning the kernel matrix with semidefinite programming. The Journal of Machine Learning Research, 5:27–72, 2004. [17] Sören Laue. A hybrid algorithm for convex semidefinite optimization. In Proceedings of the 29th International Conference on Machine Learning, ICML, 2012. [18] Sahand Negahban, Bin Yu, Martin J Wainwright, and Pradeep K. Ravikumar. A unified framework for high-dimensional analysis of m-estimators with decomposable regularizers. In Y. Bengio, D. Schuurmans, J. D. Lafferty, C. K. I. Williams, and A. Culotta, editors, Advances in Neural Information Processing Systems 22, pages 1348–1356. 2009. [19] Shai Shalev-Shwartz, Alon Gonen, and Ohad Shamir. Large-scale convex minimization with a low-rank constraint. In Proceedings of the 28th International Conference on Machine Learning, ICML, 2011. [20] Ohad Shamir. A stochastic PCA and SVD algorithm with an exponential convergence rate. In Proceedings of the 32nd International Conference on Machine Learning, ICML, 2015. [21] Eric P Xing, Andrew Y Ng, Michael I Jordan, and Stuart Russell. Distance metric learning with application to clustering with side-information. Advances in neural information processing systems, 15:505–512, 2003. [22] Yiming Ying and Peng Li. Distance metric learning with eigenvalue optimization. J. Mach. Learn. Res., 13(1):1–26, January 2012. [23] Xinhua Zhang, Dale Schuurmans, and Yao-liang Yu. Accelerated training for matrix-norm regularization: A boosting approach. In Advances in Neural Information Processing Systems, pages 2906–2914, 2012. 9 | 2016 | 505 |
6,445 | Improved Regret Bounds for Oracle-Based Adversarial Contextual Bandits Vasilis Syrgkanis Microsoft Research vasy@microsoft.com Haipeng Luo Microsoft Research haipeng@microsoft.com Akshay Krishnamurthy University of Massachusetts, Amherst akshay@cs.umass.edu Robert E. Schapire Microsoft Research schapire@microsoft.com Abstract We propose a new oracle-based algorithm, BISTRO+, for the adversarial contextual bandit problem, where either contexts are drawn i.i.d. or the sequence of contexts is known a priori, but where the losses are picked adversarially. Our algorithm is computationally efficient, assuming access to an offline optimization oracle, and enjoys a regret of order O((KT) 2 3 (log N) 1 3 ), where K is the number of actions, T is the number of iterations, and N is the number of baseline policies. Our result is the first to break the O(T 3 4 ) barrier achieved by recent algorithms, which was left as a major open problem. Our analysis employs the recent relaxation framework of Rakhlin and Sridharan [7]. 1 Introduction We study online decision making problems where a learner chooses an action based on some side information (context) and incurs some cost for that action with a goal of incurring minimal cost over a sequence of rounds. These contextual online learning settings form a powerful framework for modeling many important decision-making scenarios with applications ranging from personalized health care to content recommendation and targeted advertising. Many of these applications also involve a partial feedback component, wherein costs for alternative actions are unobserved, and are typically modeled as contextual bandits. The contextual information present in these problems enables learning of a much richer policy for choosing actions based on context. In the literature, the typical goal for the learner is to have cumulative cost that is not much higher than the best policy π in a large policy class Π. This is formalized by the notion of regret, which is the learner’s cumulative cost minus the cumulative cost of the best fixed policy π in hindsight. Naively, one can view the contextual problem as a standard online learning problem where the set of possible “actions” available at each iteration is the set of policies. This perspective is fruitful, as classical algorithms, such as Hedge [5, 3] and Exp4 [2], give information theoretically optimal regret bounds of O( p T log(N)) in full-information and O( p TK log(N) in the bandit setting, where T is the number of rounds, K is the number of actions, and N is number of policies. However, naively lifting standard online learning algorithms to the contextual setting leads to a running time that is linear in the number of policies. Given that the optimal regret is only logarithmic in N and that our high-level goal is to learn a very rich policy, we want to capture policy classes that are exponentially large. When we use a large policy class, existing algorithms are no longer computationally tractable. 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. To study this computational question, a number of recent papers have developed oracle-based algorithms that only access the policy class through an optimization oracle for the offline fullinformation problem. Oracle-based approaches harness the research in supervised learning that focuses on designing efficient algorithms for full-information problems and uses it for online and partial-feedback problems. Optimization oracles have been used in designing contextual bandit algorithms [1, 4] that achieve the optimal O( p KT log(N)) regret while also being computationally efficient (i.e. requiring poly(K, log(N), T) oracle calls and computation). However, these results only apply when the contexts and costs are independently and identically distributed at each iteration, contrasting with the computationally inefficient approaches that can handle adversarial inputs. Two very recent works provide the first oracle efficient algorithms for the contextual bandit problem in adversarial settings [7, 8]. Rakhlin and Sridharan [7] considers a setting where the contexts are drawn i.i.d. from a known distribution with adversarial costs and they provide an oracle efficient algorithm called BISTRO with O(T 3 4 K 1 2 (log(N)) 1 4 ) regret. Their algorithm also applies in the transductive setting where the sequence of contexts is known a priori. Srygkanis et. al [8] also obtain a T 3 4 -style bound with a different oracle-efficient algorithm, but in a setting where the learner knows only the set of contexts that will arrive. Both of these results achieve very suboptimal regret bounds, as the dependence on the number of iterations is far from the optimal O( √ T)-bound. A major open question posed by both works is whether the O(T 3 4 ) barrier can be broken. In this paper, we provide an oracle-based contextual bandit algorithm, BISTRO+, that achieves regret O((KT) 2 3 (log(N)) 1 3 ) in both the i.i.d. context and the transductive settings considered by Rakhlin and Sridharan [7]. This bound matches the T-dependence of the epoch-greedy algorithm of Langford and Zhang [6] that only applies to the fully stochastic setting. As in Rakhlin and Sridharan [7], our algorithm only requires access to a value oracle, which is weaker than the standard argmax oracle, and it makes K + 1 oracle calls per iteration. To our knowledge, this is the best regret bound achievable by an oracle-efficient algorithm for any adversarial contextual bandit problem. Our algorithm and regret bound are based on a novel and improved analysis of the minimax problem that arises in the relaxation-based framework of Rakhlin and Sridharan [7] (hence the name BISTRO+). Our proof requires analyzing the value of a sequential game where the learner chooses a distribution over actions and then the adversary chooses a distribution over costs in some bounded finite domain, with - importantly - a bounded variance. This is unlike the simpler minimax problem analyzed in [7], where the adversary is only constrained by the range of the costs. Apart from showing that this more structured minimax problem has a small value, we also need to derive an oracle-based strategy for the learner that achieves the improved regret bound. The additional constraints on the game require a much more intricate argument to derive this strategy which is an algorithm for solving a structured two-player minimax game (see Section 4). 2 Model and Preliminaries Basic notation. Throughout the paper we denote with x1:t a sequence of quantities {x1, . . . , xt} and with (x, y, z)1:t a sequence of tuples {(x1, y1, z1), . . .}. ∅denotes an empty sequence. The vector of ones is denoted by 1 and the vector of zeroes is denoted by 0. Denote with [K] the set {1, . . . , K}, e1, . . . , eK the standard basis vectors in RK, and ∆U the set of distributions over a set U. We also use ∆K as a shorthand for ∆[K]. Contextual online learning. We consider the following version of the contextual online learning problem. On each round t = 1, . . . , T, the learner observes a context xt and then chooses a probability distribution qt over a set of K actions. The adversary then chooses a cost vector ct ∈[0, 1]K. The learner picks an action ˆyt drawn from distribution qt, incurs a cost ct(ˆyt) and observes only ct(ˆyt) and not the cost of the other actions. Throughout the paper we will assume that the context xt at each iteration t is drawn i.i.d. from a distribution D. This is referred to as the hybrid i.i.d.-adversarial setting [7]. As in prior work [7], we assume that the learner can sample contexts from this distribution as needed. It is easy to adapt the arguments in the paper to apply for the transductive setting where the learner knows the sequence of contexts that will arrive. The cost vectors ct are chosen by a non-adaptive adversary. 2 The goal of the learner is to compete with a set of policies Π of size N, where each policy π ∈Π is a function mapping contexts to actions. The cumulative expected regret with respect to the best fixed policy in hindsight is REG = T X t=1 ⟨qt, ct⟩−min π∈Π T X t=1 ct(π(xt)). Optimization value oracle. We will assume that we are given access to an optimization oracle that when given as input a sequence of contexts and cost vectors (x, c)1:t, it outputs the cumulative cost of the best fixed policy, which is min π∈Π t X τ=1 ct(π(xt)). (1) This can be viewed as an offline batch optimization or ERM oracle. 2.1 Relaxation based algorithms We briefly review the relaxation based framework proposed in [7]. The reader is directed to [7] for a more extensive exposition. We will also slightly augment the framework with some internal randomness that the algorithm can generate and use, which does not affect the cost of the algorithm. A crucial concept in the relaxation based framework is the information obtained by the learner at the end of each round t ∈[T], which is the following tuple: It(xt, qt, ˆyt, ct, St) = (xt, qt, ˆyt, ct(ˆyt), St), where ˆyt is the realized chosen action drawn from the distribution qt and St is some random string drawn from some distribution that can depend on qt, ˆyt and ct(ˆyt) and which can be used by the algorithm in subsequent rounds. Definition 1 A partial-information relaxation REL(·) is a function that maps (I1, . . . , It) to a real value for any t ∈[T]. A partial-information relaxation is admissible if for any t ∈[T], and for all I1, . . . , It−1 Ext min qt max ct Eˆyt∼qt,St [ct(ˆyt) + REL(I1:t−1, It(xt, qt, ˆyt, ct, St))] ≤REL(I1:t−1), (2) and for all x1:T , c1:T and q1:T Eˆy1:T ∼q1:T ,S1:T [REL(I1:T )] ≥−min π∈Π T X t=1 ct(π(xt)). (3) Definition 2 Any randomized strategy q1:T that certifies inequalities (2) and (3) is called an admissible strategy. A basic lemma proven in [7] is that if one constructs a relaxation and a corresponding admissible strategy, then the expected regret of the admissible strategy is upper bounded by the value of the relaxation at the beginning of time. Lemma 1 ([7]) Let REL be an admissible relaxation and q1:T be an admissible strategy. Then for any c1:T , we have E [REG] ≤REL(∅). We will utilize this framework and construct a novel relaxation with an admissible strategy. We will show that the value of the relaxation at the beginning of time is upper bounded by the desired improved regret bound and that the admissible strategy can be efficiently computed assuming access to an optimization value oracle. 3 3 A Faster Contextual Bandit Algorithm First we define an unbiased estimator the cost vectors ct. In addition to doing the usual importance weighting, we also discretize the estimated cost to either 0 or L for some constant L ≥K to be specified later. Specifically, suppose that at iteration t an action ˆyt is picked based on some distribution ht ∈∆K. Now, consider the random variable Xt, which is defined conditionally on ˆyt and ht, as Xt = ( 1 with probability ct(ˆyt) Lht(ˆyt), 0 with the remaining probability. (4) This is a valid random variable whenever miny ht(y) ≥1 L, which will be ensured by the algorithm. This is the only randomness in the random string St that we used in the general relaxation framework. Our construction of an unbiased estimate for each ct based on the information It collected at the end of each round is then: ˆct = LXteˆyt. Observe that for any y ∈[K], Eˆyt,Xt [ˆct(y)] = L · Pr[ˆyt = y] · Pr[Xt = 1|ˆyt = y] = L · ht(y) · ct(y) Lht(y) = ct(y). Hence, ˆct is an unbiased estimate of ct. We are now ready to define our relaxation. Let ϵt ∈{−1, 1}K be a Rademacher random vector (i.e. each coordinate is an independent Rademacher random variable, which is −1 or 1 with equal probability), and let Zt ∈{0, L} be a random variable which is L with probability K/L and 0 otherwise. We denote with ρt = (x, ϵ, Z)t+1:T and with Gt the distribution of ρt which is described above. Our relaxation is defined as follows: REL(I1:t) = Eρt∼Gt [R((x, ˆc)1:t, ρt)], (5) where R((x, ˆc)1:t, ρt) = −min π∈Π t X τ=1 ˆcτ(π(xτ)) + T X τ=t+1 2ϵτ(π(xτ))Zτ ! + (T −t)K/L. Note that REL(∅) is the following quantity, whose first part resembles a Rademacher average: REL(∅) = 2E(x,ϵ,Z)1:T " max π∈Π T X τ=1 ϵτ(π(xτ))Zτ # + TK/L. Using the following lemma (whose proof is deferred to the supplementary material) and the fact E Z2 t ≤KL, we can upper bound REL(∅) by O( p TKL log(N) + TK/L), which after tuning L will give the claimed O(T 2/3) bound. Lemma 2 Let ϵt be Rademacher random vectors, and Zt be non-negative real-valued random variables such that E Z2 t ≤M for some constant M > 0. Then EZ1:T ,ϵ1:T " max π∈Π T X t=1 ϵt(π(xt)) · Zt # ≤ p 2TM log(N). To show an admissible strategy for our relaxation, we let D = {L · ei : i ∈[K]} ∪{0}. For a distribution p ∈∆(D), we denote with p(i), for i ∈{0, . . . , K}, the probability assigned to vector ei, with the convention that e0 = 0. Also let ∆′ D = {p ∈∆D : p(i) ≤1/L, ∀i ∈[K]}. Based on this notation our admissible strategy is defined as qt = Eρt [qt(ρt)] where qt(ρt) = 1 −K L q∗ t (ρt) + 1 L1, (6) and q∗ t (ρt) = argmin q∈∆K max pt∈∆′ D Eˆct∼pt [⟨q, ˆct⟩+ R((x, ˆc)1:t, ρt)]. (7) Algorithm 1 implements this admissible strategy. Note that it suffices to use qt(ρt) for a single random draw ρt instead of qt to ensure the exact same guarantee in expectation. In Section 4 we show that qt(ρt) can be computed efficiently using an optimization value oracle. We state the main theorem of our relaxation construction and defer the proof to Section 5. 4 Algorithm 1 BISTRO+ Input: parameter L ≥K for each time step t ∈[T] do Observe xt. Draw ρt = (x, ϵ, Z)t+1:T where each xτ is drawn from the distribution of contexts, ϵτ is a Rademacher random vectors and Zτ ∈{0, L} is L with probability K/L and 0 otherwise. Compute qt(ρt) based on Eq. (6) (using Algorithm 2). Predict ˆyt ∼qt(ρt) and observe ct(ˆyt). Create an estimate ˆct = LXteˆyt, where Xt is defined in Eq. (4) using qt(ρt) as ht. end for Algorithm 2 Computing q∗ t (ρt) Input: a value optimization oracle, (x, ˆc)1:t−1, xt and ρt. Output: q ∈∆K, a solution to Eq. (7). Compute ψi as in Eq. (9) for all i = 0, . . . , K using the optimization oracle. Compute φi = ψi−ψ0 L for all i ∈[K]. Let m = 1 and q = 0. for each coordinate i ∈[K] do Set q(i) = min{(φi)+, m}. ((x)+ = max{x, 0}) Update m ←m −q(i). end for Distribute m arbitrarily on the coordinates of q if m > 0. Theorem 3 The relaxation defined in Equation (5) is admissible. An admissible randomized strategy for this relaxation is given by (6). The expected regret of BISTRO+ is upper bounded by 2 p 2TKL log(N) + TK/L, (8) for any L ≥K. Specifically, setting L = (KT/ log(N)) 1 3 when T ≥K2 log(N), the regret is of order O((KT) 2 3 (log(N)) 1 3 ). 4 Computational Efficiency In this section we will argue that if one is given access to a value optimization oracle (1), then one can run BISTRO+ efficiently. Specifically, we will show that the minimizer of Equation (7) can be computed efficiently via Algorithm 2. Lemma 4 Computing the quantity defined in equation (7) for any given ρt can be done in time O(K) and with only K + 1 accesses to a value optimization oracle. Proof: For i ∈{0, . . . , K}, let ψi = min π∈Π t−1 X τ=1 ˆcτ(π(xτ)) + Lei(π(xt)) + T X τ=t+1 2ϵτ(π(xτ))Zt ! (9) with the convention e0 = 0. Then observe that we can re-write the definition of q∗ t (ρt) as q∗ t (ρt) = argmin q∈∆K max pt∈∆′ D K X i=1 pt(i)(L · q(i) −ψi) −pt(0) · ψ0. Observe that each ψi can be computed with a single oracle access. Thus we can assume that all K + 1 ψ’s are computed efficiently and are given. We now argue how to compute the minimizer. For any q, the maximum over pt can be characterized as follows. With the notation zi = L · q(i) −ψi and z0 = −ψ0 we re-write the minimax quantity as q∗ t (ρt) = argmin q∈∆K max pt∈∆′ D K X i=1 pt(i) · zi + pt(0) · z0. 5 Observe that without the constraint that pt(i) ≤1/L for i > 0 we would put all the probability mass on the maximum of the zi. However, with the constraint the maximizer put as much probability mass as allowed on the maximum coordinate argmaxi∈{0,...,K} zi and continues to the next highest quantity. We repeat this until reaching the quantity z0, which is unconstrained. Thus we can put all the remaining probability mass on this coordinate. Let z(1), z(2), . . . , z(K) denote the ordered zi quantities for i > 0 (from largest to smallest). Moreover, let µ ∈[K] be the largest index such that z(µ) ≥z0. By the above reasoning we get that for a given q, the maximum over pt is equal to (recall that we assume L ≥K) µ X t=1 z(t) L + 1 −µ L z0 = µ X t=1 z(t) −z0 L + z0. Now since for any t > µ, z(t) < z0, we can write the latter as µ X t=1 z(t) L + 1 −µ L z0 = K X i=1 (zi −z0)+ L + z0 with the convention (x)+ = max{x, 0}. We thus further re-write the minimax expression as q∗ t (ρt) = argmin q∈∆K K X i=1 (zi −z0)+ L + z0 = argmin q∈∆K K X i=1 (zi −z0)+ L = argmin q∈∆K K X i=1 q(i) −ψi −ψ0 L + . Let φi = ψi−ψ0 L . The expression becomes: q∗ t (ρt) = argminq∈∆K PK t=1(q(i) −φi)+. This quantity is minimized as follows: consider any i ∈[K] such that φi ≤0. Then putting positive mass ξ on such a coordinate i is going to lead to a marginal increase of ξ in the objective. On the other hand if we put some mass on an index φi > 0, then that will not increase the objective until we reach the point where q(i) = φi. Thus a minimizer will distribute probability mass of min{P i:φi>0 φi, 1}, on the coordinates for which φi > 0. The remaining mass, if any, can be distributed arbitrarily. See Algorithm 2 for details. 5 Proof of Theorem 3 We verify the two conditions for admissibility. Final condition. It is clear that inequality (3) is satisfied since ˆct are unbiased estimates of ct: Eˆy1:T ,X1:T [REL(I1:T )] = Eˆy1:T ,X1:T " max π∈Π − T X τ=1 ˆcτ(π(xτ)) # ≥max π∈Π −Eˆy1:T ,X1:T " T X τ=1 ˆcτ(π(xτ)) # = max π∈Π − T X τ=1 cτ(π(xτ)). t-th Step condition. We now check that inequality (2) is also satisfied at some time step t ∈[T]. We reason conditionally on the observed context xt and show that qt defines an admissible strategy for the relaxation. For convenience let Ft denote the joint distribution of the pair (ˆyt, Xt). Observe that the marginal of Ft on the first coordinate is equal to qt. Let q∗ t = Eρt [q∗ t (ρt)]. First observe that: E(ˆyt,Xt)∼Ft [ct(ˆyt)] = Eˆyt∼qt [ct(ˆyt)] = ⟨qt, ct⟩≤⟨q∗ t , ct⟩+ 1 L⟨1, ct⟩≤E(ˆyt,Xt)∼Ft [⟨q∗ t , ˆct⟩]+K L . Hence, max ct∈[0,1]K E(ˆyt,Xt)∼Ft [ct(ˆyt) + REL(I1:t)] ≤ max ct∈[0,1]K E(ˆyt,Xt)∼Ft [⟨q∗ t , ˆct⟩+ REL(I1:t)] + K L . 6 We now work with the first term of the right hand side. max ct∈[0,1]K E(ˆyt,Xt)∼Ft [⟨q∗ t , ˆct⟩+ REL(I1:t)] = max ct∈[0,1]K E(ˆyt,Xt)∼Ft [Eρt∼Gt [⟨q∗ t (ρt), ˆct⟩+ R((x, ˆc)1:t, ρt)]] Observe that ˆct is a random variable taking values in D and such that the probability that it is equal to Ley (for y ∈{0, . . . , K}) can be upper bounded as Pr[ˆct = Ley] = Eρt∼Gt [Pr[ˆct = Ley|ρt]] = Eρt∼Gt qt(ρt)(y) ct(y) L · qt(ρt)(y) ≤1/L. Thus we can upper bound the latter quantity by the supremum over all distributions in ∆′ D, i.e., max ct∈[0,1]K E(ˆyt,Xt) [⟨q∗ t , ˆct⟩+ REL(I1:t)] ≤ max pt∈∆′ D Eˆct∼pt [Eρt∼Gt [⟨q∗ t (ρt), ˆct⟩+ R((x, ˆc)1:t, ρt)]]. Now we can continue by pushing the expectation over ρt outside of the supremum, i.e., max ct∈[0,1]K E(ˆyt,Xt) [⟨q∗ t , ˆct⟩+ REL(I1:t)] ≤Eρt∼Gt max pt∈∆′ D Eˆct∼pt [⟨q∗ t (ρt), ˆct⟩+ R((x, ˆc)1:t, ρt)] and working conditionally on ρt. Since the expression is linear in pt, the supremum is realized, and by the definition of q∗ t (ρt), the quantity inside the expectation Eρt∼Gt is equal to min q∈∆K max pt∈∆′ D Eˆct∼pt [⟨q, ˆct⟩+ R((x, ˆc)1:t, ρt)]. We can now apply the minimax theorem and upper bound the above by max pt∈∆′ D min q∈∆K Eˆct∼pt [⟨q, ˆct⟩+ R((x, ˆc)1:t, ρt)]. Since the inner objective is linear in q, we continue with max pt∈∆′ D min y Eˆct∼pt [ˆct(y) + R((x, ˆc)1:t, ρt)]. We can now expand the definition of R(·) max pt∈∆′ D min y Eˆct∼pt " ˆct(y) + max π∈Π − t X τ=1 ˆcτ(π(xτ)) + T X τ=t+1 2ϵτ(π(xτ))Zτ !# + (T −t)K/L. With the notation Aπ = −Pt−1 τ=1 ˆcτ(π(xτ)) −PT τ=t+1 2ϵτ(π(xτ))Zτ, we re-write the above as max pt∈∆′ D min y Eˆct∼pt ˆct(y) + max π∈Π(Aπ −ˆct(π(xt))) + (T −t)K/L. We now upper bound the first term. The extra term (T −t)K/L will be combined with the extra K/L that we have abandoned to give the correct term (T −(t −1))K/L needed for REL(I1:t−1). Observe that we can re-write the first term by using symmetrization as max pt∈∆′ D min y Eˆct∼pt ˆct(y) + max π∈Π(Aπ −ˆct(π(xt))) = max pt∈∆′ D Eˆct∼pt max π∈Π(Aπ + min y Eˆc′ t∼pt [ˆc′ t(y)] −ˆct(π(xt))) ≤max pt∈∆′ D Eˆct∼pt max π∈Π(Aπ + Eˆc′ t∼pt [ˆc′ t(π(xt))] −ˆct(π(xt))) ≤max pt∈∆′ D Eˆct,ˆc′ t∼pt max π∈Π(Aπ + ˆc′ t(π(xt)) −ˆct(π(xt))) = max pt∈∆′ D Eˆct,ˆc′ t∼pt,δ max π∈Π(Aπ + δ (ˆc′ t(π(xt)) −ˆct(π(xt)))) ≤max pt∈∆′ D Eˆct∼pt,δ max π∈Π(Aπ + 2δˆct(π(xt))) 7 where δ is a random variable which is −1 and 1 with equal probability. The last inequality follows by splitting the maximum into two equal parts. Conditioning on ˆct, consider the random variable Mt which is −maxy ˆct(y) or maxy ˆct(y) on the coordinates where ˆct is equal to zero and equal to ˆct on the coordinate that achieves the maximum. This is clearly an unbiased estimate of ˆct. Thus we can upper bound the last quantity by max pt∈∆′ D Eˆct∼pt,δ max π∈Π(Aπ + 2δE [Mt(π(xt))|ˆct]) ≤max pt∈∆′ D Eˆct,δ,Mt max π∈Π(Aπ + 2δMt(π(xt))) . The random vector δMt, conditioning on ˆct, is equal to −maxy ˆct(y) or maxy ˆct(y) with equal probability independently on each coordinate. Moreover, observe that for any distribution pt ∈∆′ D, the distribution of the maximum coordinate of ˆct has support on {0, L} and is equal to L with probability at most K/L. Since the objective only depends on the distribution of the maximum coordinate of ˆct, we can continue the upper bound with a maximum over any distribution of random vectors whose coordinates are 0 with probability at least 1 −K/L and otherwise are −L or L with equal probability. Specifically, let ϵt be a Rademacher random vector, we continue with max Zt∈∆{0,L}:P r[Zt=L]≤K/L Eϵt,Zt max π∈Π(Aπ + 2ϵt(π(xt))Zt) . Now observe that if we denote with a = Pr[Zt = L], the above is equal to max a:0≤a≤K/L (1 −a) max π∈Π(Aπ) + aEϵt max π∈Π(Aπ + 2ϵt(π(xt))L) . We now argue that this maximum is achieved by setting a = K/L. For that it suffices to show that max π∈Π(Aπ) ≤Eϵt max π∈Π(Aπ + 2ϵt(π(xt))L) , which is true by observing that with π∗= argmaxπ∈Π(Aπ) one has Eϵt max π∈Π(Aπ + 2ϵt(π(xt))L) ≥Eϵt [Aπ∗+ 2ϵt(π∗(xt))L)] = Aπ∗+Eϵt [2ϵt(π∗(xt))L)] = Aπ∗. Thus we can upper bound the quantity we want by Eϵt,Zt max π∈Π(Aπ + 2ϵt(π(xt))Zt , where ϵt is a Rademacher random vector and Zt is now a random variable which is equal to L with probability K/L and is equal to 0 with the remaining probability. Taking expectation over ρt and xt and adding the (T −(t −1))K/L term that we abandoned, we arrive at the desired upper bound of REL(I1:t−1). This concludes the proof of admissibility. Regret bound. By applying Lemma 2 (See Appendix A) with E[Z2 t ] = L2 Pr[Zt = L] = KL and invoking Lemma 1, we get the regret bound in Equation (8). 6 Discussion In this paper, we present a new oracle-based algorithm for adversarial contextual bandits and we prove that it achieves O((KT)2/3 log(N)1/3) regret in the settings studied by Rakhlin and Sridharan [7]. This is the best regret bound that we are aware of among oracle-based algorithms. While our bound improves on the O(T 3/4) bounds in prior work [7, 8], achieving the optimal O( p TK log(N)) regret bound with an oracle based approach still remains an important open question. Another interesting avenue for future work involves removing the stochastic assumption on the contexts. 8 References [1] Alekh Agarwal, Daniel Hsu, Satyen Kale, John Langford, Lihong Li, and Robert E. Schapire. Taming the monster: A fast and simple algorithm for contextual bandits. In International Conference on Machine Learning (ICML), 2014. [2] Peter Auer, Nicolo Cesa-Bianchi, Yoav Freund, and Robert E. Schapire. Gambling in a rigged casino: The adversarial multi-armed bandit pproblem. In Foundations of Computer Science (FOCS), 1995. [3] Nicolo Cesa-Bianchi, Yoav Freund, David Haussler, David P Helmbold, Robert E Schapire, and Manfred K Warmuth. How to use expert advice. Journal of the ACM (JACM), 1997. [4] Miroslav Dudík, Daniel Hsu, Satyen Kale, Nikos Karampatziakis, John Langford, Lev Reyzin, and Tong Zhang. Efficient optimal learning for contextual bandits. In Uncertainty and Artificial Intelligence (UAI), 2011. [5] Yoav Freund and Robert E Schapire. A decision-theoretic generalization of on-line learning and an application to boosting. Journal of Computer and System Sciences, 1997. [6] John Langford and Tong Zhang. The epoch-greedy algorithm for multi-armed bandits with side information. In Advances in Neural Information Processing Systems (NIPS), 2008. [7] Alexander Rakhlin and Karthik Sridharan. BISTRO: an efficient relaxation-based method for contextual bandits. In International Conference on Machine Learning (ICML), 2016. [8] Vasilis Syrgkanis, Akshay Krishnamurthy, and Robert E. Schapire. Efficient algorithms for adversarial contextual learning. In International Conference on Machine Learning (ICML), 2016. 9 | 2016 | 506 |
6,446 | Joint quantile regression in vector-valued RKHSs Maxime Sangnier Olivier Fercoq Florence d’Alch´e-Buc LTCI, CNRS, T´el´ecom ParisTech Universit´e Paris-Saclay 75013, Paris, France {maxime.sangnier, olivier.fercoq, florence.dalche} @telecom-paristech.fr Abstract Addressing the will to give a more complete picture than an average relationship provided by standard regression, a novel framework for estimating and predicting simultaneously several conditional quantiles is introduced. The proposed methodology leverages kernel-based multi-task learning to curb the embarrassing phenomenon of quantile crossing, with a one-step estimation procedure and no postprocessing. Moreover, this framework comes along with theoretical guarantees and an efficient coordinate descent learning algorithm. Numerical experiments on benchmark and real datasets highlight the enhancements of our approach regarding the prediction error, the crossing occurrences and the training time. 1 Introduction Given a couple (X, Y ) of random variables, where Y takes scalar values, a common aim in statistics and machine learning is to estimate the conditional expectation E [Y | X = x] as a function of x. In the previous setting, called regression, one assumes that the main information in Y is a scalar value corrupted by a centered noise. However, in some applications such as medicine, economics, social sciences and ecology, a more complete picture than an average relationship is required to deepen the analysis. Expectiles and quantiles are different quantities able to achieve this goal. This paper deals with this last setting, called (conditional) quantile regression. This topic has been championed by Koenker and Bassett [16] as the minimization of the pinball loss (see [15] for an extensive presentation) and brought to the attention of the machine learning community by Takeuchi et al. [26]. Ever since then, several studies have built upon this framework and the most recent ones include regressing a single quantile of a random vector [12]. On the contrary, we are interested in estimating and predicting simultaneously several quantiles of a scalar-valued random variable Y |X (see Figure 1), thus called joint quantile regression. For this purpose, we focus on non-parametric hypotheses from a vector-valued Reproducing Kernel Hilbert Space (RKHS). Since quantiles of a distribution are closely related, joint quantile regression is subsumed under the field of multi-task learning [3]. As a consequence, vector-valued kernel methods are appropriate for such a task. They have already been used for various applications, such as structured classification [10] and prediction [7], manifold regularization [21, 6] and functional regression [14]. Quantile regression is a new opportunity for vector-valued RKHSs to perform in a multi-task problem, along with a loss that is different from the ℓ2 cost predominantly used in the previous references. In addition, such a framework offers a novel way to curb the phenomenon of quantile curve crossing, while preserving the so called quantile property (which may not be true for current approaches). This one guarantees that the ratio of observations lying below a predicted quantile is close to the quantile level of interest. 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. In a nutshell, the contributions of this work are (following the outline of the paper): i) a novel methodology for joint quantile regression, that is based on vector-valued RKHSs; ii) enhanced predictions thanks to a multi-task approach along with limited appearance of crossing curves; iii) theoretical guarantees regarding the generalization of the model; iv) an efficient coordinate descent algorithm, that is able to handle the intercept of the model in a manner that is simple and different from Sequential Minimal Optimization (SMO). Besides these novelties, the enhancements of the proposed method and the efficiency of our learning algorithm are supported by numerical experiments on benchmark and real datasets. 2 Problem definition 2.1 Quantile regression Let Y ⊂R be a compact set, X be an arbitrary input space and (X, Y ) ∈X × Y a pair of random variables following an unknown joint distribution. For a given probability τ ∈(0, 1), the conditional τ-quantile of (X, Y ) is the function µτ : X →R such that µτ(x) = inf{µ ∈R : P (Y ≤µ | X = x) ≥τ}. Thus, given a training set {(xi, yi)}n i=1 ∈(X × Y)n, the quantile regression problem aims at estimating this conditional τ-quantile function µτ. Following Koenker [15], this can be achieved by minimization of the pinball loss: ℓτ(r) = max(τr, (τ −1)r), where r ∈R is a residual. Using such a loss first arose from the observation that the location parameter µ that minimizes the ℓ1-loss Pn i=1 |yi −µ| is an estimator of the unconditional median [16]. Now focusing on the estimation of a conditional quantile, one can show that the target function µτ is a minimizer of the τ-quantile risk Rτ(h) = E [ℓτ(Y −h(X))] [17]. However, since the joint probability of (X, Y ) is unknown but we are provided with an independent and identically distributed (iid) sample of observations {(xi, yi)}n i=1, we resort to minimizing the empirical risk: Remp τ (h) = 1 n Pn i=1 ℓτ(yi −h(xi)), within a class H ⊂(R)X of functions, calibrated in order to overcome the shift from the true risk to the empirical one. In particular, when H has the form: H = {h = f + b : b ∈R, f ∈(R)X , ψ(f) ≤c}, with ψ: (R)X →R being a convex function and c > 0 a constant, Takeuchi et al. [26] proved that (similarly to the unconditional case) the quantile property is satisfied: for any estimator ˆh, obtained by minimizing Remp τ in H, the ratio of observations lying below ˆh (i.e. yi < ˆh(xi)) equals τ to a small error (the ration of observations exactly equal to ˆh(xi)). Moreover, under some regularity assumptions, this quantity converges to τ when the sample grows. Note that these properties are true since the intercept b is unconstrained. 2.2 Multiple quantile regression In many real problems (such as medical reference charts), one is not only interested by estimating a single quantile curve but a few of them. Thus, denoting Np the range of integers between 1 and p, for several quantile levels τj (j ∈Np) and functions hj ∈H, the empirical loss to be minimized can bi written as the following separable function: Remp τ (h1, . . . , hp) = 1 n Pn i=1 Pp j=1 ℓτj(yi −hj(xi)), where τ denotes the p dimensional vector of quantile levels. A nice feature of multiple quantile regression is thus to extract slices of the conditional distribution of Y |X. However, when quantiles are estimated independently, an embarrassing phenomenon often appears: quantile functions cross, thus violating the basic principle that the cumulative distribution function should be monotonically non-decreasing. We refer to that pitfall as the crossing problem. In this paper, we propose to prevent curve crossing by considering the problem of multiple quantile regression as a vector-valued regression problem where outputs are not independent. An interesting feature of our method is to preserve the quantile property while most other approaches lose it when struggling to the crossing problem. 2.3 Related work Going beyond linear and spline-based models, quantile regression in RKHSs has been introduced a decade ago [26, 17]. In [26], the authors proposed to minimize the pinball loss in a scalar-valued RKHS and to add hard constraints on the training points in order to prevent the crossing problem. Our work can be legitimately seen as an extension of [26] to multiple quantile regression using 2 a vector-valued RKHS and structural constraints against curve crossing thanks to an appropriate matrix-valued kernel. Another related work is [27], which first introduced the idea of multi-task learning for quantile regression. In [27], linear quantile curves are estimated jointly with a common feature subspace shared across the tasks, based on multi-task feature learning [3]. In addition, the authors showed that for such linear regressors, a common representation shared across infinitely many tasks can be computed, thus estimating simultaneously conditional quantiles for all possible quantile levels. Both previous approaches will be considered in the numerical experiments. Quantile regression has been investigated from many perspectives, including different losses leading to an approximate quantile property (ϵ-insensitive [25], re-weighted least squares [22]) along with models and estimation procedures to curb the crossing problem: location-scale model with a multi-step strategy [13], tensor product spline surface [22], non-negative valued kernels [18], hard non-crossing constraints [26, 28, 5], inversion and monotonization of a conditional distribution estimation [9] and rearrangement of quantile estimations [8], to cite only a few references. Let us remark that some solutions such as non-crossing constraints [26] lose theoretically the quantile property because of constraining the intercept. In comparison to the literature, we propose a novel methodology, based on vector-valued RKHSs, with a one-step estimation, no post-processing, and keeping the quantile property while dealing with curve crossing. We also provide an efficient learning algorithm and theoretical guarantees. 3 Vector-valued RKHS for joint quantile regression 3.1 Joint estimation Given a vector τ ∈(0, 1)p of quantile levels, multiple quantile regression is now considered as a joint estimation in (Rp)X of the target function x ∈X 7→(µτ1(x), . . . , µτp(x)) ∈Rp of conditional quantiles. Thus, let now ψ be a convex regularizer on (Rp)X and H = {h = f + b : b ∈ Rp, f ∈(Rp)X , ψ(f) ≤c} be the hypothesis set. Similarly to previously, joint quantile regression aims at minimizing Remp τ (h) = 1 n Pn i=1 ℓτ(yi1 −h(xi)), where 1 stands for the all-ones vector, ℓτ(r) = Pp j=1 ℓτj(rj) and h is in H, which is to be appropriately chosen in order to estimate the p conditional quantiles while enhancing predictions and avoiding curve crossing. It is worthwhile remarking that, independently of the choice of ψ, the quantile property is still verified for a vectorvalued estimator since the loss is separable and the intercept is unconstrained. Similarly, the vectorvalued function whose components are the conditional τj-quantiles is still a minimizer of the τquantile risk Rτ(h) = E [ℓτ(Y 1 −h(X))]. In this context, the constraint ψ does not necessarily apply independently on each coordinate function hj but can impose dependency between them. The theory of vector-valued RKHS seems especially well suited for this purpose when considering ψ as the norm associated to it. In this situation, the choice of the kernel does not only influence the nature of the hypotheses (linear, non-linear, universal approximators) but also the way the estimation procedure is regularized. In particular, the kernel critically operates on the output space by encoding structural constraints on the outputs. 3.2 Matrix-valued kernel Let us denote ·⊤the transpose operator and L(Rp) the set of linear and bounded operators from Rp to itself. In our (finite) case, L(Rp) comes down to the set of p × p real-valued matrices. A matrix-valued kernel is a function K : X × X →L(Rp), that is symmetric and positive [20]: ∀(x, x′) ∈X × X, K(x, x′) = K(x′, x)⊤and ∀m ∈N, ∀{(αi, βi)}1≤i≤m ∈(X × Rp)m, P 1≤i,j≤m βi | K(αi, αj)βj ℓ2 ≥0. Let K be such a kernel and for any x ∈X, let Kx : y ∈Rp 7→Kxy ∈(Rp)X be the linear operator such that: ∀x′ ∈X, (Kxy)(x′) = K(x′, x)y. There exists a unique Hilbert space of functions KK ⊂(Rp)X (with an inner product and a norm respectively denoted ⟨· | ·⟩K and ∥·∥K), called the RKHS associated to K, such that ∀x ∈X [20]: Kx spans the space KK (∀y ∈Rp : Kxy ∈K), Kx is bounded for the uniform norm (supy∈Rp ∥Kxy∥K < ∞) and ∀f ∈K: f(x) = K∗ xf (reproducing property), where ·∗is the adjoint operator. 3 From now on, we assume that we are provided with a matrix-valued kernel K and we limit the hypothesis space to: H = {f + b : b ∈Rp, f ∈KK, ∥f∥K ≤c} (i.e. ψ = ∥·∥K). Though several candidates are available [1], we focus on one of the simplest and most efficiently computable kernels, called decomposable kernel: K : (x, x′) 7→k(x, x′)B, where k: X ×X →R is a scalar-valued kernel and B is a p×p symmetric Positive Semi-Definite (PSD) matrix. In this particular case, the matrix B encodes the relationship between the components fj and thus, the link between the different conditional quantile estimators. A rational choice is to consider B = exp(−γ(τi −τj)2) 1≤i,j≤p. To explain it, let us consider two extreme cases (see also Figure 1). First, when γ = 0, B is the all-ones matrix. Since KK is the closure of the space span {Kxy : (x, y) ∈X × Rp}, any f ∈KK has all its components equal. Consequently, the quantile estimators hj = fj + bj are parallel (and non-crossing) curves. In this case, the regressor is said homoscedastic. Second, when γ →+∞, then B →I (identity matrix). In this situation, it is easy to show that the components of f ∈KK are independent from each other and that ∥f∥2 K = Pp j=1 ∥fj∥2 K′ (where ∥·∥K′ is the norm coming with the RKHS associated to k) is separable. Thus, each quantile function is learned independently from the others. Regressors are said heteroscedastic. It appears clearly that between these two extreme cases, there is a room for learning a non-homescedastic and non-crossing quantile regressor (while preserving the quantile property). Figure 1: Estimated (plain lines) and true (dashed lines) conditional quantiles of Y |X (synthetic dataset) from homoscedastic regressors (γ = 0) to heteroscedastic ones (γ →+∞). 4 Theoretical analysis This section is intended to give a few theoretical insights about the expected behavior of our hypotheses. Here, we do assume working in an RKHS but not specifically with a decomposable kernel. First, we aim at providing a uniform generalization bound. For this purpose, let F = {f ∈KK, ∥f∥K ≤c}, tr(·) be the trace operator, ((Xi, Yi))1≤i≤n ∈(X × Y)n be an iid sample and denote ˆRn(h) = 1 n Pn i=1 ℓτ(Yi1 −h(Xi)), the random variable associated to the empirical risk of a hypothesis h. Theorem 4.1 (Generalization). Let a ∈R+ such that supy∈Y |y| ≤a, b ∈Yp and H = {f + b : f ∈F} be the class of hypotheses. Moreover, assume that there exists κ ≥0 such that: supx∈X tr(K(x, x)) ≤κ. Then with probability at least 1 −δ (for δ ∈(0, 1]): ∀h ∈H, R(h) ≤ˆRn(h) + 2 √ 2c rpκ n + (2pa + c√pκ) r log(1/δ) 2n . Sketch of proof (full derivation in Appendix A.1). We start with a concentration inequality for scalar-valued functions [4] and we use a vector-contraction property [19]. The bound on the Rademacher complexity of [24, Theorem 3.1] concludes the proof. The uniform bound in Theorem 4.1 states that, with high probability, all the hypotheses of interest have a true risk which is less that an empirical risk to an additive bias in O(1/√n). Let us remark that it makes use of the output dimension p. However, there exist non-uniform generalization bounds for operator-valued kernel-based hypotheses, which do not depend on the output dimension [14], being thus well-suited for infinite-dimensional output spaces. Yet those results, only hold for optimal solutions ˆh of the learning problem, which we never obtain in practice. As a second theoretical insight, Theorem 4.2 gives a bound on the quantile property, which is similar to the one provided in [26] for scalar-valued functions. This one states that E [P (Y ≤hj(X) | X)] does not deviate to much from τj. 4 Theorem 4.2 (Quantile deviation). Let us consider that the assumptions of Theorem 4.1 hold. Moreover, let ϵ > 0 be an artificial margin, Γ+ ϵ : r ∈R 7→proj[0,1] 1 −r ϵ and Γ− ϵ : r ∈R 7→ proj[0,1] −r ϵ , two ramp functions, j ∈Np and δ ∈(0, 1]. Then with probability at least 1 −δ: ∀h ∈H, 1 n n X i=1 Γ− ϵ (Yi−hj(Xi))−∆≤E [P (Y ≤hj(X) | X)] ≤1 n n X i=1 Γ+ ϵ (Yi −hj(Xi)) | {z } ≈τj +∆, where ∆= 2c ϵ p κ n + q log(2/δ) 2n . Sketch of proof (full derivation in Appendix A.2). The proof is similar to the one of Theorem 4.1, when remarking that Γ+ ϵ and Γ− ϵ are 1/ϵ-Lipschitz continuous. 5 Optimization algorithm In order to finalize the M-estimation of a non-parametric function, we need a way to jointly solve the optimization problem of interest and compute the estimator. For ridge regression in vector-valued RKHSs, representer theorems enable to reformulate the hypothesis f and to derive algorithms based on matrix inversion [20, 6] or Sylvester equation [10]. Since the optimization problem we are tackling is quite different, those methods do not apply. Yet, deriving a dual optimization problem makes it possible to hit the mark. Quantile estimation, as presented in this paper, comes down to minimizing a regularized empirical risk, defined by the pinball loss ℓτ. Since this loss function is non-differentiable, we introduce slack variables ξ and ξ∗to get the following primal formulation. We also consider a regularization parameter C to be tuned: minimize f∈KK ,b∈Rp, ξ,ξ∗∈(Rp)n 1 2 ∥f∥2 K + C n X i=1 ⟨τ | ξi⟩ℓ2 +⟨1 −τ | ξ∗ i ⟩ℓ2 s. t. ∀i ∈Nn : ξi ≽0, ξ∗ i ≽0, yi −f(xi) −b = ξi −ξ∗ i , (1) where ≽is a pointwise inequality. A dual formulation of Problem (1) is (see Appendix B): minimize α∈(Rp)n 1 2 n X i,j=1 ⟨αi | K(xi, xj)αj⟩ℓ2 − n X i=1 yi ⟨αi | 1⟩ℓ2 s. t. n X i=1 αi = 0Rp, ∀i ∈Nn : C(τ −1) ≼αi ≼Cτ, (2) where the linear constraints come from considering an intercept b. The Karush-Kuhn-Tucker (KKT) conditions of Problem (1) indicate that a minimizer ˆf of (1) can be recovered from a solution ˆα of (2) with the formula ˆf = Pn i=1 Kxi ˆαi. Moreover, ˆb can also be obtained thanks to KKT conditions. However, as we deal with a numerical approximate solution α, in practice b is computed by solving Problem (1) with f fixed. This boils down to taking bj as the τj-quantile of (yi −fj(xi))1≤i≤n. Problem (2) is a common quadratic program that can be solved with off-the-shelf solvers. However, since we are essentially interested in decomposable kernels K(·, ·) = k(·, ·)B, it appears that the quadratic part of the objective function would be defined by the np × np matrix K ⊗B, where ⊗ is the Kronecker product and K = (k(xi, xj))1≤i,j≤n. Storing this matrix explicitly is likely to be time and memory expensive. In order to improve the estimation procedure, ad hoc algorithms can be derived. For instance, regression with a decomposable kernel boils down to solving a Sylvester equation (which can be done efficiently) [10] and vector-valued Support Vector Machine (SVM) without intercept can be learned with a coordinate descent algorithm [21]. However, these methods can not be used in our setting since the loss function is different and considering the intercept is necessary for the quantile property. Yet, coordinate descent could theoretically be extended in an SMO technique, able to handle the linear constraints introduced by the intercept. However, SMO works usually with a single linear constraint and needs heuristics to run efficiently, which are quite difficult to find (even though an implementation exists for two linear constraints [25]). Therefore, for the sake of efficiency, we propose to use a Primal-Dual Coordinate Descent (PDCD) technique, recently introduced in [11]. This algorithm (which is proved to converge) is able to deal with the linear constraints coming from the intercept and is thus utterly workable for the problem at hand. Moreover, PDCD has been proved favorably competitive with SMO for SVMs. 5 Table 1: Empirical pinball loss and crossing loss ×100 (the less, the better). Bullets (resp. circles) indicate statistically significant (resp non-significant) differences. The proposed method is JQR. Pinball loss Crossing loss Data set IND. IND. (NC) MTFL JQR IND. IND. (NC) MTFL JQR caution - 102.6 ± 17.3 103.2 ± 17.2 102.9 ± 19.0 ◦◦◦102.6 ± 19.0 - 0.53 ± 0.67 0.31 ± 0.70 0.69 ± 0.54 •◦• 0.09 ± 0.14 ftcollinssnow 151.1 ± 8.2 150.8 ± 8.0 152.4 ± 8.9 ◦◦◦153.7 ± 12.1 - 0.00 ± 0.00 0.00 ± 0.00 0.00 ± 0.00 ◦◦◦0.00 ± 0.00 highway - 102.9 ± 39.1 102.8 ± 38.9 102.0 ± 34.5 ◦◦◦103.7 ± 35.7 - 9.08 ± 7.38 9.00 ± 7.39 3.48 ± 4.49 ◦◦• 8.81 ± 7.46 heights 128.2 ± 2.4 128.2 ± 2.4 128.6 ± 2.2 ◦◦• 127.9 ± 1.8 - 0.04 ± 0.05 0.04 ± 0.05 0.07 ± 0.14 ••• 0.00 ± 0.00 sniffer 44.8 ± 6.7 44.6 ± 6.8 46.9 ± 7.6 ◦◦• 45.2 ± 6.9 - 1.01 ± 0.75 0.52 ± 0.48 1.23 ± 0.77 ••• 0.15 ± 0.22 snowgeese 68.4 ± 35.3 68.4 ± 35.3 75.3 ± 38.2 ◦◦◦76.0 ± 31.5 - 3.24 ± 5.10 2.60 ± 4.28 8.93 ± 19.52 ••◦0.94 ± 3.46 ufc 81.8 ± 4.6 81.6 ± 4.6 84.9 ± 4.7 ••• 80.6 ± 4.1 - 0.24 ± 0.22 0.27 ± 0.42 0.82 ± 1.47 ••• 0.05 ± 0.15 birthwt 139.0 ± 9.9 139.0 ± 9.9 142.6 ± 11.6 ◦◦◦139.8 ± 11.7 - 0.00 ± 0.00 0.00 ± 0.00 0.31 ± 0.88 ◦◦• 0.00 ± 0.00 crabs 12.3 ± 1.0 12.3 ± 1.0 12.6 ± 1.0 ••• 11.9 ± 0.9 - 0.46 ± 0.33 0.35 ± 0.24 0.30 ± 0.22 ••• 0.06 ± 0.20 GAGurine 62.6 ± 8.2 62.6 ± 8.2 64.5 ± 7.5 ◦◦• 62.6 ± 8.1 - 0.05 ± 0.08 0.04 ± 0.07 0.05 ± 0.09 ◦◦◦0.03 ± 0.08 geyser 110.2 ± 7.8 110.1 ± 7.8 109.4 ± 7.1 ◦◦◦111.3 ± 8.2 - 0.87 ± 1.60 0.92 ± 2.02 0.80 ± 1.18 ◦◦◦0.72 ± 1.51 gilgais 47.4 ± 4.4 47.2 ± 4.4 49.9 ± 3.6 ◦◦• 46.9 ± 4.6 - 1.23 ± 0.96 0.95 ± 0.85 0.71 ± 0.96 ◦◦◦0.81 ± 0.43 topo 71.1 ± 13.0 70.1 ± 13.7 73.1 ± 11.8 ◦◦◦69.6 ± 13.4 - 2.72 ± 3.26 1.52 ± 2.47 2.75 ± 2.93 •◦• 1.14 ± 2.02 BostonHousing 48.5 ± 5.0 48.5 ± 5.0 49.7 ± 4.7 ••• 47.4 ± 4.7 - 0.64 ± 0.32 0.48 ± 0.27 1.11 ± 0.33 ◦•• 0.58 ± 0.34 CobarOre 0.5 ± 0.5 0.5 ± 0.5 5.0 ± 4.9 ••• 0.6 ± 0.5 - 0.10 ± 0.13 0.10 ± 0.13 0.29 ± 0.35 ••• 0.02 ± 0.05 engel 61.3 ± 18.3 61.2 ± 19.0 58.7 ± 17.9 ◦◦• 64.4 ± 23.2 - 1.50 ± 4.94 1.25 ± 4.53 1.65 ± 5.97 •◦◦0.06 ± 0.14 mcycle 89.2 ± 8.5 88.9 ± 8.4 102.0 ± 11.7 ••• 84.3 ± 10.3 - 2.10 ± 1.83 0.92 ± 1.25 1.13 ± 1.10 ••• 0.14 ± 0.37 BigMac2003 71.0 ± 21.0 70.9 ± 21.1 68.7 ± 18.1 ••◦67.6 ± 20.9 - 2.50 ± 2.12 1.87 ± 1.68 0.73 ± 0.92 ◦◦◦1.55 ± 1.75 UN3 99.5 ± 7.0 99.4 ± 7.0 101.8 ± 7.1 ◦◦• 98.8 ± 7.6 - 1.06 ± 0.85 0.85 ± 0.70 0.65 ± 0.62 ••• 0.09 ± 0.31 cpus 20.0 ± 13.7 19.9 ± 13.6 23.8 ± 16.0 ◦◦• 19.7 ± 13.7 - 1.29 ± 1.13 1.17 ± 1.15 0.46 ± 0.28 ••• 0.09 ± 0.13 PDCD is described in Algorithm 1, where, for α = (αi)1≤i≤n ∈(Rp)n, αj ∈Rn denotes its jth row vector and αj i its ith component, diag is the operator mapping a vector to a diagonal matrix and proj1 and proj[C(τl−1),Cτl] are respectively the projectors onto the vector 1 and the compact set [C(τl −1), Cτl]. PDCD uses dual variables θ ∈(Rp)n (which are updated during the descent) and has two sets of parameters ν ∈(Rp)n and µ ∈(Rp)n, that verify (∀(i, l) ∈Nn × Np): µl i < 1 (K(xi,xi))l,l+νl i . In practice, we kept the same parameters as in [11]: νl i = 10(K(xi, xi))l,l and µl i equal to 0.95 times the bound. Moreover, as it is standard for coordinate descent methods, our implementation uses efficient updates for the computation of both Pn j=1 K(xi, xj)αj and θ l. 6 Numerical experiments Two sets of experiments are presented, respectively aimed at assessing the ability of our methodology to predict quantiles and at comparing an implementation of Algorithm 1 with an off-theshelf solver and an augmented Lagrangian scheme. Following the previous sections, a decomposable kernel K(x, x′) = k(x, x′)B is used, where B = (exp(−γ(τi −τj)2))1≤i,j≤p and k(x, x′) = exp(−∥x −x′∥2 ℓ2 /2σ2), with σ being the 0.7-quantile of the pairwise distances of the training data {xi}1≤i≤n. Quantile levels of interest are τ = (0.1, 0.3, 0.5, 0.7, 0.9). 6.1 Quantile regression Quantile regression is assessed with two criteria: the pinball loss 1 n Pn i=1 ℓτ(yi1 − h(xi)) is the one minimized to build the proposed estimator and the crossing loss Pp−1 j=1 1 n Pn i=1 max(0, hj+1(xi) −hj(xi)) , assuming that τj > τj+1, quantifies how far hj goes below hj+1, while hj is expected to stay always above hj+1. More experiments are in Appendix D.1. This study focuses on three non-parametric models based on the RKHS theory. Other linear and spline-based models have been dismissed since Takeuchi et al. [26] have already provided a comparison of these ones with kernel methods. First, we considered an independent estimation of quantile regressors (IND.), which boils down to setting B = I (this approach could be set up without vector-valued RKHSs but with scalar-valued kernels only). Second, hard non-crossing constraints on the training data have been imposed (IND. (NC)), as proposed in [26]. Third, the proposed joint estimator (JQR) uses the Gaussian matrix B presented above. Quantile regression with multi-task feature learning (MTFL), as proposed in [27], is also included. For a fair comparison, each point is mapped with ψ(x) = (k(x, x1), . . . , k(x, xn)) and the estimator h(x) = W ⊤ψ(x) + b (W ∈Rn×p) is learned jointly with the PSD matrix D ∈Rn×n of the 6 Algorithm 1 Primal-Dual Coordinate Descent. Initialize αi, θi ∈Rp (∀i ∈Nn). repeat Choose (i, l) ∈Nn × Np uniformly at random. Set θ l ←proj1 θl + diag(νl)αl . Set dl i ←Pn j=1(K(xi, xj)αj)l −yi + 2θ l i −θl i. Set αl i ←proj[C(τl−1),Cτl] αl i −µl idl i . Update coordinate (i, l): αl i ←αl i, θl i ←θ l i, and keep other coordinates unchanged. until duality gap (1)-(2) is small enough Table 2: CPU time (s) for training a model. Size QP AUG. LAG. PDCD 250 8.73 ± 0.34 261.11 ± 46.69 18.69 ± 3.54 500 75.53 ± 2.98 865.86 ± 92.26 61.30 ± 7.05 1000 621.60 ± 30.37 – 266.50 ± 41.16 2000 3416.55 ± 104.41 – 958.93 ± 107.80 regularizer ψ(h) = tr(W ⊤D−1W ). This comes down to alternating our approach (with B = I and k(·, ·) = ⟨· | D·⟩ℓ2) and the update D ←(W W ⊤)1/2/ tr((W W ⊤)1/2). To present an honorable comparison of these four methods, we did not choose datasets for the benefit of our method but considered the ones used in [26]. These 20 datasets (whose names are indicated in Table 1) come from the UCI repository and three R packages: quantreg, alr3 and MASS. The sample sizes vary from 38 (CobarOre) to 1375 (heights) and the numbers of explanatory variables vary from 1 (5 sets) to 12 (BostonHousing). The datasets were standardized coordinate-wise to have zero mean and unit variance. Results are given in Table 1 thanks to the mean and the standard deviation of the test losses recorded on 20 random splits train-test with ratio 0.7-0.3. The best result of each line is boldfaced and the bullets indicate the significant differences of each competitor from JQR (based on a Wilcoxon signed-rank test with significance level 0.05). The parameter C is chosen by cross-validation (minimizing the pinball loss) inside a logarithmic grid (10−5, 10−4, . . . , 105) for all methods and datasets. For our approach (JQR), the parameter γ is chosen in the same grid as C with extra candidates 0 and +∞. Finally, for a balanced comparison, the dual optimization problems corresponding to each approach are solved with CVXOPT [2]. Regarding the pinball loss, joint quantile regression compares favorably to independent and hard non-crossing constraint estimations for 12 vs 8 datasets (5 vs 1 significantly different). These results bear out the assumption concerning the relationship between conditional quantiles and the usefulness of multiple-output methods for quantile regression. Prediction is also enhanced compared to MTFL for 15 vs 5 datasets (11 vs 1 significantly different). The crossing loss clearly shows that joint regression enables to weaken the crossing problem, in comparison to independent estimation and hard non-crossing constraints (18 vs 1 favorable datasets and 9 vs 0 significantly different). Results are similar compared to MTFL (16 vs 3, 12 vs 1). Note that for IND. (NC), the crossing loss is null on the training data by construction but not necessarily on the test data. In addition, let us remark that model selection (and particularly for γ, which tunes the trade-off between hetero and homoscedastic regressors) has been performed based on the pinball loss only. It seems that, in a way, the pinball loss embraces the crossing loss as a subcriterion. 6.2 Learning algorithms This section is aimed at comparing three implementations of algorithms for estimating joint quantile regressors (solving Problem 2), following their running (CPU) time. First, the off-the-shelf solver (based on an interior-point method) included in CVXOPT [2] (QP) is applied to Problem (2) turned into a standard form of linearly constrained quadratic program. Second, an augmented Lagrangian scheme (AUG. LAG) is used in order to get rid of the linear constraints and to make it possible to use a coordinate descent approach (detailed procedure in Appendix C). In this scheme, the inner solver is Algorithm 1 when the intercept is dismissed, which boils down to be the algorithm proposed in [23]. The last approach (PDCD) is Algorithm 1. We use a synthetic dataset (the same as in Figure 1), for which X ∈[0, 1.5]. The target Y is computed as a sine curve at 1 Hz modulated by a sine envelope at 1/3 Hz and mean 1. Moreover, this pattern is distorted with a random Gaussian noise with mean 0 and a linearly decreasing standard deviation from 1.2 at X = 0 to 0.2 at X = 1.5. Parameters for the models are: (C, γ) = (102, 10−2). 7 To compare the implementations of the three algorithms, we first run QP, with a relative tolerance set to 10−2, and store the optimal objective value. Then, the two other methods (AUG. LAG and PDCD) are launched and stopped when they pass the objective value reached by QP (optimal objective values are reported in Appendix D.2). Table 2 gives the mean and standard deviation of the CPU time required by each method for 10 random datasets and several sample sizes. Some statistics are missing because AUG. LAG. ran out of time. As expected, it appears that for a not too tight tolerance and big datasets, implementation of Algorithm 1 outperforms the two other competitors. Let us remark that QP is also more expensive in memory than the coordinate-based algorithms like ours. Moreover, training time may seem high in comparison to usual SVMs. However, let us first remind that we jointly learn p regressors. Thus, a fair comparison should be done with an SVM applied to an np × np matrix, instead of n × n. In addition, there is no sample sparsity in quantile regression, which does speed up SVM training. Last but not least, in order to illustrate the use of our algorithm, we have run it on two 2000-point datasets from economics and medicine: the U.S. 2000 Census data, consisting of annual salary and 9 related features on workers, and the 2014 National Center for Health Statistics’ data, regarding girl birth weight and 16 statistics on parents.1 Parameters (C, γ) have been set to (1, 100) and (0.1, 1) respectively for the Census and NCHS datasets (determined by cross-validation). Figure 2 depicts 9 estimated conditional quantiles of the salary with respect to the education (17 levels from no schooling completed to doctorate degree) and of the birth weight (in grams) vs mother’s prepregnancy weight (in pounds). As expected, the Census data reveal an increasing and heteroscedastic trend while new-born’s weight does not seem correlated to mother’s weight. Figure 2: Estimated conditional quantiles for the Census (left, salary vs education) and the NCHS data (right, birth weight vs mother’s pre-pregnancy weight). 7 Conclusion This paper introduces a novel framework for joint quantile regression, which is based on vectorvalued RKHSs. It comes along with theoretical guarantees and an efficient learning algorithm. Moreover, this methodology, which keeps the quantile property, enjoys few curve crossing and enhanced performances compared to independent estimations and hard non-crossing constraints. To go forward, let us remark that this framework benefits from all the tools now associated with vector-valued RKHSs, such as manifold learning for the semi-supervised setting, multiple kernel learning for measuring feature importance and random Fourier features for very large scale applications. Moreover, extensions of our methodology to multivariate output variables are to be investigated, given that it requires to choose among the various definitions of multivariate quantiles. Acknowledgments This work was supported by the industrial chair “Machine Learning for Big Data”. References [1] M.A. Alvarez, L. Rosasco, and N.D. Lawrence. Kernels for Vector-Valued Functions: a Review. Foundations and Trends in Machine Learning, 4(3):195–266, 2012. arXiv: 1106.6251. 1Data are available at www.census.gov/census2000/PUMS5.html and www.nber.org/data/ vital-statistics-natality-data.html. 8 [2] M.S. Anderson, J. Dahl, and L. Vandenberghe. CVXOPT: A Python package for convex optimization, version 1.1.5., 2012. [3] A. Argyriou, T. Evgeniou, and M. Pontil. Convex multi-task feature learning. Machine Learning, 73(3): 243–272, 2008. [4] P.L. Bartlett and S. Mendelson. Rademacher and gaussian complexities: Risk bounds and structural results. Journal of Machine Learning Research, 3:463–482, 2002. [5] H.D. Bondell, B.J. Reich, and H. Wang. Noncrossing quantile regression curve estimation. Biometrika, 97(4):825–838, 2010. [6] C. Brouard, F. d’Alch´e Buc, and M. Szafranski. Semi-supervised Penalized Output Kernel Regression for Link Prediction. In Proceedings of the 28th International Conference on Machine Learning, 2011. [7] C. Brouard, M. Szafranski, and F. d’Alch´e Buc. Input Output Kernel Regression: Supervised and SemiSupervised Structured Output Prediction with Operator-Valued Kernels. Journal of Machine Learning Research, 17(176):1–48, 2016. [8] V. Chernozhukov, I. Fern´andez-Val, and A. Galichon. Quantile and Probability Curves Without Crossing. Econometrica, 78(3):1093–1125, 2010. [9] H. Dette and S. Volgushev. Non-crossing non-parametric estimates of quantile curves. Journal of the Royal Statistical Society: Series B (Statistical Methodology), 70(3):609–627, 2008. [10] F. Dinuzzo, C.S. Ong, P. Gehler, and G. Pillonetto. Learning Output Kernels with Block Coordinate Descent. In Proceedings of the 28th International Conference of Machine Learning, 2011. [11] O. Fercoq and P. Bianchi. A Coordinate Descent Primal-Dual Algorithm with Large Step Size and Possibly Non Separable Functions. arXiv:1508.04625 [math], 2015. [12] M. Hallin and M. ˇSiman. Elliptical multiple-output quantile regression and convex optimization. Statistics & Probability Letters, 109:232–237, 2016. [13] X. He. Quantile Curves without Crossing. The American Statistician, 51(2):186–192, 1997. [14] H. Kadri, E. Duflos, P. Preux, S. Canu, A. Rakotomamonjy, and J. Audiffren. Operator-valued Kernels for Learning from Functional Response Data. Journal of Machine Learning Research, 16:1–54, 2015. [15] R. Koenker. Quantile Regression. Cambridge University Press, Cambridge, New York, 2005. [16] R. Koenker and G. Bassett. Regression Quantiles. Econometrica, 46(1):33–50, 1978. [17] Y. Li, Y. Liu, and J. Zhu. Quantile Regression in Reproducing Kernel Hilbert Spaces. Journal of the American Statistical Association, 102(477):255–268, 2007. [18] Y. Liu and Y. Wu. Simultaneous multiple non-crossing quantile regression estimation using kernel constraints. Journal of nonparametric statistics, 23(2):415–437, 2011. [19] A. Maurer. A vector-contraction inequality for Rademacher complexities. In Proceedings of The 27th International Conference on Algorithmic Learning Theory, 2016. [20] C.A. Micchelli and M.A. Pontil. On Learning Vector-Valued Functions. Neural Computation, 17:177– 204, 2005. [21] H.Q. Minh, L. Bazzani, and V. Murino. A Unifying Framework in Vector-valued Reproducing Kernel Hilbert Spaces for Manifold Regularization and Co-Regularized Multi-view Learning. Journal of Machine Learning Research, 17(25):1–72, 2016. [22] S.K. Schnabel and P.H.C. Eilers. Simultaneous estimation of quantile curves using quantile sheets. AStA Advances in Statistical Analysis, 97(1):77–87, 2012. [23] S. Shalev-Shwartz and T. Zhang. Stochastic Dual Coordinate Ascent Methods for Regularized Loss Minimization. Journal of Machine Learning Research, 14:567–599, 2013. [24] V. Sindhwani, M.H. Quang, and A.C. Lozano. Scalable Matrix-valued Kernel Learning for Highdimensional Nonlinear Multivariate Regression and Granger Causality. In Proceedings of the TwentyNinth Conference on Uncertainty in Artificial Intelligence, 2013. [25] I. Takeuchi and T. Furuhashi. Non-crossing quantile regressions by SVM. In 2004 IEEE International Joint Conference on Neural Networks, 2004. Proceedings, July 2004. [26] I. Takeuchi, Q.V. Le, T.D. Sears, and A.J. Smola. Nonparametric Quantile Estimation. Journal of Machine Learning Research, 7:1231–1264, 2006. [27] I. Takeuchi, T. Hongo, M. Sugiyama, and S. Nakajima. Parametric Task Learning. In Advances in Neural Information Processing Systems 26, pages 1358–1366. Curran Associates, Inc., 2013. [28] Y. Wu and Y. Liu. Stepwise multiple quantile regression estimation using non-crossing constraints. Statistics and Its Interface, 2:299–310, 2009. 9 | 2016 | 507 |
6,447 | Kernel Bayesian Inference with Posterior Regularization Yang Song†, Jun Zhu‡∗, Yong Ren‡ † Dept. of Physics, Tsinghua University, Beijing, China ‡ Dept. of Comp. Sci. & Tech., TNList Lab; Center for Bio-Inspired Computing Research State Key Lab for Intell. Tech. & Systems, Tsinghua University, Beijing, China yangsong@cs.stanford.edu; {dcszj@, renyong15@mails}.tsinghua.edu.cn Abstract We propose a vector-valued regression problem whose solution is equivalent to the reproducing kernel Hilbert space (RKHS) embedding of the Bayesian posterior distribution. This equivalence provides a new understanding of kernel Bayesian inference. Moreover, the optimization problem induces a new regularization for the posterior embedding estimator, which is faster and has comparable performance to the squared regularization in kernel Bayes’ rule. This regularization coincides with a former thresholding approach used in kernel POMDPs whose consistency remains to be established. Our theoretical work solves this open problem and provides consistency analysis in regression settings. Based on our optimizational formulation, we propose a flexible Bayesian posterior regularization framework which for the first time enables us to put regularization at the distribution level. We apply this method to nonparametric state-space filtering tasks with extremely nonlinear dynamics and show performance gains over all other baselines. 1 Introduction Kernel methods have long been effective in generalizing linear statistical approaches to nonlinear cases by embedding a sample to the reproducing kernel Hilbert space (RKHS) [1]. In recent years, the idea has been generalized to embedding probability distributions [2, 3]. Such embeddings of probability measures are usually called kernel embeddings (a.k.a. kernel means). Moreover, [4, 5, 6] show that statistical operations of distributions can be realized in RKHS by manipulating kernel embeddings via linear operators. This approach has been applied to various statistical inference and learning problems, including training hidden Markov models (HMM) [7], belief propagation (BP) in tree graphical models [8], planning Markov decision processes (MDP) [9] and partially observed Markov decision processes (POMDP) [10]. One of the key workhorses in the above applications is the kernel Bayes’ rule [5], which establishes the relation among the RKHS representations of the priors, likelihood functions and posterior distributions. Despite empirical success, the characterization of kernel Bayes’ rule remains largely incomplete. For example, it is unclear how the estimators of the posterior distribution embeddings relate to optimizers of some loss functions, though the vanilla Bayes’ rule has a nice connection [11]. This makes generalizing the results especially difficult and hinters the intuitive understanding of kernel Bayes’ rule. To alleviate this weakness, we propose a vector-valued regression [12] problem whose optimizer is the posterior distribution embedding. This new formulation is inspired by the progress in two fields: 1) the alternative characterization of conditional embeddings as regressors [13], and 2) the ∗Corresponding author. introduction of posterior regularized Bayesian inference (RegBayes) [14] based on an optimizational reformulation of the Bayes’ rule. We demonstrate the novelty of our formulation by providing a new understanding of kernel Bayesian inference, with theoretical, algorithmic and practical implications. On the theoretical side, we are able to prove the (weak) consistency of the estimator obtained by solving the vector-valued regression problem under reasonable assumptions. As a side product, our proof can be applied to a thresholding technique used in [10], whose consistency is left as an open problem. On the algorithmic side, we propose a new regularization technique, which is shown to run faster and has comparable accuracy to squared regularization used in the original kernel Bayes’ rule [5]. Similar in spirit to RegBayes, we are also able to derive an extended version of the embeddings by directly imposing regularization on the posterior distributions. We call this new framework kRegBayes. Thanks to RKHS embeddings of distributions, this is the first time, to the best of our knowledge, people can do posterior regularization without invoking linear functionals (such as moments) of the random variables. On the practical side, we demonstrate the efficacy of our methods on both simple and complicated synthetic state-space filtering datasets. Same to other algorithms based on kernel embeddings, our kernel regularized Bayesian inference framework is nonparametric and general. The algorithm is nonparametric, because the priors, posterior distributions and likelihood functions are all characterized by weighted sums of data samples. Hence it does not need the explicit mechanism such as differential equations of a robot arm in filtering tasks. It is general in terms of being applicable to a broad variety of domains as long as the kernels can be defined, such as strings, orthonormal matrices, permutations and graphs. 2 Preliminaries 2.1 Kernel embeddings Let (X, BX ) be a measurable space of random variables, pX be the associated probability measure and HX be a RKHS with kernel k(·, ·). We define the kernel embedding of pX to be µX = EpX[φ(X)] ∈ HX , where φ(X) = k(X, ·) is the feature map. Such a vector-valued expectation always exists if the kernel is bounded, namely supx kX (x, x) < ∞. The concept of kernel embeddings has several important statistical merits. Inasmuch as the reproducing property, the expectation of f ∈H w.r.t. pX can be easily computed as EpX[f(X)] = EpX[⟨f, φ(X)⟩] = ⟨f, µX⟩. There exists universal kernels [15] whose corresponding RKHS H is dense in CX in terms of sup norm. This means H contains a rich range of functions f and their expectations can be computed by inner products without invoking usually intractable integrals. In addition, the inner product structure of the embedding space H provides a natural way to measure the differences of distributions through norms. In much the same way we can define kernel embeddings of linear operators. Let (X, BX ) and (Y, BY) be two measurable spaces, φ(x) and ψ(y) be the measurable feature maps of corresponding RKHS HX and HY with bounded kernels, and p denote the joint distribution of a random variable (X, Y ) on X ×Y with product measures. The covariance operator CXY is defined as CXY = Ep[φ(X)⊗ψ(Y )], where ⊗denotes the tensor product. Note that it is possible to identify CXY with µ(XY ) in HX ⊗HY with the kernel function k((x1, y1), (x2, y2)) = kX (x1, x2)kY(y1, y2) [16]. There is an important relation between kernel embeddings of distributions and covariance operators, which is fundamental for the sequel: Theorem 1 ([4, 5]). Let µX, µY be the kernel embeddings of pX and pY respectively. If CXX is injective, µX ∈R(CXX) and E[g(Y ) | X = ·] ∈HX for all g ∈HY, then µY = CY XC−1 XXµX. (1) In addition, µY |X=x = E[ψ(Y )|X = x] = CY XC−1 XXφ(x). On the implementation side, we need to estimate these kernel embeddings via samples. An intuitive estimator for the embedding µX is bµX = 1 N PN i=1 φ(xi), where {xi}N i=1 is a sample from pX. Similarly, the covariance operators can also be estimated by bCXY = 1 N PN i=1 φ(xi) ⊗ψ(yi). Both operators are shown to converge in the RKHS norm at a rate of Op(N −1 2 ) [4]. 2 2.2 Kernel Bayes’ rule Let π(Y ) be the prior distribution of a random variable Y , p(X = x | Y ) be the likelihood, pπ(Y | X = x) be the posterior distribution given π(Y ) and observation x, and pπ(X, Y ) be the joint distribution incorporating π(Y ) and p(X | Y ). Kernel Bayesian inference aims to obtain the posterior embedding µπ Y (X = x) given a prior embedding πY and a covariance operator CXY . By Bayes’ rule, pπ(Y | X = x) ∝π(Y )p(X = x | Y ). We assume that there exists a joint distribution p on X × Y whose conditional distribution matches p(X | Y ) and let CXY be its covariance operator. Note that we do not require p = pπ hence p can be any convenient distribution. According to Thm. 1, µπ Y (X = x) = Cπ Y XCπ XX −1φ(x), where Cπ Y X corresponds to the joint distribution pπ and Cπ XX to the marginal probability of pπ on X. Recall that Cπ Y X can be identified with µ(Y X) in HY⊗HX , we can apply Thm. 1 to obtain µ(Y X) = C(Y X)Y C−1 Y Y πY , where C(Y X)Y := E[ψ(Y ) ⊗φ(X) ⊗ψ(Y )]. Similarly, Cπ XX can be represented as µ(XX) = C(XX)Y C−1 Y Y πY . This way of computing posterior embeddings is called the kernel Bayes’ rule [5]. Given estimators of the prior embedding bπY = Pm i=1 ˜αiψ(yi) and the covariance operator bCY X, The posterior embedding can be obtained via bµπ Y (X = x) = bCπ Y X([ bCπ XX]2 + λI)−1 bCπ XXφ(x) , where squared regularization is added to the inversion. Note that the regularization for bµπ Y (X = x) is not unique. A thresholding alternative is proposed in [10] without establishing the consistency. We will discuss this thresholding regularization in a different perspective and give consistency results in the sequel. 2.3 Regularized Bayesian inference Regularized Bayesian inference (RegBayes [14]) is based on a variational formulation of the Bayes’ rule [11]. The posterior distribution can be viewed as the solution of minp(Y |X=x) KL(p(Y |X = x)∥π(Y )) − R log p(X = x|Y )dp(Y |X = x), subjected to p(Y |X = x) ∈Pprob, where Pprob is the set of valid probability measures. RegBayes combines this formulation and posterior regularization [17] in the following way min p(Y |X=x),ξ KL(p(Y |X = x)∥π(Y )) − Z log p(X = x|Y )dp(Y |X = x) + U(ξ) s.t. p(Y |X = x) ∈Pprob(ξ), where Pprob(ξ) is a subset depending on ξ and U(ξ) is a loss function. Such a formulation makes it possible to regularize Bayesian posterior distributions, smoothing the gap between Bayesian generative models and discriminative models. Related applications include max-margin topic models [18] and infinite latent SVMs [14]. Despite the flexibility of RegBayes, regularization on the posterior distributions is practically imposed indirectly via expectations of a function. We shall see soon in the sequel that our new framework of kernel Regularized Bayesian inference can control the posterior distribution in a direct way. 2.4 Vector-valued regression The main task for vector-valued regression [12] is to minimize the following objective E(f) := n X i=1 ∥yj −f(xj)∥2 HY + λ ∥f∥2 HK , where yj ∈HY, f : X →HY. Note that f is a function with RKHS values and we assume that f belongs to a vector-valued RKHS HK. In vector-valued RKHS, the kernel function k is generalized to linear operators L(HY) ∋K(x1, x2) : HY →HY, such that K(x1, x2)y := (Kx2y)(x1) for every x1, x2 ∈X and y ∈HY, where Kx2y ∈HK. The reproducing property is generalized to ⟨y, f(x)⟩HY = ⟨Kxy, f⟩HK for every y ∈HY, f ∈HK and x ∈X. In addition, [12] shows that the representer theorem still holds for vector-valued RKHS. 3 Kernel Bayesian inference as a regression problem One of the unique merits of the posterior embedding µπ Y (X = x) is that expectations w.r.t. posterior distributions can be computed via inner products, i.e., ⟨h, µπ Y (X = x)⟩= Epπ(Y |X=x)[h(Y )] for all 3 h ∈HY. Since µπ Y (X = x) ∈HY, µπ Y can be viewed as an element of a vector-valued RKHS HK containing functions f : X →HY. A natural optimization objective [13] thus follows from the above observations E[µ] := sup ∥h∥Y≤1 EX (EY [h(Y )|X] −⟨h, µ(X)⟩HY)2 , (2) where EX[·] denotes the expectation w.r.t. pπ(X) and EY [·|X] denotes the expectation w.r.t. the Bayesian posterior distribution, i.e., pπ(Y | X) ∝π(Y )p(X | Y ). Clearly, µπ Y = arg infµ E[µ]. Following [13], we introduce an upper bound Es for E by applying Jensen’s and Cauchy-Schwarz’s inequalities consecutively Es[µ] := E(X,Y )[∥ψ(Y ) −µ(X)∥2 HY], (3) where (X, Y ) is the random variable on X ×Y with the joint distribution pπ(X, Y ) = π(Y )p(X | Y ). The first step to make this optimizational framework practical is to find finite sample estimators of Es[µ]. We will show how to do this in the following section. 3.1 A consistent estimator of Es[µ] Unlike the conditional embeddings in [13], we do not have i.i.d. samples from the joint distribution pπ(X, Y ), as the priors and likelihood functions are represented with samples from different distributions. We will eliminate this problem using a kernel trick, which is one of our main innovations in this paper. The idea is to use the inner product property of a kernel embedding µ(X,Y ) to represent the expectation E(X,Y )[∥ψ(Y ) −µ(X)∥2 HY] and then use finite sample estimators of µ(X,Y ) to estimate Es[µ]. Recall that we can identify CXY := EXY [φ(X) ⊗ψ(Y )] with µ(X,Y ) in a product space HX ⊗HY with a product kernel kX kY on X × Y [16]. Let f(x, y) = ∥ψ(y) −µ(x)∥2 HY and assume that f ∈HX ⊗HY. The optimization objective Es[µ] can be written as Es[µ] = E(X,Y )[∥ψ(Y ) −µ(X)∥2 HY] = ⟨f, µ(X,Y )⟩HX ⊗HY. (4) From Thm. 1, we assert that µ(X,Y ) = C(X,Y )Y C−1 Y Y πY and a natural estimator follows to be bµ(X,Y ) = bC(X,Y )Y ( bCY Y + λI)−1bπY . As a result, bEs[µ] := ⟨bµ(X,Y ), f⟩HX ⊗HY and we introduce the following proposition to write bEs in terms of Gram matrices. Proposition 1 (Proof in Appendix). Suppose (X, Y ) is a random variable in X × Y, where the prior for Y is π(Y ) and the likelihood is p(X | Y ). Let HX be a RKHS with kernel kX and feature map φ(x), HY be a RKHS with kernel kY and feature map ψ(y), φ(x, y) be the feature map of HX ⊗HY, bπY = Pl i=1 ˜αiψ(˜yi) be a consistent estimator of πY and {(xi, yi)}n i=1 be a sample representing p(X | Y ). Under the assumption that f(x, y) = ∥ψ(y) −µ(x)∥2 HY ∈HX ⊗HY, we have bEs[µ] = n X i=1 βi ∥ψ(yi) −µ(xi)∥2 HY , (5) where β = (β1, · · · , βn)⊺is given by β = (GY + nλI)−1 ˜GY ˜α, where (GY )ij = kY(yi, yj), ( ˜GY )ij = kY(yi, ˜yj), and ˜α = (˜α1, · · · , ˜αl)⊺. The consistency of bEs[µ] is a direct consequence of the following theorem adapted from [5], since the Cauchy-Schwarz inequality ensures |⟨µ(X,Y ), f⟩−⟨bµ(X,Y ), f⟩| ≤
µ(X,Y ) −bµ(X,Y )
∥f∥. Theorem 2 (Adapted from [5], Theorem 8). Assume that CY Y is injective, bπY is a consistent estimator of πY in HY norm, and that E[k((X, Y ), ( ˜X, ˜Y )) | Y = y, ˜Y = ˜y] is included in HY ⊗HY as a function of (y, ˜y), where ( ˜X, ˜Y ) is an independent copy of (X, Y ). Then, if the regularization coefficient λn decays to 0 sufficiently slowly,
bC(X,Y )Y ( bCY Y + λnI)−1bπY −µ(X,Y )
HX ⊗HY →0 (6) in probability as n →∞. 4 Although bEs[µ] is a consistent estimator of Es[µ], it does not necessarily have minima, since the coefficients βi can be negative. One of our main contributions in this paper is the discovery that we can ignore data points (xi, yi) with a negative βi, i.e., replacing βi with β+ i := max(0, βi) in bEs[µ]. We will give explanations and theoretical justifications in the next section. 3.2 The thresholding regularization We show in the following theorem that bE+ s [µ] := Pn i=1 β+ i ∥ψ(yi) −µ(xi)∥2 converges to Es[µ] in probability in discrete situations. The trick of replacing βi with β+ i is named thresholding regularization. Theorem 3 (Proof in Appendix). Assume that X is compact and |Y| < ∞, k is a strictly positive definite continuous kernel with sup(x,y) k((x, y), (x, y)) < κ and f(x, y) = ∥ψ(y) −µ(x)∥2 HY ∈ HX ⊗HY. With the conditions in Thm. 2, we assert that bµ+ (X,Y ) is a consistent estimator of µ(X,Y ) and bE+ s [µ] −Es[µ] →0 in probability as n →∞. In the context of partially observed Markov decision processes (POMDPs) [10], a similar thresholding approach, combined with normalization, was proposed to make the Bellman operator isotonic and contractive. However, the authors left the consistency of that approach as an open problem. The justification of normalization has been provided in [13], Lemma 2.2 under the finite space assumption. A slight modification of our proof of Thm. 3 (change the probability space from X × Y to X) can complete the other half as a side product, under the same assumptions. Compared to the original squared regularization used in [5], thresholding regularization is more computational efficient because 1) it does not need to multiply the Gram matrix twice, and 2) it does not need to take into consideration those data points with negative βi’s. In many cases a large portion of {βi}n i=1 is negative but the sum of their absolute values is small. The finite space assumption in Thm. 3 may also be weakened, but it requires deeper theoretical analyses. 3.3 Minimizing bE+ s [µ] Following the standard steps of solving a RKHS regression problem, we add a Tikhonov regularization term to bE+ s [µ] to provide a well-proposed problem, bEλ,n[µ] = n X i=1 β+ i ∥ψ(yi) −µ(xi)∥2 HY + λ ∥µ∥2 HK . (7) Let bµλ,n = arg minµ bEλ,n[µ]. Note that bEλ,n[µ] is a vector-valued regression problem, and the representer theorems in vector-valued RKHS apply here. We summarize the matrix expression of bµλ,n in the following proposition. Proposition 2 (Proof in Appendix). Without loss of generality, we assume that β+ i ̸= 0 for all 1 ≤i ≤n. Let µ ∈HK and choose the kernel of HK to be K(xi, xj) = kX (xi, xj)I, where I : HK →HK is an identity map. Then bµλ,n(x) = Ψ(KX + λnΛ+)−1K:x, (8) where Ψ = (ψ(y1), · · · , ψ(yn)), (KX)ij = kX (xi, xj), Λ+ = diag(1/β+ 1 , · · · , 1/β+ n ), K:x = (kX (x, x1), · · · , kX (x, xn))⊺and λn is a positive regularization constant. 3.4 Theoretical justifications for bµλ,n In this section, we provide theoretical explanations for using bµλ,n as an estimator of the posterior embedding under specific assumptions. Let µ∗= arg minµ E[µ], µ′ = arg minµ Es[µ], and recall that bµλ,n = arg minµ bEλ,n[µ]. We first show the relations between µ∗and µ′ and then discuss the relations between bµλ,n and µ′. The forms of E and Es are exactly the same for posterior kernel embeddings and conditional kernel embeddings. As a consequence, the following theorem in [13] still hold. 5 Theorem 4 ([13]). If there exists a µ∗∈HK such that for any h ∈HY, E[h|X] = ⟨h, µ∗(X)⟩HY pX-a.s., then µ∗is the pX-a.s. unique minimiser of both objectives: µ∗= arg min µ∈HK E[µ] = arg min µ∈HK Es[µ]. This theorem shows that if the vector-valued RKHS HK is rich enough to contain µπ Y |X=x, both E and Es can lead us to the correct embedding. In this case, it is reasonable to use µ′ instead of µ∗. For the situation where µπ Y |X=x ̸∈HK, we refer the readers to [13]. Unfortunately, we cannot obtain the relation between bµλ,n and µ′ by referring to [19], as in [13]. The main difficulty here is that {(xi, yi)}|n i=1 is not an i.i.d. sample from pπ(X, Y ) = π(Y )p(X | Y ) and the estimator bE+ s [µ] does not use i.i.d. samples to estimate expectations. Therefore the concentration inequality ([19], Prop. 2) used in the proofs of [19] cannot be applied. To solve the problem, we propose Thm. 9 (in Appendix) which can lead to a consistency proof for bµλ,n. The relation between bµλ,n and µ′ can now be summarized in the following theorem. Theorem 5 (Proof in Appendix). Assume Hypothesis 1 and Hypothesis 2 in [20] and our Assumption 1 (in the Appendix) hold. With the conditions in Thm. 3, we assert that if λn decreases to 0 sufficiently slowly, Es[bµλn,n] −Es[µ′] →0 (9) in probability as n →∞. 4 Kernel Bayesian inference with posterior regularization Based on our optimizational formulation of kernel Bayesian inference, we can add additional regularization terms to control the posterior embeddings. This technique gives us the possibility to incorporate rich side information from domain knowledge and to enforce supervisions on Bayesian inference. We call our framework of imposing posterior regularization kRegBayes. As an example of the framework, we study the following optimization problem L := m X i=1 β+ i ∥µ(xi) −ψ(yi)∥2 HY + λ ∥µ∥2 HK | {z } bEλ,n[µ] + δ n X i=m+1 ∥µ(xi) −ψ(ti)∥2 HY | {z } The regularization term , (10) where {(xi, yi)}m i=1 is the sample used for representing the likelihood, {(xi, ti)}n i=m+1 is the sample used for posterior regularization and λ, δ are the regularization constants. Note that in RKHS embeddings, ψ(t) is identified as a point distribution at t [2]. Hence the regularization term in (10) encourages the posterior distributions p(Y | X = xi) to be concentrated at ti. More complicated regularization terms are also possible, such as ∥µ(xi) −Pl i=1 αiψ(ti)∥HY. Compared to vanilla RegBayes, our kernel counterpart has several obvious advantages. First, the difference between two distributions can be naturally measured by RKHS norms. This makes it possible to regularize the posterior distribution as a whole, rather than through expectations of discriminant functions. Second, the framework of kernel Bayesian inference is totally nonparametric, where the priors and likelihood functions are all represented by respective samples. We will further demonstrate the properties of kRegBayes through experiments in the next section. Let bµreg = arg minµ L. It is clear that solving L is substantially the same as bEλ,n[µ] and we summarize it in the following proposition. Proposition 3. With the conditions in Prop. 2, we have bµreg(x) = Ψ(KX + λΛ+)−1K:x, (11) where Ψ = (ψ(y1), · · · , ψ(yn)), (KX)ij = kX (xi, xj)|1≤i,j≤n, Λ+ = diag(1/β+ 1 , · · · , 1/β+ m, 1/δ, · · · , 1/δ), and K:x = (kX (x, x1), · · · , kX (x, xn))⊺. 6 5 Experiments In this section, we compare the results of kRegBayes and several other baselines for two state-space filtering tasks. The mechanism behind kernel filtering is stated in [5] and we provide a detailed introduction in Appendix, including all the formula used in implementation. Toy dynamics This experiment is a twist of that used in [5]. We report the results of extended Kalman filter (EKF) [21] and unscented Kalman filter (UKF) [22], kernel Bayes’ rule (KBR) [5], kernel Bayesian learning with thresholding regularization (pKBR) and kRegBayes. The data points {(θt, xt, yt)} are generated from the dynamics θt+1 = θt + 0.4 + ξt (mod 2π), xt+1 yt+1 = (1 + sin(8θt+1)) cos θt+1 sin θt+1 + ζt, (12) where θt is the hidden state, (xt, yt) is the observation, ξt ∼N(0, 0.04) and ζt ∼N(0, 0.04). Note that this dynamics is nonlinear for both transition and observation functions. The observation model is an oscillation around the unit circle. There are 1000 training data and 200 validation/test data for each algorithm. Figure 1: Mean running MSEs against time steps for each algorithm. (Best view in color) We suppose that EKF, UKF and kRegBayes know the true dynamics of the model and the first hidden state θ1. In this case, we use ˜θt+1 = θ1 + 0.4t (mod 2π) and (˜xt+1, ˜yt+1)⊺= (1 + sin(8˜θt+1))(cos ˜θt+1, sin ˜θt+1)⊺as the supervision data point for the (t + 1)-th step. We follow [5] to set our parameters. The results are summarized in Fig. 5. pKBR has lower errors compared to KBR, which means the thresholding regularization is practically no worse than the original squared regularization. The lower MSE of kRegBayes compared with pKBR shows that the posterior regularization successfully incorporates information from equations of the dynamics. Moreover, pKBR and kRegBayes run faster than KBR. The total running times for 50 random datasets of pKBR, kRegBayes and KBR are respectively 601.3s, 677.5s and 3667.4s. Camera position recovery In this experiment, we build a scene containing a table and a chair, which is derived from classchair.pov (http://www.oyonale.com). With a fixed focal point, the position of the camera uniquely determines the view of the scene. The task of this experiment is to estimate the position of the camera given the image. This is a problem with practical applications in remote sensing and robotics. We vary the position of the camera in a plane with a fixed height. The transition equations of the hidden states are θt+1 = θt+0.2+ξθ, rt+1 = max(R2, min(R1, rt+ξr)), xt+1 = cos θt+1, yt+1 = sin θt+1, where ξθ ∼N(0, 4e −4), ξr ∼N(0, 1), 0 ≤R1 < R2 are two constants and {(xt, yt)}|m t=1 are treated as the hidden variables. As the observation at t-th step, we render a 100 × 100 image with the camera located at (xt, yt). For training data, we set R1 = 0 and R2 = 10 while for validation data and test data we set R1 = 5 and R2 = 7. The motivation is to distinguish the efficacy of enforcing the posterior distribution to concentrate around distance 6 by kRegBayes. We show a sample set of training and test images in Fig. 2. We compare KBR, pKBR and kRegBayes with the traditional linear Kalman filter (KF [23]). Following [4] we down-sample the images and train a linear regressor for observation model. In all experiments, we flatten the images to a column vector and apply Gaussian RBF kernels if needed. The kernel band widths are set to be the median distances in the training data. Based on experiments on the validation dataset, we set λT = 1e −6 = 2δT and µT = 1e −5. 7 Figure 2: First several frames of training data (upper row) and test data (lower row). (a) (b) Figure 3: (a) MSEs for different algorithms (best view in color). Since KF performs much worse than kernel filters, we use a different scale and plot it on the right y-axis. (b) Probability histograms for the distance between each state and the scene center. All algorithms use 100 training data. To provide supervision for kRegBayes, we uniformly generate 2000 data points {(ˆxi, ˆyt)}2000 i=1 on the circle r = 6. Given the previous estimate (˜xt, ˜yt), we first compute ˆθt = arctan(ˆyt/ˆxt) (where the value ˆθt is adapted according to the quadrant of (ˆxt, ˆyt)) and estimate (˘xt+1, ˘yt+1) = (cos(ˆθt + 0.4), sin(ˆθt + 0.4)). Next, we find the nearest point to (˘xt+1, ˘yt+1) in the supervision set (˜xk, ˜yk) and add the regularization µT ∥µ(It+1) −φ(˜xk, ˜yk)∥to the posterior embedding, where It+1 denotes the (t + 1)-th image. We vary the size of training dataset from 100 to 300 and report the results of KBR, pKBR, kRegBayes and KF on 200 test images in Fig. 3. KF performs much worse than all three kernel filters due to the extreme non-linearity. The result of pKBR is a little worse than that of KBR, but the gap decreases as the training dataset becomes larger. kRegBayes always performs the best. Note that the advantage becomes less obvious as more data come. This is because kernel methods can learn the distance relation better with more data, and posterior regularization tends to be more useful when data are not abundant and domain knowledge matters. Furthermore, Fig. 3(b) shows that the posterior regularization helps the distances to concentrate. 6 Conclusions We propose an optimizational framework for kernel Bayesian inference. With thresholding regularization, the minimizer of the framework is shown to be a reasonable estimator of the posterior kernel embedding. In addition, we propose a posterior regularized kernel Bayesian inference framework called kRegBayes. These frameworks are applied to non-linear state-space filtering tasks and the results of different algorithms are compared extensively. Acknowledgements We thank all the anonymous reviewers for valuable suggestions. The work was supported by the National Basic Research Program (973 Program) of China (No. 2013CB329403), National NSF of China Projects (Nos. 61620106010, 61322308, 61332007), the Youth Top-notch Talent Support Program, and Tsinghua Initiative Scientific Research Program (No. 20141080934). 8 References [1] Alex J Smola and Bernhard Schölkopf. Learning with kernels. Citeseer, 1998. [2] Alain Berlinet and Christine Thomas-Agnan. Reproducing kernel Hilbert spaces in probability and statistics. Springer Science & Business Media, 2011. [3] Alex Smola, Arthur Gretton, Le Song, and Bernhard Schölkopf. A hilbert space embedding for distributions. In Algorithmic learning theory, pages 13–31. Springer, 2007. [4] Le Song, Jonathan Huang, Alex Smola, and Kenji Fukumizu. Hilbert space embeddings of conditional distributions with applications to dynamical systems. In Proceedings of the 26th Annual International Conference on Machine Learning, pages 961–968. ACM, 2009. [5] Kenji Fukumizu, Le Song, and Arthur Gretton. Kernel bayes’ rule. In Advances in neural information processing systems, pages 1737–1745, 2011. [6] Le Song, Kenji Fukumizu, and Arthur Gretton. Kernel embeddings of conditional distributions: A unified kernel framework for nonparametric inference in graphical models. Signal Processing Magazine, IEEE, 30(4):98–111, 2013. [7] Le Song, Byron Boots, Sajid M Siddiqi, Geoffrey J Gordon, and Alex Smola. Hilbert space embeddings of hidden markov models. 2010. [8] Le Song, Arthur Gretton, and Carlos Guestrin. Nonparametric tree graphical models. In International Conference on Artificial Intelligence and Statistics, pages 765–772, 2010. [9] Steffen Grunewalder, Guy Lever, Luca Baldassarre, Massi Pontil, and Arthur Gretton. Modelling transition dynamics in mdps with rkhs embeddings. arXiv preprint arXiv:1206.4655, 2012. [10] Yu Nishiyama, Abdeslam Boularias, Arthur Gretton, and Kenji Fukumizu. Hilbert space embeddings of pomdps. arXiv preprint arXiv:1210.4887, 2012. [11] Peter M. Williams. Bayesian conditionalisation and the principle of minimum information. The British Journal for the Philosophy of Science, 31(2), 1980. [12] Charles A Micchelli and Massimiliano Pontil. On learning vector-valued functions. Neural computation, 17(1):177–204, 2005. [13] Steffen Grünewälder, Guy Lever, Luca Baldassarre, Sam Patterson, Arthur Gretton, and Massimiliano Pontil. Conditional mean embeddings as regressors. In Proceedings of the 29th International Conference on Machine Learning (ICML-12), pages 1823–1830, 2012. [14] Jun Zhu, Ning Chen, and Eric P Xing. Bayesian inference with posterior regularization and applications to infinite latent svms. The Journal of Machine Learning Research, 15(1):1799–1847, 2014. [15] Charles A Micchelli, Yuesheng Xu, and Haizhang Zhang. Universal kernels. The Journal of Machine Learning Research, 7:2651–2667, 2006. [16] Nachman Aronszajn. Theory of reproducing kernels. Transactions of the American mathematical society, 68(3):337–404, 1950. [17] Kuzman Ganchev, Joao Graça, Jennifer Gillenwater, and Ben Taskar. Posterior regularization for structured latent variable models. The Journal of Machine Learning Research, 11:2001–2049, 2010. [18] Jun Zhu, Amr Ahmed, and Eric Xing. MedLDA: Maximum margin supervised topic models. JMLR, 13:2237–2278, 2012. [19] Andrea Caponnetto and Ernesto De Vito. Optimal rates for the regularized least-squares algorithm. Foundations of Computational Mathematics, 7(3):331–368, 2007. [20] Ernesto De Vito and Andrea Caponnetto. Risk bounds for regularized least-squares algorithm with operator-value kernels. Technical report, DTIC Document, 2005. [21] Simon J Julier and Jeffrey K Uhlmann. New extension of the kalman filter to nonlinear systems. In AeroSense’97, pages 182–193. International Society for Optics and Photonics, 1997. [22] Eric A Wan and Ronell Van Der Merwe. The unscented kalman filter for nonlinear estimation. In Adaptive Systems for Signal Processing, Communications, and Control Symposium 2000. AS-SPCC. The IEEE 2000, pages 153–158. Ieee, 2000. [23] Rudolph Emil Kalman. A new approach to linear filtering and prediction problems. Journal of basic Engineering, 82(1):35–45, 1960. [24] Alexander J Smola and Risi Kondor. Kernels and regularization on graphs. In Learning theory and kernel machines, pages 144–158. Springer, 2003. [25] Heinz Werner Engl, Martin Hanke, and Andreas Neubauer. Regularization of inverse problems, volume 375. Springer Science & Business Media, 1996. 9 | 2016 | 508 |
6,448 | Scaled Least Squares Estimator for GLMs in Large-Scale Problems Murat A. Erdogdu Department of Statistics Stanford University erdogdu@stanford.edu Mohsen Bayati Graduate School of Business Stanford University bayati@stanford.edu Lee H. Dicker Department of Statistics and Biostatistics Rutgers University and Amazon ⇤ ldicker@stat.rutgers.edu Abstract We study the problem of efficiently estimating the coefficients of generalized linear models (GLMs) in the large-scale setting where the number of observations n is much larger than the number of predictors p, i.e. n ≫p ≫1. We show that in GLMs with random (not necessarily Gaussian) design, the GLM coefficients are approximately proportional to the corresponding ordinary least squares (OLS) coefficients. Using this relation, we design an algorithm that achieves the same accuracy as the maximum likelihood estimator (MLE) through iterations that attain up to a cubic convergence rate, and that are cheaper than any batch optimization algorithm by at least a factor of O(p). We provide theoretical guarantees for our algorithm, and analyze the convergence behavior in terms of data dimensions. Finally, we demonstrate the performance of our algorithm through extensive numerical studies on large-scale real and synthetic datasets, and show that it achieves the highest performance compared to several other widely used optimization algorithms. 1 Introduction We consider the problem of efficiently estimating the coefficients of generalized linear models (GLMs) when the number of observations n is much larger than the dimension of the coefficient vector p, (n ≫p ≫1). GLMs play a crucial role in numerous machine learning and statistics problems, and provide a miscellaneous framework for many regression and classification tasks. Celebrated examples include ordinary least squares, logistic regression, multinomial regression and many applications involving graphical models [MN89, WJ08, KF09]. The standard approach to estimating the regression coefficients in a GLM is the maximum likelihood method. Under standard assumptions on the link function, the maximum likelihood estimator (MLE) can be written as the solution to a convex minimization problem [MN89]. Due to the non-linear structure of the MLE problem, the resulting optimization task requires iterative methods. The most commonly used optimization technique for computing the MLE is the Newton-Raphson method, which may be viewed as a reweighted least squares algorithm [MN89]. This method uses a second order approximation to benefit from the curvature of the log-likelihood and achieves locally quadratic convergence. A drawback of this approach is its excessive per-iteration cost of O(np2). To remedy this, Hessian-free Krylov sub-space based methods such as conjugate gradient and minimal residual are used, but the resulting direction is imprecise [HS52, PS75, Mar10]. On the other hand, first order ⇤Work conducted while at Rutgers University 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. approximation yields the gradient descent algorithm, which attains a linear convergence rate with O(np) per-iteration cost. Although its convergence rate is slow compared to that of second order methods, its modest per-iteration cost makes it practical for large-scale problems. In the regime n ≫p, another popular optimization technique is the class of Quasi-Newton methods [Bis95, Nes04], which can attain a per-iteration cost of O(np), and the convergence rate is locally super-linear; a well-known member of this class of methods is the BFGS algorithm [Nes04]. There are recent studies that exploit the special structure of GLMs [Erd15], and achieve near-quadratic convergence with a per-iteration cost of O (np), and an additional cost of covariance estimation. In this paper, we take an alternative approach to fitting GLMs, based on an identity that is well-known in some areas of statistics, but appears to have received relatively little attention for its computational implications in large scale problems. Let βglm denote the GLM regression coefficients, and let βols denote the corresponding ordinary least squares (OLS) coefficients (this notation will be defined more precisely in Section 2). Then, under certain random predictor (design) models, βglm / βols. (1) For logistic regression with Gaussian design (which is equivalent to Fisher’s discriminant analysis), (1) was noted by Fisher in the 1930s [Fis36]; a more general formulation for models with Gaussian design is given in [Bri82]. The relationship (1) suggests that if the constant of proportionality is known, then βglm can be estimated by computing the OLS estimator, which may be substantially simpler than finding the MLE for the original GLM. Our work in this paper builds on this idea. Our contributions can be summarized as follows. 1. We show that βglm is approximately proportional to βols in random design GLMs, regardless of the predictor distribution. That is, we prove !!βglm −c ⇥βols!! 1 . 1 p, for some c 2 R. 2. We design a computationally efficient estimator for βglm by first estimating the OLS coefficients, and then estimating the proportionality constant c . We refer to the resulting estimator as the Scaled Least Squares (SLS) estimator and denote it by ˆβ sls. After estimating the OLS coefficients, the second step of our algorithm involves finding a root of a real valued function; this can be accomplished using iterative methods with up to a cubic convergence rate and only O(n) per-iteration cost. This is cheaper than the classical batch methods mentioned above by at least a factor of O(p). 3. For random design GLMs with sub-Gaussian predictors, we show that !!!ˆβ sls −βglm!!! 1 . 1 p + r p n/ max {log(n), p}. This bound characterizes the performance of the proposed estimator in terms of data dimensions, and justifies the use of the algorithm in the regime n ≫p ≫1. 4. We study the statistical and computational performance of ˆβ sls, and compare it to that of the MLE (using several well-known implementations), on a variety of large-scale datasets. The rest of the paper is organized as follows: Section 1.1 surveys the related work and Section 2 introduces the required background and the notation. In Section 3, we provide the intuition behind the relationship (1), which are based on exact calculations for GLMs with Gaussian design. In Section 4, we propose our algorithm and discuss its computational properties. Section 5 provides a thorough comparison between the proposed algorithm and other existing methods. Theoretical results may be found in Section 6. Finally, we conclude with a brief discussion in Section 7. 1.1 Related work As mentioned in Section 1, the relationship (1) is well-known in several forms in statistics. Brillinger [Bri82] derived (1) for models with Gaussian predictors. Li & Duan [LD89] studied model misspecification problems in statistics and derived (1) when the predictor distribution has linear conditional means (this is a slight generalization of Gaussian predictors). More recently, Stein’s lemma [BEM13] and the relationship (1) has been revisited in the context of compressed sensing [PV15, TAH15], where it has been shown that the standard lasso estimator may be very effective when used in models 2 where the relationship between the expected response and the signal is nonlinear, and the predictors (i.e. the design or sensing matrix) are Gaussian. A common theme for all of this previous work is that it focuses solely on settings where (1) holds exactly and the predictors are Gaussian (or, in [LD89], nearly Gaussian). Two key novelties of the present paper are (i) our focus on the computational benefits following from (1) for large scale problems with n ≫p ≫1; and (ii) our rigorous analysis of models with non-Gaussian predictors, where (1) is shown to be approximately valid. 2 Preliminaries and notation We assume a random design setting, where the observed data consists of n random iid pairs (y1, x1), (y2, x2), . . ., (yn, xn); yi 2 R is the response variable and xi = (xi1, . . . , xip)T 2 Rp is the vector of predictors or covariates. We focus on problems where fitting a GLM is desirable, but we do not need to assume that (yi, xi) are actually drawn from the corresponding statistical model (i.e. we allow for model misspecification). The MLE for GLMs with canonical link is defined by ˆβmle = argmax β2Rp 1 n n X i=1 yihxi, βi − (hxi, βi). (2) where h·, ·i denotes the Euclidean inner-product on Rp, and is a sufficiently smooth convex function. The GLM coefficients βglm are defined by taking the population average in (2): βglm = argmax β2Rp E [yihxi, βi − (hxi, βi)] . (3) While we make no assumptions on beyond smoothness, note that if is the cumulant generating function for yi | xi, then we recover the standard GLM with canonical link and regression parameters βglm [MN89]. Examples of GLMs in this form include logistic regression, with (w) = log{1+ew}; Poisson regression, with (w) = ew; and linear regression (least squares), with (w) = w2/2. Our objective is to find a computationally efficient estimator for βglm. The alternative estimator for βglm proposed in this paper is related to the OLS coefficient vector, which is defined by βols := E[xixT i ]−1E [xiyi]; the corresponding OLS estimator is ˆβols := (XT X)−1XT y, where X = (x1, . . . , xn)T is the n ⇥p design matrix and y = (y1, . . . , yn)T 2 Rn. Additionally, throughout the text we let [m]={1, 2, ..., m}, for positive integers m, and we denote the size of a set S by |S|. The m-th derivative of a function g : R ! R is denoted by g(m). For a vector u 2 Rp and a n ⇥p matrix U, we let kukq and kUkq denote the `q-vector and -operator norms, respectively. If S ✓[n], let US denote the |S| ⇥p matrix obtained from U by extracting the rows that are indexed by S. For a symmetric matrix M 2 Rp⇥p, λmax(M) and λmin(M) denote the maximum and minimum eigenvalues, respectively. ⇢k(M) denotes the condition number of M with respect to k-norm. We denote by Nq the q-variate normal distribution. 3 OLS is equivalent to GLM up to a scalar factor To motivate our methodology, we assume in this section that the covariates are multivariate normal, as in [Bri82]. These distributional assumptions will be relaxed in Section 6. Proposition 1. Assume that the covariates are multivariate normal with mean 0 and covariance matrix ⌃= E ⇥ xixT i ⇤ , i.e. xi ⇠Np(0, ⌃). Then βglm can be written as βglm = c ⇥βols, where c 2 R satisfies the equation 1 = c E ⇥ (2)(hx, βolsic ) ⇤ . Proof of Proposition 1. The optimal point in the optimization problem (3), has to satisfy the following normal equations, E [yixi] = E h xi (1)(hxi, βi) i . (4) Now, denote by φ(x | ⌃) the multivariate normal density with mean 0 and covariance matrix ⌃. We recall the well-known property of Gaussian density dφ(x | ⌃)/dx = −⌃−1xφ(x | ⌃). Using this 3 Algorithm 1 SLS: Scaled Least Squares Estimator Input: Data (yi, xi)n i=1 Step 1. Compute the least squares estimator: ˆβols and ˆy = Xˆβols. For a sub-sampling based OLS estimator, let S ⇢[n] be a random subset and take ˆβols = |S| n (XT SXS)−1XT y. Step 2. Solve the following equation for c 2 R: 1 = c n Pn i=1 (2)(c ˆyi). Use Newton’s root-finding method: Initialize c = 2/Var (yi); Repeat until convergence: c c − c 1 n Pn i=1 (2)(c ˆyi) −1 1 n Pn i=1 " (2)(c ˆyi) + c (3)(c ˆyi) . Output: ˆβ sls = c ⇥ˆβols. and integration by parts on the right hand side of the above equation, we obtain E h xi (1)(hxi, βi) i = Z x (1)(hx, βi)φ(x | ⌃) dx = ⌃βE h (2)(hxi, βi) i (5) (this is basically the Stein’s lemma). Combining this with the identity (4), we conclude the proof. Proposition 1 and its proof provide the main intuition behind our proposed method. Observe that in our derivation, we only worked with the right hand side of the normal equations (4) which does not depend on the response variable yi. The equivalence holds regardless of the joint distribution of (yi, xi), whereas in [Bri82], yi is assumed to follow a single index model. In Section 6, where we extend the method to non-Gaussian predictors, (5) is generalized via the zero-bias transformations. 3.1 Regularization A version of Proposition 1 incorporating regularization — an important tool for datasets where p is large relative to n or the predictors are highly collinear — is also possible, as outlined briefly in this section. We focus on `2-regularization (ridge regression) in this section; some connections with lasso (`1-regularization) are discussed in Section 6 and Corollary 1. For λ ≥0, define the `2-regularized GLM coefficients, βglm λ = argmax β2Rp E [yihxi, βi − (hxi, βi)] −λ 2 kβk2 2 (6) and the corresponding `2-regularized OLS coefficients βols λ = ' E ⇥ xixT i ⇤ + λI *−1 E [xiyi] (so βglm = βglm 0 and βols = βols 0 ). The same argument as above implies that βglm λ = c ⇥βols γ , where γ = λc . (7) This suggests that the ordinary ridge regression for the linear model can be used to estimate the `2-regularized GLM coefficients βglm λ . Further pursuing these ideas for problems where regularization is a critical issue may be an interesting area for future research. 4 SLS: Scaled Least Squares estimator for GLMs Motivated by the results in the previous section, we design a computationally efficient algorithm for any GLM task that is as simple as solving the least squares problem; it is described in Algorithm 1. The algorithm has two basic steps. First, we estimate the OLS coefficients, and then in the second step we estimate the proportionality constant via a simple root-finding algorithm. There are numerous fast optimization methods to solve the least squares problem, and even a superficial review of these could go beyond the page limits of this paper. We emphasize that this step (finding the OLS estimator) does not have to be iterative and it is the main computational cost of the proposed algorithm. We suggest using a sub-sampling based estimator for βols, where we only use a subset of the observations to estimate the covariance matrix. Let S ⇢[n] be a 4 0 20 40 60 4 5 6 log10(n) Time(sec) Method SLS MLE SLS vs MLE : Computation 0.0 0.3 0.6 0.9 1.2 4 5 6 log10(n) |β^ −β|2 Method SLS MLE SLS vs MLE : Accuracy Figure 1: Logistic regression with general Gaussian design. The left plot shows the computational cost (time) for finding the MLE and SLS as n grows and p = 200. The right plot depicts the accuracy of the estimators. In the regime where the MLE is expensive to compute, the SLS is found much more rapidly and has the same accuracy. R’s built-in functions are used to find the MLE. random sub-sample and denote by XS the sub-matrix formed by the rows of X in S. Then the sub-sampled OLS estimator is given as ˆβols = ! 1 |S|XT SXS "−1 1 nXT y. Properties of this estimator have been well-studied [Ver10, DLFU13, EM15]. For sub-Gaussian covariates, it suffices to use a sub-sample size of O (p log(p)) [Ver10]. Hence, this step requires a single time computational cost of O ! |S|p2 + p3 + np " ⇡O ! p max{p2 log(p), n} " . For other approaches, we refer reader to [RT08, DLFU13] and the references therein. The second step of Algorithm 1 involves solving a simple root-finding problem. As with the first step of the algorithm, there are numerous methods available for completing this task. Newton’s root-finding method with quadratic convergence or Halley’s method with cubic convergence may be appropriate choices. We highlight that this step costs only O (n) per-iteration and that we can attain up to a cubic rate of convergence. The resulting per-iteration cost is cheaper than other commonly used batch algorithms by at least a factor of O (p) — indeed, the cost of computing the gradient is O (np). For simplicity, we use Newton’s root-finding method initialized at c = 2/Var (yi). Assuming that the GLM is a good approximation to the true conditional distribution, by the law of total variance and basic properties of GLMs, we have Var (yi) = E [Var (yi | xi)] + Var (E [yi | xi]) ⇡c−1 + Var ! (1)(hxi, βi) " . (8) It follows that this initialization is reasonable as long as c−1 ⇡E [Var (yi | xi)] is not much smaller than Var ! (1)(hxi, βi) " . Our experiments show that SLS is very robust to initialization. In Figure 1, we compare the performance of our SLS estimator to that of the MLE, when both are used to analyze synthetic data generated from a logistic regression model under general Gaussian design with randomly generated covariance matrix. The left plot shows the computational cost of obtaining both estimators as n increases for fixed p. The right plot shows the accuracy of the estimators. In the regime n ≫p ≫1 — where the MLE is hard to compute — the MLE and the SLS achieve the same accuracy, yet SLS has significantly smaller computation time. We refer the reader to Section 6 for theoretical results characterizing the finite sample behavior of the SLS. 5 Experiments This section contains the results of a variety of numerical studies, which show that the Scaled Least Squares estimator reaches the minimum achievable test error substantially faster than commonly used batch algorithms for finding the MLE. Both logistic and Poisson regression models (two types of GLMs) are utilized in our analyses, which are based on several synthetic and real datasets. Below, we briefly describe the optimization algorithms for the MLE that were used in the experiments. 1. Newton-Raphson (NR) achieves locally quadratic convergence by scaling the gradient by the inverse of the Hessian evaluated at the current iterate. Computing the Hessian has a per-iteration cost of O ! np2" , which makes it impractical for large-scale datasets. 2. Newton-Stein (NS) is a recently proposed second-order batch algorithm specifically designed for GLMs [Erd16]. The algorithm uses Stein’s lemma and sub-sampling to efficiently estimate the Hessian with O (np) per-iteration cost, achieving near quadratic rates. 5 Random start OLS start Logis0c Regression Poisson Regression (a) (b) (c) (e) (g) (d) (f) (h) 0.2 0.3 0.4 0.5 0 10 20 30 40 50 Time (sec) Test Error SLS NR NS BFGS LBFGS GD AGD Log−Reg / Covariates ~ Σ x {Exp(1)−1} 0.22 0.24 0.26 0.28 0.30 0 10 20 30 40 50 Time (sec) Test Error SLS NR NS BFGS LBFGS GD AGD Log−Reg / Higgs dataset 0.23 0.24 0.25 0 10 20 30 40 Time (sec) Test Error SLS NR NS BFGS LBFGS GD AGD Log−Reg / Higgs dataset 0.18 0.20 0.22 0.24 0 5 10 15 20 Time (sec) Test Error SLS NR NS BFGS LBFGS GD AGD Log−Reg / Covariates ~ Σ x {Exp(1)−1} 0.5 1.0 1.5 2.0 0 10 20 30 40 Time (sec) log(Test Error) SLS NR NS BFGS LBFGS GD AGD Poi−Reg / Covariates ~ Σ x Ber( ± 1) 0.5 1.0 1.5 2.0 2.5 0 10 20 30 40 Time (sec) log(Test Error) SLS NR NS BFGS LBFGS GD AGD Poi−Reg / Covariates ~ Σ x Ber( ± 1) 0 5 10 15 0.0 2.5 5.0 7.5 10.0 Time (sec) log(Test Error) SLS NR NS BFGS LBFGS GD AGD Poi−Reg / Covertype dataset 0.5 1.0 1.5 2.0 0.0 2.5 5.0 7.5 10.0 Time (sec) log(Test Error) SLS NR NS BFGS LBFGS GD AGD Poi−Reg / Covertype dataset Figure 2: Performance of SLS compared to that of MLE obtained with various optimization algorithms on several datasets. SLS is represented with red straight line. The details are provided in Table 1. 3. Broyden-Fletcher-Goldfarb-Shanno (BFGS) is the most popular and stable quasi-Newton method [Nes04]. At each iteration, the gradient is scaled by a matrix that is formed by accumulating information from previous iterations and gradient computations. The convergence is locally super-linear with a per-iteration cost of O (np). 4. Limited memory BFGS (LBFGS) is a variant of BFGS, which uses only the recent iterates and gradients to approximate the Hessian, providing significant improvement in terms of memory usage. LBFGS has many variants; we use the formulation given in [Bis95]. 5. Gradient descent (GD) takes a step in the opposite direction of the gradient, evaluated at the current iterate. Its performance strongly depends on the condition number of the design matrix. Under certain assumptions, the convergence is linear with O (np) per-iteration cost. 6. Accelerated gradient descent (AGD) is a modified version of gradient descent with an additional “momentum” term [Nes83]. Its per iteration cost is O (np) and its performance strongly depends on the smoothness of the objective function. For all the algorithms, the step size at each iteration is chosen via the backtracking line search [BV04]. Recall that the proposed Algorithm 1 is composed of two steps; the first finds an estimate of the OLS coefficients. This up-front computation is not needed for any of the MLE algorithms described above. On the other hand, each of the MLE algorithms requires some initial value for β, but no such initialization is needed to find the OLS estimator in Algorithm 1. This raises the question of how the MLE algorithms should be initialized, in order to compare them fairly with the proposed method. We consider two scenarios in our experiments: first, we use the OLS estimator computed for Algorithm 1 to initialize the MLE algorithms; second, we use a random initial value. On each dataset, the main criterion for assessing the performance of the estimators is how rapidly the minimum test error is achieved. The test error is measured as the mean squared error of the estimated mean using the current parameters at each iteration on a test dataset, which is a randomly selected (and set-aside) 10% portion of the entire dataset. As noted previously, the MLE is more accurate for small n (see Figure 1). However, in the regime considered here (n ≫p ≫1), the MLE and the SLS perform very similarly in terms of their error rates; for instance, on the Higgs dataset, the SLS and MLE have test error rates of 22.40% and 22.38%, respectively. For each dataset, the minimum achievable test error is set to be the maximum of the final test errors, where the maximum is taken over all of the estimation methods. Let ⌃(1) and ⌃(2) be two randomly generated covariance matrices. The datasets we analyzed were: (i) a synthetic dataset generated from a logistic regression model with iid {exponential(1)−1} predictors scaled by ⌃(1); (ii) the Higgs dataset (logistic regression) [BSW14]; (iii) a synthetic dataset generated from a Poisson regression model with iid binary(±1) predictors scaled by ⌃(2); (iv) the Covertype dataset (Poisson regression) [BD99]. In all cases, the SLS outperformed the alternative algorithms for finding the MLE by a large margin, in terms of computation. Detailed results may be found in Figure 2 and Table 1. We provide additional experiments with different datasets in the Supplementary Material. 6 Table 1: Details of the experiments shown in Figure 2. MODEL LOGISTIC REGRESSION POISSON REGRESSION DATASET ⌃⇥{EXP(1)-1} HIGGS [BSW14] ⌃⇥BER(±1) COVERTYPE [BD99] SIZE n = 6.0 ⇥105, p = 300 n = 1.1⇥107, p = 29 n = 6.0⇥105, p = 300 n = 5.8⇥105, p = 53 INITIALIZED RND OLS RND OLS RND OLS RND OLS PLOT (A) (B) (C) (D) (E) (F) (G) (H) METHOD TIME IN SECONDS / NUMBER OF ITERATIONS (TO REACH MIN TEST ERROR) SLS 8.34/4 2.94/3 13.18/3 9.57/3 5.42/5 3.96/5 2.71/6 1.66/20 NR 301.06/6 82.57/3 37.77/3 36.37/3 170.28/5 130.1/4 16.7/8 32.48/18 NS 51.69/8 7.8/3 27.11/4 26.69/4 32.71/5 36.82/4 21.17/10 282.1/216 BFGS 148.43/31 24.79/8 660.92/68 701.9/68 67.24/29 72.42/26 5.12/7 22.74/59 LBFGS 125.33/39 24.61/8 6368.1/651 6946.1/670 224.6/106 357.1/88 10.01/14 10.05/17 GD 669/138 134.91/25 100871/10101 141736/13808 1711/513 1364/374 14.35/25 33.58/87 AGD 218.1/61 35.97/12 2405.5/251 2879.69/277 103.3/51 102.74/40 11.28/15 11.95/25 6 Theoretical results In this section, we use the zero-bias transformations [GR97] to generalize the equivalence between OLS and GLMs to settings where the covariates are non-Gaussian. Definition 1. Let z be a random variable with mean 0 and variance σ2. Then, there exists a random variable z⇤that satisfies E [zf(z)] = σ2E[f (1)(z⇤)], for all differentiable functions f. The distribution of z⇤is said to be the z-zero-bias distribution. The existence of z⇤in Definition 1 is a consequence of Riesz representation theorem [GR97]. The normal distribution is the unique distribution whose zero-bias transformation is itself (i.e. the normal distribution is a fixed point of the operation mapping the distribution of z to that of z⇤). To provide some intuition behind the usefulness of the zero-bias transformation, we refer back to the proof of Proposition 1. For simplicity, assume that the covariate vector xi has iid entries with mean 0, and variance 1. Then the zero-bias transformation applied to the j-th normal equation in (4) yields E [yixij] = E h xij (1)" xijβj + ⌃k6=jxikβk #i | {z } j-th normal equation = βjE h (2) " x⇤ ijβj + ⌃k6=jxikβik #i | {z } Zero-bias transformation . (9) The distribution of x⇤ ij is the xij-zero-bias distribution and is entirely determined by the distribution of xij; general properties of x⇤ ij can be found, for example, in [CGS10]. If β is well spread, it turns out that taken together, with j = 1, . . . , p, the far right-hand side in (9) behaves similar to the right side of (5), with ⌃= I; that is, the behavior is similar to the Gaussian case, where the proportionality relationship given in Proposition 1 holds. This argument leads to an approximate proportionality relationship for non-Gaussian predictors, which, when carried out rigorously, yields the following. Theorem 1. Suppose that the covariate vector xi has mean 0 and covariance matrix ⌃and, furthermore, that the random vector ⌃−1/2xi has independent entries and its sub-Gaussian norm is bounded by . Assume that the function (2) is Lipschitz continuous with constant k. Let kβk2 = ⌧ and assume β is r-well-spread in the sense that ⌧/ kβk1 = rpp for some r 2 (0, 1]. Then, for c = 1/E ⇥ (2)(hxi, βglmi) ⇤ , and ⇢= ⇢1(⌃1/2) denoting the condition number of ⌃1/2, we have ++++ 1 c ⇥βglm −βols ++++ 1 ⌘ p, where ⌘= 8k3⇢k⌃1/2k1(⌧/r)2. (10) Theorem 1 is proved in the Supplementary Material. It implies that the population parameters βols and βglm are approximately equivalent up to a scaling factor, with an error bound of O (1/p). The assumption that βglm is well-spread can be relaxed with minor modifications. For example, if we have a sparse coefficient vector, where supp(βglm) = {j; βglm j 6= 0} is the support set of βglm, then Theorem 1 holds with p replaced by the size of the support set. An interesting consequence of Theorem 1 and the remarks following the theorem is that whenever an entry of βglm is zero, the corresponding entry of βols has to be small, and conversely. For λ ≥0, define the lasso coefficients βlasso λ = argmin β2Rp 1 2E ⇥ (yi −hxi, βi)2⇤ + λ kβk1 . (11) 7 Corollary 1. For any λ ≥⌘/|supp(βglm)|, if E [xi] = 0 and E ⇥ xixT i ⇤ = I, we have supp(βlasso) ⇢supp(βglm). Further, if λ and βglm also satisfy that 8j 2 supp(βglm), |βglm j | > c # λ + ⌘/|supp(βglm)| $ , then we have supp(βlasso) = supp(βglm). So far in this section, we have only discussed properties of the population parameters, such as βglm. In the remainder of this section, we turn our attention to results for the estimators that are the main focus of this paper; these results ultimately build on our earlier results, i.e. Theorem 1. In order to precisely describe the performance of ˆβ sls, we first need bounds on the OLS estimator. The OLS estimator has been studied extensively in the literature; however, for our purposes, we find it convenient to derive a new bound on its accuracy. While we have not seen this exact bound elsewhere, it is very similar to Theorem 5 of [DLFU13]. Proposition 2. Assume that E [xi] = 0, E ⇥ xixT i ⇤ = ⌃, and that ⌃−1/2xi and yi are sub-Gaussian with norms and γ, respectively. For λmin denoting the smallest eigenvalue of ⌃, and |S| > ⌘p, %%%ˆβols −βols%%% 2 ⌘λ −1/2 min r p |S|, (12) with probability at least 1 −3e−p, where ⌘depends only on γ and . Proposition 2 is proved in the Supplementary Material. Our main result on the performance of ˆβ sls is given next. Theorem 2. Let the assumptions of Theorem 1 and Proposition 2 hold with E[k⌃−1/2xk2] = ˜µpp. Further assume that the function f(z) = zE ⇥ (2)(hx, βolsiz) ⇤ satisfies f(¯c) > 1 + ¯δpp for some ¯c and ¯δ such that the derivative of f in the interval [0, ¯c] does not change sign, i.e., its absolute value is lower bounded by υ > 0. Then, for n and |S| sufficiently large, we have %%%ˆβ sls −βglm%%% 1 ⌘1 1 p + ⌘2 r p min {n/ log(n), |S|/p}, (13) with probability at least 1 −5e−p, where the constants ⌘1 and ⌘2 are defined by ⌘1 =⌘k¯c3⇢k⌃1/2k1(⌧/r)2 (14) ⌘2 =⌘¯cλ−1/2 min ⇣ 1 + υ−1λ1/2 min kβolsk1 max {(b + k/˜µ), k¯c} ⌘ , (15) and ⌘> 0 is a constant depending on and γ. Note that the convergence rate of the upper bound in (13) depends on the sum of the two terms, both of which are functions of the data dimensions n and p. The first term on the right in (13) comes from Theorem 1, which bounds the discrepancy between c ⇥βols and βglm. This term is small when p is large, and it does not depend on the number of observations n. The second term in the upper bound (13) comes from estimating βols and c . This term is increasing in p, which reflects the fact that estimating βglm is more challenging when p is large. As expected, this term is decreasing in n and |S|, i.e. larger sample size yields better estimates. When the full OLS solution is used (|S| = n), the second term becomes O( p p max{log(n), p}/n) = O(p/pn), for p sufficiently large. This suggests that n should be at least of order p2 for good performance. 7 Discussion In this paper, we showed that the coefficients of GLMs and OLS are approximately proportional in the general random design setting. Using this relation, we proposed a computationally efficient algorithm for large-scale problems that achieves the same accuracy as the MLE by first estimating the OLS coefficients and then estimating the proportionality constant through iterations that can attain quadratic or cubic convergence rate, with only O (n) per-iteration cost. We briefly mentioned that the proportionality between the coefficients holds even when there is regularization in Section 3.1. Further pursuing this idea may be interesting for large-scale problems where regularization is crucial. Another interesting line of research is to find similar proportionality relations between the parameters in other large-scale optimization problems such as support vector machines. Such relations may reduce the problem complexity significantly. 8 References [BD99] J. A. Blackard and D. J. Dean, Comparative accuracies of artificial neural networks and discriminant analysis in predicting forest cover types from cartographic variables, Comput. Electron. Agr. 24 (1999), 131–151. [BEM13] M. Bayati, M. A. Erdogdu, and A. Montanari, Estimating lasso risk and noise level, NIPS 26, 2013, pp. 944–952. [Bis95] C. M. Bishop, Neural Networks for Pattern Recognition, Oxford University Press, 1995. [Bri82] D. R Brillinger, A generalized linear model with "Gaussian" regressor variables, A Festschrift For Erich L. Lehmann, CRC Press, 1982, pp. 97–114. [BSW14] P. Baldi, P. Sadowski, and D. Whiteson, Searching for exotic particles in high-energy physics with deep learning, Nat. Commun. 5 (2014), 4308–4308. [BV04] S. Boyd and L. Vandenberghe, Convex Optimization, Cambridge University Press, 2004. [CGS10] L. H. Y. Chen, L. Goldstein, and Q.-M. Shao, Normal approximation by Stein’s method, Springer, 2010. [DLFU13] P. Dhillon, Y. Lu, D. P. Foster, and L. Ungar, New subsampling algorithms for fast least squares regression, NIPS 26 (2013), 360–368. [EM15] M. A. Erdogdu and A. Montanari, Convergence rates of sub-sampled newton methods, NIPS 28, 2015, pp. 3034–3042. [Erd15] M. A. Erdogdu, Newton-Stein method: A second order method for GLMs via Stein’s lemma, NIPS 28 (2015), 1216–1224. [Erd16] , Newton-Stein Method: An optimization method for GLMs via Stein’s Lemma, Journal of Machine Learning Research (to appear) (2016). [Fis36] R. A. Fisher, The use of multiple measurements in taxonomic problems, Ann. Eugenic 7 (1936), 179–188. [Gol07] L. Goldstein, l1 bounds in normal approximation, Ann. Probab. 35 (2007), 1888–1930. [GR97] L. Goldstein and G. Reinert, Stein’s method and the zero bias transformation with application to simple random sampling, Ann. Appl. Probab. 7 (1997), 935–952. [HS52] M. R. Hestenes and E. Stiefel, Methods of conjugate gradients for solving linear systems, J. Res. Nat. Bur. Stand. 49 (1952), 409–436. [KF09] D. Koller and N. Friedman, Probabilistic Graphical Models: Principles and Techniques, MIT press, 2009. [LD89] K.-C. Li and N. Duan, Regression analysis under link violation, Ann. Stat. 17 (1989), 1009–1052. [Mar10] J. Martens, Deep learning via Hessian-free optimization, ICML 27 (2010), 735–742. [MN89] P. McCullagh and J. A. Nelder, Generalized Linear Models, 2nd ed., Chapman and Hall, 1989. [Nes83] Y. Nesterov, A method of solving a convex programming problem with convergence rate O(1/k2), Soviet Math. Dokl. 27 (1983), 372–376. [Nes04] , Introductory Lectures on Convex Optimization: A Basic Course, Springer, 2004. [PS75] C. C. Paige and M. A. Saunders, Solution of sparse indefinite systems of linear equations, SIAM J. Numer. Anal. 12 (1975), 617–629. [PV15] Y. Plan and R. Vershynin, The generalized lasso with non-linear observations, 2015, arXiv preprint arXiv:1502.04071. [RT08] V. Rokhlin and M. Tygert, A fast randomized algorithm for overdetermined linear least-squares regression, P. Natl. Acad. Sci. 105 (2008), 13212–13217. [TAH15] C. Thrampoulidis, E. Abbasi, and B. Hassibi, Lasso with non-linear measurements is equivalent to one with linear measurements, NIPS 28 (2015), 3402–3410. [Ver10] R. Vershynin, Introduction to the non-asymptotic analysis of random matrices, 2010, arXiv:1011.3027. [WJ08] M. J. Wainwright and M. I. Jordan, Graphical models, exponential families, and variational inference, Foundations and Trends in Machine Learning 1 (2008), 1–305. 9 | 2016 | 509 |
6,449 | Exponential expressivity in deep neural networks through transient chaos Ben Poole1, Subhaneil Lahiri1, Maithra Raghu2, Jascha Sohl-Dickstein2, Surya Ganguli1 1Stanford University, 2Google Brain {benpoole,sulahiri,sganguli}@stanford.edu, {maithra,jaschasd}@google.com Abstract We combine Riemannian geometry with the mean field theory of high dimensional chaos to study the nature of signal propagation in generic, deep neural networks with random weights. Our results reveal an order-to-chaos expressivity phase transition, with networks in the chaotic phase computing nonlinear functions whose global curvature grows exponentially with depth but not width. We prove this generic class of deep random functions cannot be efficiently computed by any shallow network, going beyond prior work restricted to the analysis of single functions. Moreover, we formalize and quantitatively demonstrate the long conjectured idea that deep networks can disentangle highly curved manifolds in input space into flat manifolds in hidden space. Our theoretical analysis of the expressive power of deep networks broadly applies to arbitrary nonlinearities, and provides a quantitative underpinning for previously abstract notions about the geometry of deep functions. 1 Introduction Deep feedforward neural networks have achieved remarkable performance across many domains [1–6]. A key factor thought to underlie their success is their high expressivity. This informal notion has manifested itself primarily in two forms of intuition. The first is that deep networks can compactly express highly complex functions over input space in a way that shallow networks with one hidden layer and the same number of neurons cannot. The second piece of intuition, which has captured the imagination of machine learning [7] and neuroscience [8] alike, is that deep neural networks can disentangle highly curved manifolds in input space into flattened manifolds in hidden space. These intuitions, while attractive, have been difficult to formalize mathematically and thus test rigorously. For the first intuition, seminal works have exhibited examples of particular functions that can be computed with a polynomial number of neurons (in the input dimension) in a deep network but require an exponential number of neurons in a shallow network [9–13]. This raises a central open question: are such functions merely rare curiosities, or is any function computed by a generic deep network not efficiently computable by a shallow network? The theoretical techniques employed in prior work both limited the applicability of theory to specific nonlinearities and dictated the particular measure of deep functional complexity involved. For example, [9] focused on ReLU nonlinearities and number of linear regions as a complexity measure, while [10] focused on sum-product networks and the number of monomials as complexity measure, and [14] focused on Pfaffian nonlinearities and topological measures of complexity, like the sum of Betti numbers of a decision boundary (however, see [15] for an interesting analysis of a general class of compositional functions). The limits of prior theoretical techniques raise another central question: is there a unifying theoretical framework for deep neural expressivity that is simultaneously applicable to arbitrary nonlinearities, generic networks, and a natural, general measure of functional complexity? Code to reproduce all results available at: https://github.com/ganguli-lab/deepchaos 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. Here we attack both central problems of deep neural expressivity by combining Riemannian geometry [16] and dynamical mean field theory [17]. This novel combination of tools enables us to show that for very broad classes of nonlinearities, even random deep neural networks can construct hidden internal representations whose global extrinsic curvature grows exponentially with depth but not width. Our geometric framework enables us to quantitatively define a notion of disentangling and verify this notion in deep random networks. Furthermore, our methods yield insights into the emergent, deterministic nature of signal propagation through large random feedforward networks, revealing the existence of an order to chaos transition as a function of the statistics of weights and biases. We find that the transient, finite depth evolution in the chaotic regime underlies the origins of exponential expressivity in deep random networks. In a companion paper [18], we study several related measures of expressivity in deep random neural networks with piecewise linear activations. 2 A mean field theory of deep nonlinear signal propagation Consider a deep feedforward network with D layers of weights W1, . . . , WD and D + 1 layers of neural activity vectors x0, . . . , xD, with Nl neurons in each layer l, so that xl ∈RNl and Wl is an Nl × Nl−1 weight matrix. The feedforward dynamics elicited by an input x0 is given by xl = φ(hl) hl = Wl xl−1 + bl for l = 1, . . . , D, (1) where bl is a vector of biases, hl is the pattern of inputs to neurons at layer l, and φ is a single neuron scalar nonlinearity that acts component-wise to transform inputs hl to activities xl. We wish to understand the nature of typical functions computable by such networks, as a consequence of their depth. We therefore study ensembles of random networks in which each of the synaptic weights Wl ij are drawn i.i.d. from a zero mean Gaussian with variance σ2 w/Nl−1, while the biases are drawn i.i.d. from a zero mean Gaussian with variance σ2 b. This weight scaling ensures that the input contribution to each individual neuron at layer l from activities in layer l −1 remains O(1), independent of the layer width Nl−1. This ensemble constitutes a maximum entropy distribution over deep neural networks, subject to constraints on the means and variances of weights and biases. This ensemble induces no further structure in the resulting set of deep functions, so its analysis provides an opportunity to understand the specific contribution of depth alone to the nature of typical functions computed by deep networks. In the limit of large layer widths, Nl ≫1, certain aspects of signal propagation through deep random neural networks take on an essentially deterministic character. This emergent determinism in large random neural networks enables us to understand how the Riemannian geometry of simple manifolds in the input layer x0 is typically modified as the manifold propagates into the deep layers. For example, consider the simplest case of a single input vector x0. As it propagates through the network, its length in downstream layers will change. We track this changing length by computing the normalized squared length of the input vector at each layer: ql = 1 Nl Nl X i=1 (hl i)2. (2) This length is the second moment of the empirical distribution of inputs hl i across all Nl neurons in layer l. For large Nl, this empirical distribution converges to a zero mean Gaussian since each hl i = P j Wl ijφ(hl−1 j ) + bl i is a weighted sum of a large number of uncorrelated random variables - i.e. the weights Wl ij and biases bl i, which are independent of the activity in previous layers. By propagating this Gaussian distribution across one layer, we obtain an iterative map for ql in (2): ql = V(ql−1 | σw, σb) ≡σ2 w Z Dz φ p ql−1z 2 + σ2 b, for l = 2, . . . , D, (3) where Dz = dz √ 2πe−z2 2 is the standard Gaussian measure, and the initial condition is q1 = σ2 wq0 +σ2 b, where q0 = 1 N0 x0 · x0 is the length in the initial activity layer. See Supplementary Material (SM) for a derivation of (3). Intuitively, the integral over z in (3) replaces an average over the empirical distribution of hl i across neurons i in layer l at large layer width Nl. The function V in (3) is an iterative variance, or length, map that predicts how the length of an input in (2) changes as it propagates through the network. This length map is plotted in Fig. 1A for the special 2 Figure 1: Dynamics of the squared length ql for a sigmoidal network (φ(h) = tanh(h)) with 1000 hidden units. (A) The iterative length map in (3) for 3 different σw at σb = 0.3. Theoretical predictions (solid lines) match well with individual network simulations (dots). Stars reflect fixed points q∗of the map. (B) The iterative dynamics of the length map yields rapid convergence of ql to its fixed point q∗, independent of initial condition (lines=theory; dots=simulation). (C) q∗as a function of σw and σb. (D) Number of iterations required to achieve ≤1% fractional deviation off the fixed point. The (σb, σw) pairs in (A,B) are marked with color matched circles in (C,D). case of a sigmoidal nonlinearity, φ(h) = tanh(h). For monotonic nonlinearities, this length map is a monotonically increasing, concave function whose intersections with the unity line determine its fixed points q∗(σw, σb). For σb = 0 and σw < 1, the only intersection is at q∗= 0. In this bias-free, small weight regime, the network shrinks all inputs to the origin. For σw > 1 and σb = 0, the q∗= 0 fixed point becomes unstable and the length map acquires a second nonzero fixed point, which is stable. In this bias-free, large weight regime, the network expands small inputs and contracts large inputs. Also, for any nonzero bias σb, the length map has a single stable non-zero fixed point. In such a regime, even with small weights, the injected biases at each layer prevent signals from decaying to 0. The dynamics of the length map leads to rapid convergence of length to its fixed point with depth (Fig. 1B,D), often within only 4 layers. The fixed points q∗(σw, σb) are shown in Fig. 1C. 3 Transient chaos in deep networks Now consider the layer-wise propagation of two inputs x0,1 and x0,2. The geometry of these two inputs as they propagate through the network is captured by the 2 by 2 matrix of inner products: ql ab = 1 Nl Nl X i=1 hl i(x0,a) hl i(x0,b) a, b ∈{1, 2}. (4) The dynamics of the two diagonal terms are each theoretically predicted by the length map in (3). We derive (see SM) a correlation map C that predicts the layer-wise dynamics of ql 12: ql 12 = C(cl−1 12 , ql−1 11 , ql−1 22 | σw, σb) ≡σ2 w Z Dz1 Dz2 φ (u1) φ (u2) + σ2 b, (5) u1 = q ql−1 11 z1, u2 = q ql−1 22 cl−1 12 z1 + q 1 −(cl−1 12 )2z2 , where cl 12 = ql 12(ql 11ql 22)−1/2 is the correlation coefficient. Here z1 and z2 are independent standard Gaussian variables, while u1 and u2 are correlated Gaussian variables with covariance matrix ⟨uaub⟩= ql−1 ab . Together, (3) and (5) constitute a theoretical prediction for the typical evolution of the geometry of 2 points in (4) in a fixed large network. Analysis of these equations reveals an interesting order to chaos transition in the σw and σb plane. In particular, what happens to two nearby points as they propagate through the layers? Their relation to each other can be tracked by the correlation coefficient cl 12 between the two points, which approaches a fixed point c∗(σw, σb) at large depth. Since the length of each point rapidly converges to q∗(σw, σb), as shown in Fig. 1BD, we can compute c∗by simply setting ql 11 = ql 22 = q∗(σw, σb) in (5) and dividing by q∗to obtain an iterative correlation coefficient map, or C-map, for cl 12: cl 12 = 1 q∗C(cl−1 12 , q∗, q∗| σw, σb). (6) 3 This C-map is shown in Fig. 2A. It always has a fixed point at c∗= 1 as can be checked by direct calculation. However, the stability of this fixed point depends on the slope of the map at 1, which is χ1 ≡∂cl 12 ∂cl−1 12 c=1 = σ2 w Z Dz φ′ √q∗z 2 . (7) See SM for a derivation of (7). If the slope χ1 is less than 1, then the C-map is above the unity line, the fixed point at 1 under the C-map in (6) is stable, and nearby points become more similar over time. Figure 2: Dynamics of correlations, cl 12, in a sigmoidal network with φ(h) = tanh(h). (A) The C-map in (6) for the same σw and σb = 0.3 as in Fig. 1A. (B) The C-map dynamics, derived from both theory, through (6) (solid lines) and numerical simulations of (1) with Nl = 1000 (dots) (C) Fixed points c∗of the C-map. (D) The slope of the C-map at 1, χ1, partitions the space (black dotted line at χ1 = 1) into chaotic (χ1 > 1, c∗< 1) and ordered (χ1 < 1, c∗= 1) regions. Conversely, if χ1 > 1 then this fixed point is unstable, and nearby points separate as they propagate through the layers. Thus we can intuitively understand χ1 as a multiplicative stretch factor. This intuition can be made precise by considering the Jacobian Jl ij = Wl ijφ′(hl−1 j ) at a point hl−1 j with length q∗. Jl is a linear approximation of the network map from layer l −1 to l in the vicinity of hl−1. Therefore a small random perturbation hl−1 +u will map to hl +Ju. The growth of the perturbation, ||Ju||2 2/||u||2 2 becomes χ1(q∗) after averaging over the random perturbation u, weight matrix Wl, and Gaussian distribution of hl−1 i across i. Thus χ1 directly reflects the typical multiplicative growth or shrinkage of a random perturbation across one layer. The dynamics of the iterative C-map and its agreement with network simulations is shown in Fig. 2B. The correlation dynamics are much slower than the length dynamics because the C-map is closer to the unity line (Fig. 2A) than the length map (Fig. 1A). Thus correlations typically take about 20 layers to approach the fixed point, while lengths need only 4. The fixed point c∗and slope χ1 of the C-map are shown in Fig. 2CD. For any fixed, finite σb, as σw increases three qualitative regions occur. For small σw, c∗= 1 is the only fixed point, and it is stable because χ1 < 1. In this strong bias regime, any two input points converge to each other as they propagate through the network. As σw increases, χ1 increases and crosses 1, destabilizing the c∗= 1 fixed point. In this intermediate regime, a new stable fixed point c∗appears, which decreases as σw increases. Here an equal footing competition between weights and nonlinearities (which de-correlate inputs) and the biases (which correlate them), leads to a finite c∗. At larger σw, the strong weights overwhelm the biases and maximally de-correlate inputs to make them orthogonal, leading to a stable fixed point at c∗= 0. Thus the equation χ1(σw, σb) = 1 yields a phase transition boundary in the (σw, σb) plane, separating it into a chaotic (or ordered) phase, in which nearby points separate (or converge). In dynamical systems theory, the logarithm of χ1 is related to the well known Lyapunov exponent which is positive (or negative) for chaotic (or ordered) dynamics. However, in a feedforward network, the dynamics is truncated at a finite depth D, and hence the dynamics are a form of transient chaos. 4 The propagation of manifold geometry through deep networks Now consider a 1 dimensional manifold x0(θ) in input space, where θ is an intrinsic scalar coordinate on the manifold. This manifold propagates to a new manifold hl(θ) = hl(x0(θ)) in the vector space of inputs to layer l. The typical geometry of the manifold in the l’th layer is summarized by ql(θ1, θ2), which for any θ1 and θ2 is defined by (4) with the choice x0,a = x0(θ1) and x0,b = 4 x0(θ2). The theory for the propagation of pairs of points applies to all pairs of points on the manifold, so intuitively, we expect that in the chaotic phase of a sigmoidal network, the manifold should in some sense de-correlate, and become more complex, while in the ordered phase the manifold should contract around a central point. This theoretical prediction of equations (3) and (5) is quantitatively confirmed in simulations in Fig. 3, when the input is a simple manifold, the circle, h1(θ) = √N1q u0 cos(θ) + u1 sin(θ) , where u0 and u1 form an orthonormal basis for a 2 dimensional subspace of RN1 in which the circle lives. The scaling is chosen so that each neuron has input activity O(1). Also, for simplicity, we choose the fixed point radius q = q∗in Fig. 3. Figure 3: Propagating a circle through three random sigmoidal networks with varying σw and fixed σb = 0.3. (A) Projection of hidden inputs of simulated networks at layer 5 and 10 onto their first three principal components. Insets show the fraction of variance explained by the first 5 singular values. For large weights (bottom), the distribution of singular values gets flatter and the projected curve is more tangled. (B) The autocorrelation, cl 12(∆θ) = R dθ ql(θ, θ + ∆θ)/q∗, of hidden inputs as a function of layer for simulated networks. (C) The theoretical predictions from (6) (solid lines) compared to the average (dots) and standard deviation across θ (shaded) in a simulated network. To quantitatively understand the layer-wise growth of complexity of this manifold, it is useful to turn to concepts in Riemannian geometry [16]. First, at each point θ, the manifold h(θ) (we temporarily suppress the layer index l) has a tangent, or velocity vector v(θ) = ∂θh(θ). Intuitively, curvature is related to how quickly this tangent vector rotates in the ambient space RN as one moves along the manifold, or in essence the acceleration vector a(θ) = ∂θv(θ). Now at each point θ, when both are nonzero, v(θ) and a(θ) span a 2 dimensional subspace of RN. Within this subspace, there is a unique circle of radius R(θ) that has the same position, velocity and acceleration vector as the curve h(θ) at θ. This circle is known as the osculating circle (Fig. 4A), and the extrinsic curvature κ(θ) of the curve is defined as κ(θ) = 1/R(θ). Thus, intuitively, small radii of curvature R(θ) imply high extrinsic curvature κ(θ). The extrinsic curvature of a curve depends only on its image in RN and is invariant with respect to the particular parameterization θ →h(θ). For any parameterization, an explicit expression for κ(θ) is given by κ(θ) = (v·v)−3/2p (v · v)(a · a) −(v · a)2 [16]. Note that under a unit speed parameterization of the curve, so that v(θ) · v(θ) = 1, we have v(θ) · a(θ) = 0, and κ(θ) is simply the norm of the acceleration vector. Another measure of the curve’s complexity is the length LE of its image in the ambient Euclidean space. The Euclidean metric in RN induces a metric gE(θ) = v(θ) · v(θ) on the curve, so that the distance dLE moved in RN as one moves from θ to θ + dθ on the curve is dLE = p gE(θ)dθ. The total curve length is LE = R p gE(θ)dθ. However, even straight line segments can have a large Euclidean length. Another interesting measure of length that takes into account curvature, is the length of the image of the curve under the Gauss map. For a K dimensional manifold M embedded in 5 Figure 4: Propagation of extrinsic curvature and length in a network with 1000 hidden units. (A) An osculating circle. (B) A curve with unit tangent vectors at 4 points in ambient space, and the image of these points under the Gauss map. (C-E) Propagation of curvature metrics based on both theory derived from iterative maps in (3), (6) and (8) (solid lines) and simulations using (1) (dots). (F) Schematic of the normal vector, tangent plane, and principal curvatures for a 2D manifold embedded in R3. (G) average principal curvatures for the largest and smallest 4 principal curvatures (κ±1, . . . , κ±4) across locations θ within one network. The principal curvatures all grow exponentially as we backpropagate to the input layer. Panels F,G are discussed in Sec. 5. RN, the Gauss map (Fig. 4B) maps a point θ ∈M to its K dimensional tangent plane TθM ∈GK,N, where GK,N is the Grassmannian manifold of all K dimensional subspaces in RN. In the special case of K = 1, GK,N is the sphere SN−1 with antipodal points identified, since a 1-dimensional subspace can be identified with a unit vector, modulo sign. The Gauss map takes a point θ on the curve and maps it to the unit velocity vector ˆv(θ) = v(θ)/ p v(θ) · v(θ). In particular, the natural metric on SN−1 induces a Gauss metric on the curve, given by gG(θ) = (∂θˆv(θ)) · (∂θˆv(θ)), which measures how quickly the unit tangent vector ˆv(θ) changes as θ changes. Thus the distance dLG moved in the Grassmannian GK,N as one moves from θ to θ + dθ on the curve is dLG = p gG(θ)dθ, and the length of the curve under the Gauss map is LG = R p gG(θ)dθ. Furthermore, the Gauss metric is related to the extrinsic curvature and the Euclidean metric via the relation gG(θ) = κ(θ)2gE(θ) [16]. To illustrate these concepts, it is useful to compute all of them for the circle h1(θ) defined above: gE(θ) = Nq, LE = 2π√Nq, κ(θ) = 1/√Nq, gG(θ) = 1, and LG = 2π. As expected, κ(θ) is the inverse of the radius of curvature, which is √Nq. Now consider how these quantities change if the circle is scaled up so that h(θ) →χh(θ). The length LE and radius scale up by χ, but the curvature κ scales down as χ−1, and so LG does not change. Thus linear expansion increases length and decreases curvature, thereby maintaining constant Grassmannian length LG. We now show that nonlinear propagation of this same circle through a deep network can behave very differently from linear expansion: in the chaotic regime, length can increase without any decrease in extrinsic curvature! To remove the scaling with N in the above quantities, we will work with the renormalized quantities ¯κ = √ Nκ, ¯gE = 1 N gE, and ¯LE = 1 √ N LE. Thus, 1/(¯κ)2 can be thought of as a radius of curvature squared per neuron of the osculating circle, while ( ¯LE)2 is the squared Euclidean length of the curve per neuron. For the circle, these quantities are q and 2πq respectively. For simplicity, in the inputs to the first layer of neurons, we begin with a circle h1(θ) with squared radius per neuron q1 = q∗, so this radius is already at the fixed point of the length map in (3). In the SM, we derive an iterative formula for the extrinsic curvature and Euclidean metric of this manifold as it propagates through the layers of a deep network: ¯gE,l = χ1 ¯gE,l−1 (¯κl)2 = 3χ2 χ2 1 + 1 χ1 (¯κl−1)2, ¯gE,1 = q∗, (¯κ1)2 = 1/q∗. (8) where χ1 is the stretch factor defined in (7) and χ2 is defined analogously as χ2 = σ2 w Z Dz φ′′ √q∗z 2 . (9) 6 χ2 is closely related to the second derivative of the C-map in (6) at cl−1 12 = 1; this second derivative is χ2q∗. See SM for a derivation of the evolution equations for extrinsic geometry in (8). Intriguingly for a sigmoidal neural network, these evolution equations behave very differently in the chaotic (χ1 > 1) versus ordered (χ1 < 1) phase. In the chaotic phase, the Euclidean metric ¯gE grows exponentially with depth due to multiplicative stretching through χ1. This stretching does multiplicatively attenuate any curvature in layer l −1 by a factor 1/χ1 (see the update equation for ¯κl in (8)), but new curvature is added in due to a nonzero χ2, which originates from the curvature of the single neuron nonlinearity in (9). Thus, unlike in linear expansion, extrinsic curvature is not lost, but maintained, and ultimately approaches a fixed point ¯κ∗. This implies that the global curvature measure ¯LG grows exponentially with depth. These highly nontrivial predictions of the metric and curvature evolution equations in (8) are quantitatively confirmed in simulations in Figure 4C-E. Intuitively, this exponential growth of global curvature ¯LG in the chaotic phase implies that the curve explores many different tangent directions in hidden representation space. This further implies that the coordinate functions of the embedding hl i(θ) become highly complex curved basis functions on the input manifold coordinate θ, allowing a deep network to compute exponentially complex functions over simple low dimensional manifolds (Figure 5A-C, details in SM). Figure 5: Deep networks in the chaotic regime are more expressive than shallow networks. (A) Activity of four different neurons in the output layer as a function of the input, θ for three networks of different depth (width Nl = 1, 000). (B) Linear regression of the output activity onto a random function (black) shows closer predictions (blue) with deeper networks (bottom) than shallow networks (top). (C) Decomposing the prediction error by frequency shows shallow networks cannot capture high frequency content in random functions but deep networks can (yellow=high error). (D) Increasing the width of a one hidden layer network up to 10, 000 does not decrease error at high frequencies. 5 Shallow networks cannot achieve exponential expressivity Consider a shallow network with 1 hidden layer x1, one input layer x0, with x1 = φ(W1x0) + b1, and a linear readout layer. How complex can the hidden representation be as a function of its width N1, relative to the results above for depth? We prove a general upper bound on LE (see SM): Theorem 1. Suppose φ(h) is monotonically non-decreasing with bounded dynamic range R, i.e. maxh φ(h) −minh φ(h) = R. Further suppose that x0(θ) is a curve in input space such that no 1D projection of ∂θx(θ) changes sign more than s times over the range of θ. Then for any choice of W1 and b1 the Euclidean length of x1(θ), satisfies LE ≤N1(1 + s)R. For the circle input, s = 1 and for the tanh nonlinearity, R = 2, so in this special case, the normalized length ¯LE ≤2√N1. In contrast, for deep networks in the chaotic regime ¯LE grows exponentially with depth in h space, and so consequently also in x space. Therefore the length of curves typically expand exponentially in depth even for random deep networks, but can only expand as the square root of width no matter what shallow network is chosen. Moreover, as we have seen above, it is the exponential growth of ¯ LE that fundamentally drives the exponential growth of ¯LG with depth. Indeed shallow random networks exhibit minimal growth in expressivity even at large widths (Figure 5D). 6 Classification boundaries acquire exponential local curvature with depth We have focused so far on how simple manifolds in input space can acquire both exponential Euclidean and Grassmannian length with depth, thereby exponentially de-correlating and filling up 7 hidden representation space. Another natural question is how the complexity of a decision boundary grows as it is backpropagated to the input layer. Consider a linear classifier y = sgn(β · xD −β0) acting on the final layer. In this layer, the N −1 dimensional decision boundary is the hyperplane β·xD −β0 = 0. However, in the input layer x0, the decision boundary is a curved N −1 dimensional manifold M that arises as the solution set of the nonlinear equation G(x0) ≡β · xD(x0) −β0 = 0, where xD(x0) is the nonlinear feedforward map from input to output. At any point x∗on the decision boundary in layer l, the gradient ⃗∇G is perpendicular to the N −1 dimensional tangent plane Tx∗M (see Fig. 4F). The normal vector ⃗∇G, along with any unit tangent vector ˆv ∈Tx∗M, spans a 2 dimensional subspace whose intersection with M yields a geodesic curve in M passing through x∗with velocity vector ˆv. This geodesic will have extrinsic curvature κ(x∗, ˆv). Maximizing this curvature over ˆv yields the first principal curvature κ1(x∗). A sequence of successive maximizations of κ(x∗, ˆv), while constraining ˆv to be perpendicular to all previous solutions, yields the sequence of principal curvatures κ1(x∗) ≥κ2(x∗) ≥· · · ≥κN−1(x∗). These principal curvatures arise as the eigenvalues of a normalized Hessian operator projected onto the tangent plane Tx∗M: H = ||⃗∇G||−1 2 P ∂2G ∂x∂xT P, where P = I −b∇Gb∇GT is the projection operator onto Tx∗M and b∇G is the unit normal vector [16]. Intuitively, near x∗, the decision boundary M can be approximated as a paraboloid with a quadratic form H whose N −1 eigenvalues are the principal curvatures κ1, . . . , κN−1 (Fig. 4F). We compute these curvatures numerically as a function of depth in Fig. 4G (see SM for details). We find, remarkably, that a subset of principal curvatures grow exponentially with depth. Here the principal curvatures are signed, with positive (negative) curvature indicating that the associated geodesic curves towards (away from) the normal vector ⃗∇G. Thus the decision boundary can become exponentially curved with depth, enabling highly complex classifications. Moreover, this exponentially curved boundary is disentangled and mapped to a flat boundary in the output layer. 7 Discussion Fundamentally, neural networks compute nonlinear maps between high dimensional spaces, for example from RN1 →RND, and it is unclear what the most appropriate mathematics is for understanding such daunting spaces of maps. Previous works have attacked this problem by restricting the nature of the nonlinearity involved (e.g. piecewise linear, sum-product, or Pfaffian) and thereby restricting the space of maps to those amenable to special theoretical analysis methods (combinatorics, polynomial relations, or topological invariants). We have begun a preliminary exploration of the expressivity of such deep functions based on Riemannian geometry and dynamical mean field theory. We demonstrate that networks in a chaotic phase compactly exhibit functions that exponentially grow the global curvature of simple one dimensional manifolds from input to output and the local curvature of simple co-dimension one manifolds from output to input. The former captures the notion that deep neural networks can efficiently compute highly expressive functions in ways that shallow networks cannot, while the latter quantifies and demonstrates the power of deep neural networks to disentangle curved input manifolds, an attractive idea that has eluded formal quantification. Moreover, our analysis of a maximum entropy distribution over deep networks constitutes an important null model of deep signal propagation that can be used to assess and understand different behavior in trained networks. For example, the metrics we have adapted from Riemannian geometry, combined with an understanding of their behavior in random networks, may provide a basis for understanding what is special about trained networks. Furthermore, while we have focused on the notion of input-output chaos, the duality between inputs and synaptic weights imply a form of weight chaos, in which deep neural networks rapidly traverse function space as weights change (see SM). Indeed, just as autocorrelation lengths between outputs as a function of inputs shrink exponentially with depth, so too will autocorrelations between outputs as a function of weights. Finally, while our length and correlation maps can be applied directly to piecewise linear nonlinearities (e.g. ReLUs), deep piecewise linear functions have 0 local curvature. To characterize how such functions twist across input space, our methods can compute tangent vector auto-correlations instead of curvature. But more generally, to understand functions, we often look to their graphs. The graph of a map from RN1 →RND is an RN1 dimensional submanifold of RN1+ND, and therefore has both high dimension and co-dimension. We speculate that many of the secrets of deep learning may be uncovered by studying the geometry of this graph as a Riemannian manifold, and understanding how it changes with both depth and learning. 8 References [1] Alex Krizhevsky, Ilya Sutskever, and Geoffrey E Hinton. Imagenet classification with deep convolutional neural networks. In Advances in neural information processing systems, pages 1097–1105, 2012. [2] Volodymyr Mnih, Koray Kavukcuoglu, David Silver, Andrei A Rusu, Joel Veness, Marc G Bellemare, Alex Graves, Martin Riedmiller, Andreas K Fidjeland, Georg Ostrovski, et al. Human-level control through deep reinforcement learning. Nature, 518(7540):529–533, 2015. [3] Awni Hannun, Carl Case, Jared Casper, Bryan Catanzaro, Greg Diamos, Erich Elsen, Ryan Prenger, Sanjeev Satheesh, Shubho Sengupta, Adam Coates, et al. Deep speech: Scaling up end-to-end speech recognition. arXiv preprint arXiv:1412.5567, 2014. [4] Yann LeCun, Yoshua Bengio, and Geoffrey Hinton. Deep learning. Nature, 521(7553):436–444, 2015. [5] Chris Piech, Jonathan Bassen, Jonathan Huang, Surya Ganguli, Mehran Sahami, Leonidas J Guibas, and Jascha Sohl-Dickstein. Deep knowledge tracing. In Advances in Neural Information Processing Systems, pages 505–513, 2015. [6] Lane T. McIntosh, Niru Maheswaranathan, Aran Nayebi, Surya Ganguli, and Stephen A. Baccus. Deep learning models of the retinal response to natural scenes. In Advances in Neural Information Processing Systems, 2016. [7] Yoshua Bengio, Aaron Courville, and Pascal Vincent. Representation learning: A review and new perspectives. Pattern Analysis and Machine Intelligence, IEEE Transactions on, 35(8): 1798–1828, 2013. [8] James J DiCarlo and David D Cox. Untangling invariant object recognition. Trends in cognitive sciences, 11(8):333–341, 2007. [9] Guido F Montufar, Razvan Pascanu, Kyunghyun Cho, and Yoshua Bengio. On the number of linear regions of deep neural networks. In Advances in neural information processing systems, pages 2924–2932, 2014. [10] Olivier Delalleau and Yoshua Bengio. Shallow vs. deep sum-product networks. In Advances in Neural Information Processing Systems, pages 666–674, 2011. [11] Ronen Eldan and Ohad Shamir. The power of depth for feedforward neural networks. arXiv preprint arXiv:1512.03965, 2015. [12] Matus Telgarsky. Representation benefits of deep feedforward networks. arXiv preprint arXiv:1509.08101, 2015. [13] James Martens, Arkadev Chattopadhya, Toni Pitassi, and Richard Zemel. On the representational efficiency of restricted boltzmann machines. In Advances in Neural Information Processing Systems, pages 2877–2885, 2013. [14] Monica Bianchini and Franco Scarselli. On the complexity of neural network classifiers: A comparison between shallow and deep architectures. Neural Networks and Learning Systems, IEEE Transactions on, 25(8):1553–1565, 2014. [15] Hrushikesh Mhaskar, Qianli Liao, and Tomaso Poggio. Learning real and boolean functions: When is deep better than shallow. arXiv preprint arXiv:1603.00988, 2016. [16] John M Lee. Riemannian manifolds: an introduction to curvature, volume 176. Springer Science & Business Media, 2006. [17] Haim Sompolinsky, A Crisanti, and HJ Sommers. Chaos in random neural networks. Physical Review Letters, 61(3):259, 1988. [18] Maithra Raghu, Ben Poole, Jon Kleinberg, Surya Ganguli, and Jascha Sohl-Dickstein. On the expressive power of deep neural networks. arXiv preprint arXiv:1606.05336, 2016. 9 | 2016 | 51 |
6,450 | Contextual semibandits via supervised learning oracles Akshay Krishnamurthy† Alekh Agarwal‡ Miroslav Dudík‡ akshay@cs.umass.edu alekha@microsoft.com mdudik@microsoft.com †College of Information and Computer Sciences ‡Microsoft Research University of Massachusetts, Amherst, MA New York, NY Abstract We study an online decision making problem where on each round a learner chooses a list of items based on some side information, receives a scalar feedback value for each individual item, and a reward that is linearly related to this feedback. These problems, known as contextual semibandits, arise in crowdsourcing, recommendation, and many other domains. This paper reduces contextual semibandits to supervised learning, allowing us to leverage powerful supervised learning methods in this partial-feedback setting. Our first reduction applies when the mapping from feedback to reward is known and leads to a computationally efficient algorithm with near-optimal regret. We show that this algorithm outperforms state-of-the-art approaches on real-world learning-to-rank datasets, demonstrating the advantage of oracle-based algorithms. Our second reduction applies to the previously unstudied setting when the linear mapping from feedback to reward is unknown. Our regret guarantees are superior to prior techniques that ignore the feedback. 1 Introduction Decision making with partial feedback, motivated by applications including personalized medicine [21] and content recommendation [16], is receiving increasing attention from the machine learning community. These problems are formally modeled as learning from bandit feedback, where a learner repeatedly takes an action and observes a reward for the action, with the goal of maximizing reward. While bandit learning captures many problems of interest, several applications have additional structure: the action is combinatorial in nature and more detailed feedback is provided. For example, in internet applications, we often recommend sets of items and record information about the user’s interaction with each individual item (e.g., click). This additional feedback is unhelpful unless it relates to the overall reward (e.g., number of clicks), and, as in previous work, we assume a linear relationship. This interaction is known as the semibandit feedback model. Typical bandit and semibandit algorithms achieve reward that is competitive with the single best fixed action, i.e., the best medical treatment or the most popular news article for everyone. This is often inadequate for recommendation applications: while the most popular articles may get some clicks, personalizing content to the users is much more effective. A better strategy is therefore to leverage contextual information to learn a rich policy for selecting actions, and we model this as contextual semibandits. In this setting, the learner repeatedly observes a context (user features), chooses a composite action (list of articles), which is an ordered tuple of simple actions, and receives reward for the composite action (number of clicks), but also feedback about each simple action (click). The goal of the learner is to find a policy for mapping contexts to composite actions that achieves high reward. We typically consider policies in a large but constrained class, for example, linear learners or tree ensembles. Such a class enables us to learn an expressive policy, but introduces a computational challenge of finding a good policy without direct enumeration. We build on the supervised learning literature, which has developed fast algorithms for such policy classes, including logistic regression and SVMs for linear classifiers and boosting for tree ensembles. We access the policy class exclusively through a supervised learning algorithm, viewed as an oracle. 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. Algorithm Regret Oracle Calls Weights w? VCEE (Thm. 1) pKLT log N T 3/2p K/(L log N) known ✏-Greedy (Thm. 3) (LT)2/3(K log N)1/3 1 known Kale et al. [12] pKLT log N not oracle-based known EELS (Thm. 2) (LT)2/3(K log N)1/3 1 unknown Agarwal et al. [1] L p KLT log N p KLT/ log N unknown Swaminathan et al. [22] L4/3T 2/3(K log N)1/3 1 unknown Table 1: Comparison of contextual semibandit algorithms for arbitrary policy classes, assuming all rankings are valid composite actions. The reward is semibandit feedback weighted according to w?. For known weights, we consider w? = 1; for unknown weights, we assume kw?k2 O( p L). In this paper, we develop and evaluate oracle-based algorithms for the contextual semibandits problem. We make the following contributions: 1. In the more common setting where the linear function relating the semibandit feedback to the reward is known, we develop a new algorithm, called VCEE, that extends the oracle-based contextual bandit algorithm of Agarwal et al. [1]. We show that VCEE enjoys a regret bound between ˜O "pKLT log N # and ˜O " LpKT log N # , depending on the combinatorial structure of the problem, when there are T rounds of interaction, K simple actions, N policies, and composite actions have length L.1 VCEE can handle structured action spaces and makes ˜O(T 3/2) calls to the supervised learning oracle. 2. We empirically evaluate this algorithm on two large-scale learning-to-rank datasets and compare with other contextual semibandit approaches. These experiments comprehensively demonstrate that effective exploration over a rich policy class can lead to significantly better performance than existing approaches. To our knowledge, this is the first thorough experimental evaluation of not only oracle-based semibandit methods, but of oracle-based contextual bandits as well. 3. When the linear function relating the feedback to the reward is unknown, we develop a new algorithm called EELS. Our algorithm first learns the linear function by uniform exploration and then, adaptively, switches to act according to an empirically optimal policy. We prove an ˜O " (LT)2/3(K log N)1/3# regret bound by analyzing when to switch. We are not aware of other computationally efficient procedures with a matching or better regret bound for this setting. See Table 1 for a comparison of our results with existing applicable bounds. Related work. There is a growing body of work on combinatorial bandit optimization [2, 4] with considerable attention on semibandit feedback [6, 10, 12, 13, 19]. The majority of this research focuses on the non-contextual setting with a known relationship between semibandit feedback and reward, and a typical algorithm here achieves an ˜O( p KLT) regret against the best fixed composite action. To our knowledge, only the work of Kale et al. [12] and Qin et al. [19] considers the contextual setting, again with known relationship. The former generalizes the Exp4 algorithm [3] to semibandits, and achieves ˜O( p KLT) regret,2 but requires explicit enumeration of the policies. The latter generalizes the LinUCB algorithm of Chu et al. [7] to semibandits, assuming that the simple action feedback is linearly related to the context. This differs from our setting: we make no assumptions about the simple action feedback. In our experiments, we compare VCEE against this LinUCB-style algorithm and demonstrate substantial improvements. We are not aware of attempts to learn a relationship between the overall reward and the feedback on simple actions as we do with EELS. While EELS uses least squares, as in LinUCB-style approaches, it does so without assumptions on the semibandit feedback. Crucially, the covariates for its least squares problem are observed after predicting a composite action and not before, unlike in LinUCB. Supervised learning oracles have been used as a computational primitive in many settings including active learning [11], contextual bandits [1, 9, 20, 23], and structured prediction [8]. 1Throughout the paper, the ˜O(·) notation suppressed factors polylogarithmic in K, L, T and log N. We analyze finite policy classes, but our work extends to infinite classes by standard discretization arguments. 2Kale et al. [12] consider the favorable setting where our bounds match, when uniform exploration is valid. 2 2 Preliminaries Let X be a space of contexts and A a set of K simple actions. Let ⇧✓(X ! AL) be a finite set of policies, |⇧| = N, mapping contexts to composite actions. Composite actions, also called rankings, are tuples of L distinct simple actions. In general, there are K!/(K −L)! possible rankings, but they might not be valid in all contexts. The set of valid rankings for a context x is defined implicitly through the policy class as {⇡(x)}⇡2⇧. Let ∆(⇧) be the set of distributions over policies, and ∆(⇧) be the set of non-negative weight vectors over policies, summing to at most 1, which we call subdistributions. Let 1(·) be the 0/1 indicator equal to 1 if its argument is true and 0 otherwise. In stochastic contextual semibandits, there is an unknown distribution D over triples (x, y, ⇠), where x is a context, y 2 [0, 1]K is the vector of reward features, with entries indexed by simple actions as y(a), and ⇠2 [−1, 1] is the reward noise, E[⇠|x, y] = 0. Given y 2 RK and A = (a1, . . . , aL) 2 AL, we write y(A) 2 RL for the vector with entries y(a`). The learner plays a T-round game. In each round, nature draws (xt, yt, ⇠t) ⇠D and reveals the context xt. The learner selects a valid ranking At = (at,1, at,2, . . . , at,L) and gets reward rt(At) = PL `=1 w? ` yt(at,`) + ⇠t, where w? 2 RL is a possibly unknown but fixed weight vector. The learner is shown the reward rt(At) and the vector of reward features for the chosen simple actions yt(At), jointly referred to as semibandit feedback. The goal is to achieve cumulative reward competitive with all ⇡2 ⇧. For a policy ⇡, let R(⇡) := E(x,y,⇠)⇠D ⇥ r " ⇡(x) #⇤ denote its expected reward, and let ⇡? := argmax⇡2⇧R(⇡) be the maximizer of expected reward. We measure performance of an algorithm via cumulative empirical regret, Regret := T X t=1 rt(⇡?(xt)) −rt(At). (1) The performance of a policy ⇡is measured by its expected regret, Reg(⇡) := R(⇡?) −R(⇡). Example 1. In personalized search, a learning system repeatedly responds to queries with rankings of search items. This is a contextual semibandit problem where the query and user features form the context, the simple actions are search items, and the composite actions are their lists. The semibandit feedback is whether the user clicked on each item, while the reward may be the click-based discounted cumulative gain (DCG), which is a weighted sum of clicks, with position-dependent weights. We want to map contexts to rankings to maximize DCG and achieve a low regret. We assume that our algorithms have access to a supervised learning oracle, also called an argmax oracle, denoted AMO, that can find a policy with the maximum empirical reward on any appropriate dataset. Specifically, given a dataset D = {xi, yi, vi}n i=1 of contexts xi, reward feature vectors yi 2 RK with rewards for all simple actions, and weight vectors vi 2 RL, the oracle computes AMO(D) := argmax ⇡2⇧ n X i=1 hvi, yi(⇡(xi))i = argmax ⇡2⇧ n X i=1 L X `=1 vi,`yi(⇡(xi)`), (2) where ⇡(x)` is the `th simple action that policy ⇡chooses on context x. The oracle is supervised as it assumes known features yi for all simple actions whereas we only observe them for chosen actions. This oracle is the structured generalization of the one considered in contextual bandits [1, 9] and can be implemented by any structured prediction approach such as CRFs [14] or SEARN [8]. Our algorithms choose composite actions by sampling from a distribution, which allows us to use importance weighting to construct unbiased estimates for the reward features y. If on round t, a composite action At is chosen with probability Qt(At), we construct the importance weighted feature vector ˆyt with components ˆyt(a) := yt(a)1(a 2 At)/Qt(a 2 At), which are unbiased estimators of yt(a). For a policy ⇡, we then define empirical estimates of its reward and regret, resp., as ⌘t(⇡, w) := 1 t t X i=1 hw, ˆyi(⇡(xi))i and d Regt(⇡, w) := max ⇡0 ⌘t(⇡0, w) −⌘t(⇡, w). By construction, ⌘t(⇡, w?) is an unbiased estimate of the expected reward R(⇡), but d Regt(⇡, w?) is not an unbiased estimate of the expected regret Reg(⇡). We use ˆEx⇠H[·] to denote empirical expectation over contexts appearing in the history of interaction H. 3 Algorithm 1 VCEE (Variance-Constrained Explore-Exploit) Algorithm Require: Allowed failure probability δ 2 (0, 1). 1: Q0 = 0, the all-zeros vector. H0 = ;. Define: µt = min n 1/2K, p ln(16t2N/δ)/(Ktpmin) o . 2: for round t = 1, . . . , T do 3: Let ⇡t−1 = argmax⇡2⇧⌘t−1(⇡, w?) and ˜Qt−1 = Qt−1 + (1 −P ⇡Qt−1(⇡))1⇡t−1. 4: Observe xt 2 X, play At ⇠˜Qµt−1 t−1 (· | xt) (see Eq. (3)), and observe yt(At) and rt(At). 5: Define qt(a) = ˜Qµt−1 t−1 (a 2 A | xt) for each a. 6: Obtain Qt by solving OP with Ht = Ht−1 [ {(xt, yt(At), qt(At)} and µt. 7: end for Semi-bandit Optimization Problem (OP) With history H and µ ≥0, define b⇡:= kw?k1 kw?k2 2 c Regt(⇡) µpmin and := 100. Find Q 2 ∆(⇧) such that: X ⇡2⇧ Q(⇡)b⇡2KL/pmin (4) 8⇡2 ⇧: ˆEx⇠H " L X `=1 1 Qµ(⇡(x)` 2 A | x) # 2KL pmin + b⇡ (5) Finally, we introduce projections and smoothing of distributions. For any µ 2 [0, 1/K] and any subdistribution P 2 ∆(⇧), the smoothed and projected conditional subdistribution P µ(A | x) is P µ(A | x) := (1 −Kµ) X ⇡2⇧ P(⇡)1(⇡(x) = A) + KµUx(A), (3) where Ux is a uniform distribution over a certain subset of valid rankings for context x, designed to ensure that the probability of choosing each valid simple action is large. By mixing Ux into our action selection, we limit the variance of reward feature estimates ˆy. The lower bound on the simple action probabilities under Ux appears in our analysis as pmin, which is the largest number satisfying Ux(a 2 A) ≥pmin/K for all x and all simple actions a valid for x. Note that pmin = L when there are no restrictions on the action space as we can take Ux to be the uniform distribution over all rankings and verify that Ux(a 2 A) = L/K. In the worst case, pmin = 1, since we can always find one valid ranking for each valid simple action and let Ux be the uniform distribution over this set. Such a ranking can be found efficiently by a call to AMO for each simple action a, with the dataset of a single point (x, 1a 2 RK, 1 2 RL), where 1a(a0) = 1(a = a0). 3 Semibandits with known weights We begin with the setting where the weights w? are known, and present an efficient oracle-based algorithm (VCEE, see Algorithm 1) that generalizes the algorithm of Agarwal et al. [1]. The algorithm, before each round t, constructs a subdistribution Qt−1 2 ∆(⇧), which is used to form the distribution ˜Qt−1 by placing the missing mass on the maximizer of empirical reward. The composite action for the context xt is chosen according to the smoothed distribution ˜Qµt−1 t−1 (see Eq. (3)). The subdistribution Qt−1 is any solution to the feasibility problem (OP), which balances exploration and exploitation via the constraints in Eqs. (4) and (5). Eq. (4) ensures that the distribution has low empirical regret. Simultaneously, Eq. (5) ensures that the variance of the reward estimates ˆy remains sufficiently small for each policy ⇡, which helps control the deviation between empirical and expected regret, and implies that Qt−1 has low expected regret. For each ⇡, the variance constraint is based on the empirical regret of ⇡, guaranteeing sufficient exploration amongst all good policies. OP can be solved efficiently using AMO and a coordinate descent procedure obtained by modifying the algorithm of Agarwal et al. [1]. While the full algorithm and analysis are deferred to Appendix E, several key differences between VCEE and the algorithm of Agarwal et al. [1] are worth highlighting. 4 One crucial modification is that the variance constraint in Eq. (5) involves the marginal probabilities of the simple actions rather than the composite actions as would be the most obvious adaptation to our setting. This change, based on using the reward estimates ˆyt for simple actions, leads to substantially lower variance of reward estimates for all policies and, consequently, an improved regret bound. Another important modification is the new mixing distribution Ux and the quantity pmin. For structured composite action spaces, uniform exploration over the valid composite actions may not provide sufficient coverage of each simple action and may lead to dependence on the composite action space size, which is exponentially worse than when Ux is used. The regret guarantee for Algorithm 1 is the following: Theorem 1. For any δ 2 (0, 1), with probability at least 1 −δ, VCEE achieves regret ˜O " kw?k2 2 kw?k1 L p KT log(N/δ) / pmin # . Moreover, VCEE can be efficiently implemented with ˜O " T 3/2p K / (pmin log(N/δ)) # calls to a supervised learning oracle AMO. In Table 1, we compare this result to other applicable regret bounds in the most common setting, where w? = 1 and all rankings are valid (pmin = L). VCEE enjoys a ˜O(pKLT log N) regret bound, which is the best bound amongst oracle-based approaches, representing an exponentially better L-dependence over the purely bandit feedback variant [1] and a polynomially better T-dependence over an ✏-greedy scheme (see Theorem 3 in Appendix A). This improvement over ✏-greedy is also verified by our experiments. Additionally, our bound matches that of Kale et al. [12], who consider the harder adversarial setting but give an algorithm that requires an exponentially worse running time, ⌦(NT), and cannot be efficiently implemented with an oracle. Other results address the non-contextual setting, where the optimal bounds for both stochastic [13] and adversarial [2] semibandits are ⇥( p KLT). Thus, our bound may be optimal when pmin = ⌦(L). However, these results apply even without requiring all rankings to be valid, so they improve on our bound by a p L factor when pmin = 1. This p L discrepancy may not be fundamental, but it seems unavoidable with some degree of uniform exploration, as in all existing contextual bandit algorithms. A promising avenue to resolve this gap is to extend the work of Neu [18], which gives high-probability bounds in the noncontextual setting without uniform exploration. To summarize, our regret bound is similar to existing results on combinatorial (semi)bandits but represents a significant improvement over existing computationally efficient approaches. 4 Semibandits with unknown weights We now consider a generalization of the contextual semibandit problem with a new challenge: the weight vector w? is unknown. This setting is substantially more difficult than the previous one, as it is no longer clear how to use the semibandit feedback to optimize for the overall reward. Our result shows that the semibandit feedback can still be used effectively, even when the transformation is unknown. Throughout, we assume that the true weight vector w? has bounded norm, i.e., kw?k2 B. One restriction required by our analysis is the ability to play any ranking. Thus, all rankings must be valid in all contexts, which is a natural restriction in domains such as information retrieval and recommendation. The uniform distribution over all rankings is denoted U. We propose an algorithm that explores first and then, adaptively, switches to exploitation. In the exploration phase, we play rankings uniformly at random, with the goal of accumulating enough information to learn the weight vector w? for effective policy optimization. Exploration lasts for a variable length of time governed by two parameters n? and λ?. The n? parameter controls the minimum number of rounds of the exploration phase and is O(T 2/3), similar to ✏-greedy style schemes [15]. The adaptivity is implemented by the λ? parameter, which imposes a lower bound on the eigenvalues of the 2nd-moment matrix of reward features observed during exploration. As a result, we only transition to the exploitation phase after this matrix has suitably large eigenvalues. Since we make no assumptions about the reward features, there is no bound on how many rounds this may take. This is a departure from previous explore-first schemes, and captures the difficulty of learning w? when we observe the regression features only after taking an action. After the exploration phase of t rounds, we perform least-squares regression using the observed reward features and the rewards to learn an estimate ˆw of w?. We use ˆw and importance weighted 5 Algorithm 2 EELS (Explore-Exploit Least Squares) Require: Allowed failure probability δ 2 (0, 1). Assume kw?k2 B. 1: Set n? T 2/3(K ln(N/δ)/L)1/3 max{1, (B p L)−2/3} 2: for t = 1, . . . , n? do 3: Observe xt, play At ⇠U (U is uniform over all rankings), observe yt(At) and rt(At). 4: end for 5: Let ˆV = 1 2n?K2 Pn? t=1 P a,b2A " yt(a) −yt(b) #2 1(a,b2At) U(a,b2At). 6: ˜V 2 ˆV + 3 ln(2/δ)/(2n?). 7: Set λ? max n 6L2 ln(4LT/δ), (T ˜V /B)2/3 (L ln(2/δ))1/3o . 8: Set ⌃ Pn? t=1 yt(At)yt(At)T . 9: while λmin(⌃) λ? do 10: t t + 1. Observe xt, play At ⇠U, observe yt(At) and rt(At). 11: Set ⌃ ⌃+ yt(At)yt(At)T . 12: end while 13: Estimate weights ˆw ⌃−1(Pt i=1 yi(Ai)ri(Ai)) (Least Squares). 14: Optimize policy ˆ⇡ argmax⇡2⇧⌘t(⇡, ˆw) using importance weighted features. 15: For every remaining round: observe xt, play At = ˆ⇡(xt). reward features from the exploration phase to find a policy ˆ⇡with maximum empirical reward, ⌘t(·, ˆw). The remaining rounds comprise the exploitation phase, where we play according to ˆ⇡. The remaining question is how to set λ?, which governs the length of the exploration phase. The ideal setting uses the unknown parameter V := E(x,y)⇠D Vara⇠Unif(A)[y(a)] of the distribution D, where Unif(A) is the uniform distribution over all simple actions. We form an unbiased estimator ˆV of V and derive an upper bound ˜V . While the optimal λ? depends on V , the upper bound ˜V suffices. For this algorithm, we prove the following regret bound. Theorem 2. For any δ 2 (0, 1) and T ≥K ln(N/δ)/ min{L, (BL)2}, with probability at least 1−δ, EELS has regret ˜O " T 2/3(K log(N/δ))1/3 max{B1/3L1/2, BL1/6} # . EELS can be implemented efficiently with one call to the optimization oracle. The theorem shows that we can achieve sublinear regret without dependence on the composite action space size even when the weights are unknown. The only applicable alternatives from the literature are displayed in Table 1, specialized to B = ⇥( p L). First, oracle-based contextual bandits [1] achieve a better T-dependence, but both the regret and the number of oracle calls grow exponentially with L. Second, the deviation bound of Swaminathan et al. [22], which exploits the reward structure but not the semibandit feedback, leads to an algorithm with regret that is polynomially worse in its dependence on L and B (see Appendix B). This observation is consistent with non-contextual results, which show that the value of semibandit information is only in L factors [2]. Of course EELS has a sub-optimal dependence on T, although this is the best we are aware of for a computationally efficient algorithm in this setting. It is an interesting open question to achieve poly(K, L)pT log N regret with unknown weights. 5 Proof sketches We next sketch the arguments for our theorems. Full proofs are deferred to the appendices. Proof of Theorem 1: The result generalizes Agarwal et. al [1], and the proof structure is similar. For the regret bound, we use Eq. (5) to control the deviation of the empirical reward estimates which make up the empirical regret d Regt. A careful inductive argument leads to the following bounds: Reg(⇡) 2d Regt(⇡) + c0 kw?k2 2 kw?k1 KLµt and d Regt(⇡) 2Reg(⇡) + c0 kw?k2 2 kw?k1 KLµt. Here c0 is a universal constant and µt is defined in the pseudocode. Eq. (4) guarantees low empirical regret when playing according to ˜Qµt t , and the above inequalities also ensure small population regret. 6 The cumulative regret is bounded by kw?k2 2 kw?k1 KL PT t=1 µt, which grows at the rate given in Theorem 1. The number of oracle calls is bounded by the analysis of the number of iterations of coordinate descent used to solve OP, via a potential argument similar to Agarwal et al. [1]. Proof of Theorem 2: We analyze the exploration and exploitation phases individually, and then optimize n? and λ? to balance these terms. For the exploration phase, the expected per-round regret can be bounded by either kw?k2 p KV or kw?k2 p L, but the number of rounds depends on the minimum eigenvalue λmin(⌃), with ⌃defined in Steps 8 and 11. However, the expected per-round 2nd-moment matrix, E(x,y)⇠D,A⇠U[y(A)y(A)T ], has all eigenvalues at least V . Thus, after t rounds, we expect λmin(⌃) ≥tV , so exploration lasts about λ?/V rounds, yielding roughly Exploration Regret λ? V · kw?k2 min{ p KV , p L}. Now our choice of λ? produces a benign dependence on V and yields a T 2/3 bound. For the exploitation phase, we bound the error between the empirical reward estimates ⌘t(⇡, ˆw) and the true reward R(⇡). Since we know λmin(⌃) ≥λ? in this phase, we obtain Exploitation Regret Tkw?k2 r K log N n? + T r L λ? min{ p KV , p L}. The first term captures the error from using the importance-weighted ˆy vector, while the second uses a bound on the error k ˆw −w?k2 from the analysis of linear regression (assuming λmin(⌃) ≥λ?). This high-level argument ignores several important details. First, we must show that using ˜V instead of the optimal choice V in the setting of λ? does not affect the regret. Secondly, since the termination condition for the exploration phase depends on the random variable ⌃, we must derive a highprobability bound on the number of exploration rounds to control the regret. Obtaining this bound requires a careful application of the matrix Bernstein inequality to certify that ⌃has large eigenvalues. 6 Experimental Results Our experiments compare VCEE with existing alternatives. As VCEE generalizes the algorithm of Agarwal et al. [1], our experiments also provide insights into oracle-based contextual bandit approaches and this is the first detailed empirical study of such algorithms. The weight vector w? in our datasets was known, so we do not evaluate EELS. This section contains a high-level description of our experimental setup, with details on our implementation, baseline algorithms, and policy classes deferred to Appendix C. Software is available at http://github.com/akshaykr/oracle_cb. Data: We used two large-scale learning-to-rank datasets: MSLR [17] and all folds of the Yahoo! Learning-to-Rank dataset [5]. Both datasets have over 30k unique queries each with a varying number of documents that are annotated with a relevance in {0, . . . , 4}. Each query-document pair has a feature vector (d = 136 for MSLR and d = 415 for Yahoo!) that we use to define our policy class. For MSLR, we choose K = 10 documents per query and set L = 3, while for Yahoo!, we set K = 6 and L = 2. The goal is to maximize the sum of relevances of shown documents (w? = 1) and the individual relevances are the semibandit feedback. All algorithms make a single pass over the queries. Algorithms: We compare VCEE, implemented with an epoch schedule for solving OP after 2i/2 rounds (justified by Agarwal et al. [1]), with two baselines. First is the ✏-GREEDY approach [15], with a constant but tuned ✏. This algorithm explores uniformly with probability ✏and follows the empirically best policy otherwise. The empirically best policy is updated with the same 2i/2 schedule. We also compare against a semibandit version of LINUCB [19]. This algorithm models the semibandit feedback as linearly related to the query-document features and learns this relationship, while selecting composite actions using an upper-confidence bound strategy. Specifically, the algorithm maintains a weight vector ✓t 2 Rd formed by solving a ridge regression problem with the semibandit feedback yt(at,`) as regression targets. At round t, the algorithm uses document features {xa}a2A and chooses the L documents with highest xT a ✓t + ↵xT a ⌃−1 t xa value. Here, ⌃t is the feature 2nd-moment matrix and ↵is a tuning parameter. For computational reasons, we only update ⌃t and ✓t every 100 rounds. Oracle implementation: LINUCB only works with a linear policy class. VCEE and ✏-GREEDY work with arbitrary classes. Here, we consider three: linear functions and depth-2 and depth-5 7 0.0 0.2 0.4 0.6 0.8 1.0 Number of interactions (T) 0.0 0.2 0.4 0.6 0.8 1.0 Average reward 10000 20000 30000 2.2 2.3 Dataset: MSLR 10000 20000 30000 2.9 3.0 3.1 Dataset: Yahoo! ✏-Lin VC-Lin ✏-GB2 VC-GB2 ✏-GB5 VC-GB5 LinUCB Figure 1: Average reward as a function of number of interactions T for VCEE, ✏-GREEDY, and LINUCB on MSLR (left) and Yahoo (right) learning-to-rank datasets. gradient boosted regression trees (abbreviated Lin, GB2 and GB5). Both GB classes use 50 trees. Precise details of how we instantiate the supervised learning oracle can be found in Appendix C. Parameter tuning: Each algorithm has a parameter governing the explore-exploit tradeoff. For VCEE, we set µt = c p 1/KLT and tune c, in ✏-GREEDY we tune ✏, and in LINUCB we tune ↵. We ran each algorithm for 10 repetitions, for each of ten logarithmically spaced parameter values. Results: In Figure 1, we plot the average reward (cumulative reward up to round t divided by t) on both datasets. For each t, we use the parameter that achieves the best average reward across the 10 repetitions at that t. Thus for each t, we are showing the performance of each algorithm tuned to maximize reward over t rounds. We found VCEE was fairly stable to parameter tuning, so for VC-GB5 we just use one parameter value (c = 0.008) for all t on both datasets. We show confidence bands at twice the standard error for just LINUCB and VC-GB5 to simplify the plot. Qualitatively, both datasets reveal similar phenomena. First, when using the same policy class, VCEE consistently outperforms ✏-GREEDY. This agrees with our theory, as VCEE achieves p T-type regret, while a tuned ✏-GREEDY achieves at best a T 2/3 rate. Secondly, if we use a rich policy class, VCEE can significantly improve on LINUCB, the empirical state-of-the-art, and one of few practical alternatives to ✏-GREEDY. Of course, since ✏-GREEDY does not outperform LINUCB, the tailored exploration of VCEE is critical. Thus, the combination of these two properties is key to improved performance on these datasets. VCEE is the only contextual semibandit algorithm we are aware of that performs adaptive exploration and is agnostic to the policy representation. Note that LINUCB is quite effective and outperforms VCEE with a linear class. One possible explanation for this behavior is that LINUCB, by directly modeling the reward, searches the policy space more effectively than VCEE, which uses an approximate oracle implementation. 7 Discussion This paper develops oracle-based algorithms for contextual semibandits both with known and unknown weights. In both cases, our algorithms achieve the best known regret bounds for computationally efficient procedures. Our empirical evaluation of VCEE, clearly demonstrates the advantage of sophisticated oracle-based approaches over both parametric approaches and naive exploration. To our knowledge this is the first detailed empirical evaluation of oracle-based contextual bandit or semibandit learning. We close with some promising directions for future work: 1. With known weights, can we obtain ˜O(pKLT log N) regret even with structured action spaces? This may require a new contextual bandit algorithm that does not use uniform smoothing. 2. With unknown weights, can we achieve a p T dependence while exploiting semibandit feedback? Acknowledgements This work was carried out while AK was at Microsoft Research. 8 References [1] A. Agarwal, D. Hsu, S. Kale, J. Langford, L. Li, and R. E. Schapire. Taming the monster: A fast and simple algorithm for contextual bandits. In ICML, 2014. [2] J.-Y. Audibert, S. Bubeck, and G. Lugosi. Regret in online combinatorial optimization. Math of OR, 2014. [3] P. Auer, N. Cesa-Bianchi, Y. Freund, and R. E. Schapire. The nonstochastic multiarmed bandit problem. SIAM Journal on Computing, 2002. [4] N. Cesa-Bianchi and G. Lugosi. Combinatorial bandits. JCSS, 2012. [5] O. Chapelle and Y. Chang. Yahoo! learning to rank challenge overview. In Yahoo! Learning to Rank Challenge, 2011. [6] W. Chen, Y. Wang, and Y. Yuan. Combinatorial multi-armed bandit: General framework and applications. In ICML, 2013. [7] W. Chu, L. Li, L. Reyzin, and R. E. Schapire. Contextual bandits with linear payoff functions. In AISTATS, 2011. [8] H. Daumé III, J. Langford, and D. Marcu. Search-based structured prediction. MLJ, 2009. [9] M. Dudík, D. Hsu, S. Kale, N. Karampatziakis, J. Langford, L. Reyzin, and T. Zhang. Efficient optimal learning for contextual bandits. In UAI, 2011. [10] A. György, T. Linder, G. Lugosi, and G. Ottucsák. The on-line shortest path problem under partial monitoring. JMLR, 2007. [11] D. J. Hsu. Algorithms for active learning. PhD thesis, University of California, San Diego, 2010. [12] S. Kale, L. Reyzin, and R. E. Schapire. Non-stochastic bandit slate problems. In NIPS, 2010. [13] B. Kveton, Z. Wen, A. Ashkan, and C. Szepesvári. Tight regret bounds for stochastic combinatorial semi-bandits. In AISTATS, 2015. [14] J. Lafferty, A. McCallum, and F. Pereira. Conditional random fields: Probabilistic models for segmenting and labeling sequence data. In ICML, 2001. [15] J. Langford and T. Zhang. The epoch-greedy algorithm for multi-armed bandits with side information. In NIPS, 2008. [16] L. Li, W. Chu, J. Langford, and R. E. Schapire. A contextual-bandit approach to personalized news article recommendation. In WWW, 2010. [17] MSLR. Mslr: Microsoft learning to rank dataset. http://research.microsoft.com/en-us/ projects/mslr/. [18] G. Neu. Explore no more: Improved high-probability regret bounds for non-stochastic bandits. In NIPS, 2015. [19] L. Qin, S. Chen, and X. Zhu. Contextual combinatorial bandit and its application on diversified online recommendation. In ICDM, 2014. [20] A. Rakhlin and K. Sridharan. Bistro: An efficient relaxation-based method for contextual bandits. In ICML, 2016. [21] J. M. Robins. The analysis of randomized and nonrandomized AIDS treatment trials using a new approach to causal inference in longitudinal studies. In Health Service Research Methodology: A Focus on AIDS, 1989. [22] A. Swaminathan, A. Krishnamurthy, A. Agarwal, M. Dudík, J. Langford, D. Jose, and I. Zitouni. Off-policy evaluation for slate recommendation. arXiv:1605.04812v2, 2016. [23] V. Syrgkanis, A. Krishnamurthy, and R. E. Schapire. Efficient algorithms for adversarial contextual learning. In ICML, 2016. 9 | 2016 | 510 |
6,451 | Learning Treewidth-Bounded Bayesian Networks with Thousands of Variables Mauro Scanagatta IDSIA∗, SUPSI†, USI‡ Lugano, Switzerland mauro@idsia.ch Giorgio Corani IDSIA∗, SUPSI†, USI‡ Lugano, Switzerland giorgio@idsia.ch Cassio P. de Campos Queen’s University Belfast Northern Ireland, UK c.decampos@qub.ac.uk Marco Zaffalon IDSIA∗ Lugano, Switzerland zaffalon@idsia.ch Abstract We present a method for learning treewidth-bounded Bayesian networks from data sets containing thousands of variables. Bounding the treewidth of a Bayesian network greatly reduces the complexity of inferences. Yet, being a global property of the graph, it considerably increases the difficulty of the learning process. Our novel algorithm accomplishes this task, scaling both to large domains and to large treewidths. Our novel approach consistently outperforms the state of the art on experiments with up to thousands of variables. 1 Introduction We consider the problem of structural learning of Bayesian networks with bounded treewidth, adopting a score-based approach. Learning the structure of a bounded treewidth Bayesian network is an NP-hard problem (Korhonen and Parviainen, 2013). Yet learning Bayesian networks with bounded treewidth is necessary to allow exact tractable inference, since the worst-case inference complexity is exponential in the treewidth k (under the exponential time hypothesis) (Kwisthout et al., 2010). A pioneering approach, polynomial in both the number of variables and the treewidth bound, has been proposed in Elidan and Gould (2009). It incrementally builds the network; at each arc addition it provides an upper-bound on the treewidth of the learned structure. The limit of this approach is that, as the number of variables increases, the gap between the bound and the actual treewidth becomes large, leading to sparse networks. An exact method has been proposed in Korhonen and Parviainen (2013), which finds the highest-scoring network with the desired treewidth. However, its complexity increases exponentially with the number of variables n. Thus it has been applied in experiments with 15 variables at most. Parviainen et al. (2014) adopted an anytime integer linear programming (ILP) approach, called TWILP. If the algorithm is given enough time, it finds the highest-scoring network with bounded treewidth. Otherwise it returns a sub-optimal DAG with bounded treewidth. The ILP problem has an exponential number of constraints in the number of variables; this limits its scalability, even if the constraints can be generated online. Berg et al. (2014) casted the problem of structural learning with limited treewidth as a problem of weighted partial Maximum Satisfiability. They solved the problem exactly through a MaxSAT solver and performed experiments with 30 variables at most. Nie et al. (2014) proposed an efficient anytime ILP approach with a polynomial number of constraints ∗Istituto Dalle Molle di studi sull’Intelligenza Artificiale (IDSIA) †Scuola universitaria professionale della Svizzera italiana (SUPSI) ‡Università della Svizzera italiana (USI) 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. in the number of variables. Yet they report that the quality of the solutions quickly degrades as the number of variables exceeds a few dozens and that no satisfactory solutions are found with data sets containing more than 50 variables. Approximate approaches are therefore needed to scale to larger domains. Nie et al. (2015) proposed the method S2. It exploits the notion of k-tree, which is an undirected maximal graph with treewidth k. A Bayesian network whose moral graph is a subgraph of a k-tree has treewidth bounded by k. S2 is an iterative algorithm. Each iteration consists of two steps: a) sampling uniformly a k-tree from the space of k-trees and b) recovering a DAG whose moral graph is a sub-graph of the most promising sampled k-tree. The goodness of the k-tree is assessed via a so-called informative score. Nie et al. (2016) further refine this idea, obtaining via A* the k-tree which maximizes the informative score. This algorithm is called S2+. Recent structural learning algorithms with unbounded treewidth (Scanagatta et al., 2015) can cope with thousands of variables. Yet the unbounded treewidth provides no guarantee about the tractability of the inferences of the learned models. We aim at filling this gap, learning treewidth-bounded Bayesian network models in domains with thousands of variables. We propose two novel methods for learning Bayesian networks with bounded treewidth. They exploit the fact that any k-tree can be constructed by an iterative procedure that adds one variable at a time. We propose an iterative procedure that, given an order on the variables, builds a DAG G adding one variable at a time. The moral graph of G is ensured to be subgraph of a k-tree. The k-tree is designed as to maximize the score of the resulting DAG. This is a major difference with respect to previous works (Nie et al., 2015, 2016) in which the k-trees were randomly sampled. We propose both an exact and an approximated variant of our algorithm; the latter is necessary to scale to thousands of variables. We discuss that the search space of the presented algorithms does not span the whole space of bounded-treewidth DAGs. Yet our algorithms consistently outperform the state-of-the-art competitors for structural learning with bounded treewidth. For the first time we present experimental results for structural learning with bounded treewidth for domains involving up to ten thousand variables. Software and supplementary material are available from http://blip.idsia.ch. 2 Structural learning Consider the problem of learning the structure of a Bayesian network from a complete data set of N instances D = {D1, ..., DN}. The set of n categorical random variables is X = {X1, ..., Xn}. The goal is to find the best DAG G = (V, E), where V is the collection of nodes and E is the collection of arcs. E can be represented by the set of parents Π1, ..., Πn of each variable. Different scores can be used to assess the fit of a DAG; we adopt the Bayesian information criterion (or simply BIC). The BIC score is decomposable, being constituted by the sum of the scores of the individual variables: BIC(G) = n X i=1 BIC(Xi, Πi) = n X i=1 (LL(Xi|Πi) + Pen(Xi, Πi)) = = n X i=1 ( X π∈|Πi|,x∈|Xi| Nx,π ˆθx|π −log N 2 (|Xi| −1)(|Πi|)) where ˆθx|π is the maximum likelihood estimate of the conditional probability P(Xi = x|Πi = π), Nx,π represents the number of times (X = x ∧Πi = π) appears in the data set, and | · | indicates the size of the Cartesian product space of the variables given as argument. Thus |Xi| is the number of states of Xi and |Πi| is the product of the number of states of the parents of Xi. Exploiting decomposability, we first identify independently for each variable a list of candidate parent sets (parent set identification). Later, we select for each node the parent set that yields the highest-scoring treewidth-bounded DAG (structure optimization). 2 2.1 Treewidth and k-trees We illustrate the concept of treewidth following the notation of Elidan and Gould (2009). We denote an undirected graph as H = (V, E) where V is the vertex set and E is the edge set. A tree decomposition of H is a pair (C, T ) where C = {C1, C2, ..., Cm} is a collection of subsets of V and T is a tree on C, so that: • ∪m i=1 Ci = V ; • for every edge which connects the vertices v1 and v2, there is a subset Ci which contains both v1 and v2; • for all i, j, k in {1, 2, ..m} if Cj is on the path between Ci and Ck in T then Ci ∩Ck ⊆Cj. The width of a tree decomposition is max(|Ci|) −1 where |Ci| is the number of vertices in Ci. The treewidth of H is the minimum width among all possible tree decompositions of G. The treewidth can be equivalently defined in terms of a triangulation of H. A triangulated graph is an undirected graph in which every cycle of length greater than three contains a chord. The treewidth of a triangulated graph is the size of the maximal clique of the graph minus one. The treewidth of H is the minimum treewidth over all the possible triangulations of H. The treewidth of a Bayesian network is characterized with respect to all possible triangulations of its moral graph. The moral graph M of a DAG is an undirected graph that includes an edge i −j for every edge i →j in the DAG and an edge p −q for every pair of edges p →i, q →i in the DAG. The treewidth of a DAG is the minimum treewidth over all the possible triangulations of its moral graph M. Thus the maximal clique of any moralized triangulation of G is an upper bound on the treewidth of the model. k-trees An undirected graph Tk = (V, E) is a k-tree if it is a maximal graph of tree-width k: any edge added to Tk increases its treewidth. A k-tree is inductively defined as follows (Patil, 1986). Consider a (k + 1)-clique, namely a complete graph with k + 1 nodes. A (k + 1)-clique is a k-tree. A (k + 1)-clique can be decomposed into multiple k-cliques. Let us denote by z a node not yet included in the list of vertices V . Then the graph obtained by connecting z to every node of a k-clique of Tk is also a k-tree. The treewidth of any subgraph of a k-tree (partial k-tree) is bounded by k. Thus a DAG whose moral graph is subgraph of a k-tree has treewidth bounded by k. 3 Incremental treewidth-bounded structure learning Our approach for the structure optimization task proceeds by repeatedly sampling an order ≺over the variables and then identifying the highest-scoring DAG with bounded treewidth consistent with the order. An effective approach for structural learning based on order sampling has been introduced by Teyssier and Koller (2012); however it does not enforce any treewidth constraint. The size of the search space of orders is n!; this is smaller than the search space of the k-trees, O(enlog(nk)). Once the order ≺is sampled, we incrementally learn the DAG. At each iteration the moralization of the DAG is by design a subgraph of a k-tree. The treewidth of the DAG eventually obtained is thus bounded by k. The algorithm proceeds as follows. Initialization The initial k-tree Kk+1 is constituted by the complete clique over the first k + 1 variables in the order. The initial DAG Gk+1 is learned over the same k + 1 variables. Since (k + 1) is a tractable number of variables, we exactly learn Gk+1 adopting the method of Cussens (2011). The moral graph of Gk+1 is a subgraph of Kk+1 and thus Gk+1 has bounded treewidth. Addition of the subsequent nodes We then iteratively add each remaining variable in the order. Consider the next variable in the order, X≺i, where i ∈{k + 2, ..., n}. Let us denote by Gi−1 and Ki−1 the DAG and the k-tree which have to be updated by adding X≺i. We add X≺i to Gi−1, constraining its parent set Π≺i to be a k-clique (or a subset of) in Ki−1. This yields the updated DAG Gi. We then update the k-tree, connecting X≺i to such k-clique. This yields the k-tree Ki; it contains an additional k + 1-clique compared to Ki−1. By construction, Ki is also a k-tree. The moral graph of Gi cannot add arc outside this (k + 1)-clique; thus it is a subgraph of Ki. Pruning orders The initial k-tree Kk+1 and the initial DAG Gk+1 depend on which are the first k + 1 variables in the order, but not on their relative positions. Thus all the orders which differ only 3 as for the relative position of the first k + 1 elements are equivalent for our algorithm: they yield the same Kk+1 and Gk+1. Thus once we sample an order and perform structural learning, we prune the (k + 1)! −1 orders which are equivalent to the current one. In order to choose the parent set to be assigned to each variable added to the graph we propose two algorithms: k-A* and k-G. 3.1 k-A* We formulate the problem as a shortest path finding problem. We define each state as a step towards the completion of the structure, where a new variable is added to the DAG G. Given X≺i the variable assigned in the state S, we define a successor state of S for each k-clique to which we can link X≺i+1. The approach to solve the problem is based on a path-finding A* search, with cost function for state S defined as f(S) = g(S) + h(S). The goal is to find the state which minimizes f(S) once all variables have been assigned. We define g(S) and h(S) as: g(S) = i X j=0 score(X≺j,Π≺j) , h(S) = n X j=i+1 best(X≺j) . g(S) is the cost from the initial state to S; it corresponds to the sum of scores of the already assigned parent sets. h(S) is the estimated cost from S to the goal. It is the sum of the best assignable parent sets for the remaining variables. Variable Xa can have Xb as parent only if Xb ≺Xa. The A* approach requires the h function to be admissible. The function h is admissible if the estimated cost is never greater than the true cost to the goal state. Our approach satisfies this property since the true cost of each step (score of chosen parent set for X≺i+1) is always equal to or greater than the estimated one (the score of the best selectable parent set for X≺i+1). The previous discussion implies that h is consistent, meaning that for any state S and its successor T, h(S) ≤h(T) + c(S, T), where c(S, T) is the cost of the edges added in T. The function f is monotonically non-decreasing on any path, and the algorithm is guaranteed to find the optimal path as long as the goal state is reachable. Additionally there is no need to process a node more than once, as no node will be explored a second time with a lower cost. 3.2 k-G A very high number of variables might prevent the use of k-A*. For those cases we propose k-G as a greedy alternative approach, which chooses at each step the best local parent set. Given the set of existing k-clique in K as KC, we choose as parent set for X≺i: ΠX≺i = argmax π⊂c,c∈KC score(π) . 3.3 Space of learnable DAGs A reverse topological order is an order {v1, ...vn} over the vertexes V of a DAG in which each vi appears before its parents Πi. The search space of our algorithms is restricted to the DAGs whose reverse topological order, when used as variable elimination order, has treewidth k. This prevents recovering DAGs which have bounded treewidth but lack this property. We start by proving by induction that the reverse topological order has treewidth k in the DAGs recovered by our algorithms. Consider the incremental construction of the DAG previously discussed. The initial DAG Gk+1 is induced over k + 1 variables; thus every elimination ordering has treewidth bounded by k. For the inductive case, assume that Gi−1 satisfies the property. Consider the next variable in the order, X≺i, where i ∈{k + 2, ..., n}. Its parent set Π≺i is a subset of a k-clique in Ki−1. The only neighbors of X≺i in the updated DAG Gi are its parents Π≺i. Consider performing variable elimination on the moral graph of Gi, using a reverse topological order. Then X≺i will be eliminated before Π≺i, without introducing fill-in edges. Thus the treewidth associated to any reverse topological order is bounded by k. This property inductively applies to the addition also of the following nodes up to X≺n. 4 Inverted trees An example of DAG non recoverable by our algorithms is the specific class of polytrees that we call inverted trees, that is, DAGs with out-degree equal to one. An inverted tree with m levels and treewidth k can be built as follows. Take the root node (level one) and connect it to k child nodes (level two). Connect each node of level two to k child nodes (level three). Proceed in this way up to the m-th level and then invert the direction of all the arcs. Figure 1 shows an inverted tree with k=2 and m=3. It has treewidth two, since its moral graph is constituted by the cliques {A,B,E}, {C,D,F}, {E,F,G}. The treewidth associated to the reverse topological order is instead three, using the order G, F, D, C, E, A, B. A B C D E F G Figure 1: Example of inverted tree. If we run our algorithms with bounded treewidth k=2, it will be unable to recover the actual inverted tree. It will instead identify a high-scoring DAG whose reverse topological order has treewidth 2. 4 Experiments We compare k-A*, k-G, S2, S2+ and TWILP in various experiments. We compare them through an indicator which we call W-score: the percentage of worsening of the BIC score of the selected treewidth-bounded method compared to the score of the Gobnilp solver Cussens (2011). Gobnilp achieves higher scores than the treewidth-bounded methods since it has no limits on the treewidth. Let us denote by G the BIC score achieved by Gobnilp and by T the BIC score obtained by the given treewidth-bounded method. Notice that both G and T are negative. The W-score is W = G−T G . W stands for worsening and thus lower values of W are better. The lowest value of W is zero, while there is no upper bound. We adopt BIC as a scoring function. The reason is that an algorithm for approximate exploration of the parent sets (Scanagatta et al., 2015) allowing high in-degree even on large domains exists at the moment only for BIC. 4.1 Parent set score exploration Before performing structural learning it is necessary to compute the scores of the candidate parent sets for each node (parent set exploration). The different structural learning methods are then provided with the same score of the parent sets. A treewidth k implies that one should explore all the parent sets up to size k; thus the complexity of parent set exploration increases exponentially with the treewidth. To let the parent set exploration scale efficiently with large treewidths and large number of variables we apply the approach of Scanagatta et al. (2015). It guides the exploration towards the most promising parent sets (with size up to k) without scoring them all. This is done on the basis of an approximated score function that is computed in constant time. The actual score of the most promising parent sets is eventually computed. We allow 60 seconds of time for the computation of the scores of the parent set of each variable, in each data set. 4.2 Our implementation of S2 and S2+ Here we provide some details of our implementation of S2 and S2+. The second phase of both S2 and S2+ looks for a DAG whose moralization is a subgraph of a chosen k-tree. For this task Nie et al. (2014) adopt an approximate approach based on partial order sampling (Algorithm 2). We found that using Gobnilp for this task yields consistently slightly higher scores; thus we adopt this approach in our implementation. We believe that it is due to the fact that constraining the structure optimization to a subjacent graph of a k-tree results in a small number of allowed arcs for the DAG. Thus our implementation of S2 and S2+ finds the highest-scoring DAG whose moral graph is a subgraph of the provided k-tree. 5 4.3 Learning inverted trees As already discussed our approach cannot learn an inverted tree with k parents per node if the given bounded treewidth is k. In this section we study this worst-case scenario. We start with treewidth k = 2. We consider the number of variables n ∈{21, 41, 61, 81, 101}. For each value of n we generate 5 different inverted trees. To generate as inverted tree we first select a root variable X and add k parents to it as ΠX; then we continue by randomly choosing a leaf of the graph (at a generic iteration, there are leaves at different distance from X) and adding k parents to it, until the the graph contains n variables. All variables are binary and we sample their conditional probability tables from a Beta(1,1). We sample 10,000 instances from each generated inverted tree. We then perform structural learning with k-A*, k-G, S2, S2+ and TWILP setting k = 2 as limit on the treewidth. We allow each method to run for ten minutes. S2, S2+ and TWILP could in principle recover the true structure, which is prevented to our algorithms. The results are shown in Fig.2. Qualitatively similar results are obtained repeating the experiments with k = 4. 20 30 40 50 60 70 80 90 100 0 0.05 0.1 Number of variables W-score S2 TWILP S2+ k-G k-A* Figure 2: Structural learning results when the actual DAGs are inverted trees (k=2). Each point represent the mean W-score over 5 experiments. Lower values of the W-score are better. Despite the unfavorable setting, both k-G and k-A* yield DAGs with higher score than S2, S2+ and TWILP consistently for each value of n. For n = 20 they found a close approximation to the optimal graph. S2, S2+ and TWILP found different structures, with close score. Thus the limitation of the space of learnable DAGs does not hurt the performance of k-G and k-A*. In fact S2 could theoretically recover the actual DAG, but this is not feasible in practice as it requires a prohibitive number of samples from the space of k-trees. The exact solver TWILP was unable to find the exact solution within the time limit; thus it returned a best solution achieved in the time limit. S2 S2+ k-G k-A* Iterations 803150 3 7176 66 Median -273600 -267921 -261648 -263250 Max -271484 -266593 -258601 -261474 Table 1: Statistics of the solutions yielded by different methods on an inverted tree (n = 100, k = 4). We further investigate the differences between methods in Table 1. Iterations is the number of proposed solutions; for S2 and S2+ it corresponds to the number of explored k-trees, while for k-G and k-A* it corresponds to the number of explored orders. During the execution, S2 samples almost one million k-trees. Yet it yields the lowest-scoring DAGs among the different methods. This can be explained considering that a randomly sampled k-tree has a low chance to cover a high-scoring DAG. S2+ recovers only a few k-trees, but their scores are higher than those of S2. Thus the informative score is effective at driving the search for good k-trees; yet it does not scale on large data sets as we will see later. As for our methods, k-G samples a larger number of orders than k-A* does and this allows it to achieve higher scores, even if it sub-optimally deals with each single order. Such statistics show a similar pattern also in the next experiments. 6 DATASET VAR. GOBNILP TWILP S2 S2+ k-G k-A* nursery 9 -72159 −72159 −72159 −72159 −72159 −72159 breast 10 -2698 −2698 −2698 −2698 −2698 −2698 housing 14 -3185 -3213 -3252 -3247 -3206 −3203 adult 15 -200142 -200340 -201235 -200926 -200431 −200363 letter 17 -181748 -190086 -189539 -186815 -183369 −183241 zoo 17 -608 -620 -620 -619 -615 −613 mushroom 22 -53104 -68298 -68670 -64769 -57021 −55785 wdbc 31 -6919 -7190 -7213 -7209 -7109 −7088 audio 62 -2173 -2277 -2283 -2208 -2201 −2185 community 100 -77555 -107252 -88350 -82633 −82003 hill 100 -1277 -1641 -1427 -1284 −1279 Table 2: Comparison of the BIC scores yielded by different algorithms on the data sets analyzed by Nie et al. (2016). The highest-scoring solution with limited treewidth is boldfaced. In the first column we report the score obtained by Gobnilp without bound on the treewidth. 4.4 Small data sets We now present experiments on the data sets considered by Nie et al. (2016). They involve up to 100 variables. We set the bounded treewidth to k = 4. We allow each method to run for ten minutes. We perform 10 experiments on each data set and we report the median scores in Table 2. On the smallest data sets all methods (including Gobnilp) achieve the same score. As the data sets becomes larger, both k-A* and k-G achieve higher scores than S2, S2+ and TWILP (which does not achieve the exact solution). Between our two novel algorithms, k-A* has a slight advantage over k-G. 4.5 Large data sets We now consider 10 large data sets (100 ≤n ≤400) listed in Table 3. We no longer run TWILP, as it is unable to handle this number of variables. Data set n Data set n Data set n Data set n Data set n Audio 100 Netflix 100 Retail 135 Andes 223 Pumsb-star 163 Jester 100 Accidents 111 Kosarek 190 MSWeb 294 DNA 180 Table 3: Large data sets sorted according to the number of variables. k-A* S2 S2+ k-G 29/20/24 30/30/29 30/30/30 k-A* 29/27/20 29/27/21 S2 12/13/30 Table 4: Result on the 30 experiments on large data sets. Each cell report how many times the row algorithm yields a higher score than the column algorithm for treewidth 2/5/8. For instance k-G wins on all the 30 data sets against S2+ for each considered treewidth. We consider the following treewidths: k ∈{2, 5, 8}. We split each data set randomly into three subsets. Thus for each treewidth we run 10·3=30 structural learning experiments. We let each method run for one hour. For S2+, we adopt a more favorable approach, allowing it to run for one hour; if after one hour the first k-tree was not yet solved, we allow it to run until it has solved the first k-tree. In Table 4 we report how many times each method wins against another for each treewidth, out of 30 experiments. The entries are boldfaced when the number of victories of an algorithm over another is statistically significant (p-value <0.05) according to the sign-test. Consistently for any chosen treewidth, k-G is significantly better than any competitor, including k-A*; moreover, k-A* is significantly better than both S2 and S2+. 7 This can be explained by considering that k-G explores more orders than k-A*, as for a given order it only finds an approximate solution. The results suggest that it is more important to explore many orders instead of obtaining the optimal DAG given an order. 4.6 Very large data sets Eventually we consider 14 very large data sets, containing between 400 and 10000 variables. We split each algorithm in three subsets. We thus perform 14·3=42 structural learning experiments with each algorithm. We include three randomly-generated synthetic data sets containing 2000, 4000 and 10000 variables respectively. These networks have been generated using the software BNGenerator 4. Each variable has a number of states randomly drawn from 2 to 4 and a number of parents randomly drawn from 0 to 6. Data set n Data set n Data set n Data set n Data set n Diabets 413 EachMovie 500 Reuters-52 889 BBC 1058 R4 4000 Pigs 441 Link 724 C20NG 910 Ad 1556 R10 10000 Book 500 WebKB 839 Munin 1041 R2 2000 Table 5: Very large data sets sorted according to the number n of variables. We let each method run for one hour. The only two algorithms able to cope with these data sets are k-G and S2. For all the experiments, both k-A* and S2+ fail to find even a single solution in the allowed time limit; we verified this is not due to memory issues. Among them, k-G wins 42 times out of 42; this dominance is clearly significant. This result is consistently found under each choice of treewidth (k =2, 5, 8). On average, the improvement of k-G over S2 fills about 60% of the gap which separates S2 from the unbounded solver. k-G(2) k-G(5) k-G(8) S2(2) S2(5) S2(8) 10−1 100 101 102 W-score Figure 3: Boxplots of the W-scores, summarizing the results over 14·3=42 structural learning experiments on very large data sets. Lower W-scores are better. The y-axis is shown in logarithmic scale. In the label of the x-axis we also report the adopted treewidth for each method: 2, 5 or 8. The W-scores of such 42 structural learning experiments are summarized in Figure 3. For both S2 and k-G, a larger treewidth allows to recover a higher-scoring graph. In turn this decreases the W-score. However k-G scales better than S2 with respect to the treewidth; its W-score decreases more sharply with the treewidth. For S2, the difference between the treewidth seems negligible from the figure. This is due to the fact that the graph learned are actually sparse. Further experimental documentation is available, including how the score achieved by the algorithms evolve with time, are available from http://blip.idsia.ch. 5 Conclusions Our novel approaches for treewidth-bounded structure learning scale effectively with both in the number of variables and the treewidth, outperforming the competitors. Acknowledgments Work partially supported by the Swiss NSF grants 200021_146606 / 1 and IZKSZ2_162188. 4http://sites.poli.usp.br/pmr/ltd/Software/BNGenerator/ 8 References Berg J., Järvisalo M., and Malone B. Learning optimal bounded treewidth Bayesian networks via maximum satisfiability. In AISTATS-14: Proceedings of the 17th International Conference on Artificial Intelligence and Statistics, 2014. Cussens J. Bayesian network learning with cutting planes. In UAI-11: Proceedings of the 27th Conference Annual Conference on Uncertainty in Artificial Intelligence, pages 153–160. AUAI Press, 2011. Elidan G. and Gould S. Learning bounded treewidth Bayesian networks. In Advances in Neural Information Processing Systems 21, pages 417–424. Curran Associates, Inc., 2009. Korhonen J. H. and Parviainen P. Exact learning of bounded tree-width Bayesian networks. In Proc. 16th Int. Conf. on AI and Stat., page 370–378. JMLR W&CP 31, 2013. Kwisthout J. H. P., Bodlaender H. L., and van der Gaag L. C. The necessity of bounded treewidth for efficient inference in Bayesian networks. In ECAI-10: Proceedings of the 19th European Conference on Artificial Intelligence, 2010. Nie S., Mauá D. D., de Campos C. P., and Ji Q. Advances in learning Bayesian networks of bounded treewidth. In Advances in Neural Information Processing Systems, pages 2285–2293, 2014. Nie S., de Campos C. P., and Ji Q. Learning Bounded Tree-Width Bayesian Networks via Sampling. In ECSQARU-15: Proceedings of the 13th European Conference on Symbol and Quantitative Approaches to Reasoning with Uncertainty, pages 387–396, 2015. Nie S., de Campos C. P., and Ji Q. Learning Bayesian networks with bounded treewidth via guided search. In AAAI-16: Proceedings of the 30th AAAI Conference on Artificial Intelligence, 2016. Parviainen P., Farahani H. S., and Lagergren J. Learning bounded tree-width Bayesian networks using integer linear programming. In Proceedings of the 17th International Conference on Artificial Intelligence and Statistics, 2014. Patil H. P. On the structure of k-trees. Journal of Combinatorics, Information and System Sciences, pages 57–64, 1986. Scanagatta M., de Campos C. P., Corani G., and Zaffalon M. Learning Bayesian Networks with Thousands of Variables. In NIPS-15: Advances in Neural Information Processing Systems 28, pages 1855–1863, 2015. Teyssier M. and Koller D. Ordering-based search: A simple and effective algorithm for learning Bayesian networks. CoRR, abs/1207.1429, 2012. 9 | 2016 | 511 |
6,452 | Unsupervised Learning from Noisy Networks with Applications to Hi-C Data Bo Wang⇤1, Junjie Zhu2, Oana Ursu3, Armin Pourshafeie4, Serafim Batzoglou1 and Anshul Kundaje3,1 1Department of Computer Science, Stanford University 2Department of Electrical Engineering, Stanford University 3Department of Genetics, Stanford University 4Department of Physics, Stanford University Abstract Complex networks play an important role in a plethora of disciplines in natural sciences. Cleaning up noisy observed networks poses an important challenge in network analysis. Existing methods utilize labeled data to alleviate the noise the noise levels. However, labeled data is usually expensive to collect while unlabeled data can be gathered cheaply. In this paper, we propose an optimization framework to mine useful structures from noisy networks in an unsupervised manner. The key feature of our optimization framework is its ability to utilize local structures as well as global patterns in the network. We extend our method to incorporate multiresolution networks in order to add further resistance in the presence of high-levels of noise. The framework is generalized to utilize partial labels in order to further enhance the performance. We empirically test the effectiveness of our method in denoising a network by demonstrating an improvement in community detection results on multi-resolution Hi-C data both with and without Capture-C-generated partial labels. 1 Introduction Complex networks emerge in a plethora of disciplines including computer science, social sciences, biology and etc. They entail non-trivial topological features and patterns critical to understanding interactions within complicated systems. However, observed networks from data are typically noisy due to imperfect measurements. The adverse effects of noise pose a critical challenge in unraveling clear structures and dynamics in the networks. Therefore, network denoising can strongly influence how the networks are interpreted, and can significantly improve the outcome of down-stream analysis such as global and local community detection. The goal of community detection is to identify meaningful structures/communities underlying the provided samples in an unsupervised manner. While the performance of community detection algorithms can worsen due to noise [1], one may use prior knowledge about the structure of the communities, such as the presence of clusters, to recover local networks [25]. In addition to the special structure that one may expect in a network, a small portion of high confidence links may be available. The combination of the special structure and the confident links can be used to denoise the network that might include both noisy or missing links. How to incorporate multiple sources of information to construct a network has been widely studied in the context of data fusion or data aggregation [3]. Biology offers a special case where overall structure of the network of interest might be known from the science but the data may be riddled with noise. One example of this is the 3D structure, or folding, of DNA. In biology, this structure is important as, among other things, the DNA topology ⇤bowang87@stanford.edu 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. has been shown to have a fundamental impact on gene expression in biological processes [4]. For example, many genes are in 3D contact with genomic regions that are far away in the linear genome but close in 3D space. These genomic regions contain regulatory elements that control when the gene is active [5, 6, 34]. The rules by which regulatory elements come in contact with their target genes are still unclear [7]. While the exact mechanism for this selective interaction between the regulatory elements and the target genes is unknown, the 3D organization of the genome in domains of interaction seem to play a crucial role. Furthermore, topologically associated domains (TADs) [8], where local interactions are observed, are of potential biological interest as they have been shown to be conserved between mice and humans, which suggests an ancient root for higher order structures in the genome [8]. The interaction map of regulatory elements in a genome can be viewed as a network, where each node is a regulatory element and each link represents the interaction strength between two of the elements. In this context, we not only have prior knowledge about the types of structures in this interaction network, but we also have various types of noisy and incomplete observations of the links in this network based on recently-developed technologies. One approach to observe these links is Hi-C, an experiment which uses high-throughput sequencing to construct a 2D contact map measuring the frequency with which pairs of genomic regions co-localize in 3D space. The results of Hi-C experiments can be summarized at multiple resolutions (lower resolutions are obtained by binning genomic regions together), ranging from 1 kb to 1 Mb[8–10]. Higher resolution maps capture more fine grained location interactions but the background noise generated by random collisions can be larger [11]. Lower resolution maps have less noise, but at the cost of losing the exact localization of genomic contacts. In addition to Hi-C, there are other experiment variants such as 4C, 5C and Capture-C technologies, which provide a new window into detection of a small number of interaction links with high confidence [12–15], by focusing sequencing resources on a selected subset of contacts. For these experiments the increased confidence comes at the cost of not measuring the full contact map. Thus, the integration of multi-resolution noisy Hi-C data with high-confidence Capture-C data is not only an interesting problem in the context of general network densoising but it is also biologically relevant. 1.1 Related Work Many applications in biology utilize multiple measurements to construct a single biological network. General approaches such as [16] have relied on specific models to reveal structures from the multiple measurements. However, some biological networks do not fit these model assumptions (e.g. Gaussian). For example, while Hi-C data can be summarized at multiple resolutions, standard model assumptions are not appropriate for combining the resolutions. Furthermore, one may acquire a small subset of highly confident measurements. In the case of Hi-C data, this can be done through Capture-C [12, 13, 15] technologies. While matrix completion is a well studied problem [2] to recover missing measurements, the setting with Capture-C is slightly different. In particular, the number of highly confident entries for the n ⇥n adjacency matrix of rank r may be less than nr log n, which is suggested for matrix completion [2]. Additionally, such a method would not take advantage of the large amount of data available, albeit with higher noise, from different sources. A common application of a denoised networks is to more reliably detect biologically-relevant communities. General community detection methods have been used to find protein complexes [17, 18], genetically related subpopulations [19], like-minded individuals in a social network [20], and many other tasks [21, 22]. Aside from the all-purpose algorithms mentioned above, there are specialized algorithms for the problem of community detection in Hi-C data. Rao et al. define TADs using the specialized Arrowhead algorithm [10]. Cabreros et al. used a mixed-membership stochastic block model to discover communities in Hi-C data [23]. Their method can detect the number of communities or can be forced to find a specified number of communities. Dixon et. al defined a directionality index that quantifies the asymmetry between the upstream and downstream interaction bias for a position [8]. A hidden Markov model was subsequently used to detect biased states based on these scores [8]. 1.2 Our Contribution As mentioned above, Hi-C data can be represented by many different resolutions. Although the data and noise from these resolutions are not independent, the different resolutions still contain 2 information that can help denoise the data. We propose a model-free optimization framework to extract information from the different resolutions to denoise the Hi-C data. While generic community detection methods are limited to using only a single input network, our optimization framework is able to pool data from different resolutions, and produces a single denoised network. This framework allows us to apply community detection methods to multi-resolution Hi-C data. Furthermore, in special cases, a subset of the interaction network may be known with a high confidence using Capture-C [12]. To our knowledge, there is no algorithm with the capability of taking advantage of this highly confident set to improve the denoising of Hi-C data. Our framework is able to take a multi-resolution network in addition to the confident set of data to denoise the corresponding network. Applying our framework to datasets with simulated ground-truth communities derived from chromosomes 14 and 21 of GM12878 in [10], we find that our framework can indeed leverage the multiple sources of information to reveal the communities underlying the noisy and missing data. 2 Problem Setup 2.1 General Learning Framework Throughout this paper, we will use a real and symmetric n ⇥n matrix to represent a network on n nodes. Accordingly, the (i, j)th entry of the matrix will be used to denote the weight or intensity of a link between node i and node j. Suppose we want to construct a weighted network S 2 Rn⇥n from a noisy observation W 2 Rn⇥n on the same nodes, where the noise introduces false-positive and false-negative links. If the network of interest S is low rank, then this inherent structure can be used to denoise W. This intuition that the detected noisy matrix could lie near an underlying low-rank or sparse matrix is also key to subspace detection algorithms, such as Sparse Subspace Clustering [25] and Low-Rank Representation [26]. We use this intuition to formulate our optimization framework below: minimize −tr ! W >S " + λ L(S, F) + β||S||2 F (OPT1) with respect to S 2 Rn⇥n, F 2 Rn⇥C subject to F >F = IC, X j Sij = 1, Sij ≥0 for all (i, j), where L(S, F) = tr(F >(In −S)F), here λ, β > 0 are tuning parameters (see Appendix 7.3). F is an auxiliary C-dimensional variable (with C < n) and is constrained to consist of orthogonal columns. S is constrained to be a stochastic matrix and further regularized by the squared Frobenius norm, i.e. ||S||2 F . In order to represent the resulting denoised network, the solution S can be made symmetric by (S + S>)/2. In addition, the objective and constraints in (OPT1) ensure two key properties for S to represent a denoised network: Property (1): S complies well with the links in network W. The first term in the objective function of (OPT1) involves maximizing the Frobenius product of S and W, i.e., −tr(W >S) = − X i,j WijSij. so each link in S is consistent with W. Taking the sum of the element-wise products allows S to be invariant to scaling of W. Property (2): S is low rank and conveys cluster structures. The term L(S, F) in (OPT1) is an imposed graph regularization on S so that it is embedded in a low-dimensional space spanned by F. To see this, first note that (In −S) is the graph Laplacian of S as the row sums (and column sums) of S is 1. It can be shown that L(S, F) = tr(F >(In −S)F) = X i,j ||fi −fj||2 2Sij, where fi and fj are the ith and jth rows of F respectively. Thus, each row of F can be interpreted as a C-dimensional embedding of the corresponding node in the network. Here, || · ||2 denotes the `2-norm, so the minimization of L(S, F) enforces link Sij to capture the Euclidean distance of node i and node j in the vector space spanned by F. 3 2.2 Learning from multi-resolution networks The general graph denoising framework above can be easily extended to incorporate additional information. Suppose instead of a single observation W, we have m noisy observations or representations of the underlying network S. Denote these observations as W1, ..., Wm. We refer to this multi-resolution network as W, where each link in W contains m different ordered values. (This terminology is not only used to conveniently correspond to the Hi-C interaction maps at different resolutions, but it also helps to remind us that the noise in each network is not necessarily identical or stochastic.) A multi-resolution network consists of different representations of S and provides more modeling power than a single-resolution network [32]. We can use this additional information to extend (OPT1) to the following optimization problem: minimize −tr ✓⇣X ` ↵`W` ⌘> S ◆ + λ L(S, F) + β||S||2 F + γP(↵) (OPT2) with respect to S 2 Rn⇥n, F 2 Rn⇥C, ↵2 Rm subject to F >F = IC, X j Sij = 1, X ` ↵` = 1, Sij ≥0 for all (i, j), ↵` ≥0 for all `. where L(S, F) = tr(F >(In −S)F), P(↵) = X ` ↵` log ↵`, where λ, β, γ > 0 are tuning parameters (see Appendix 7.3). The vector ↵= [↵1, ..., ↵m]> weights the m observed networks W1, ..., Wm and needs to be learned from the data. The modification to the first term in the objective in (OPT1) from that in (OPT2) allows S to simultaneously conform with all of the networks according to their importance. To avoid overfitting with the weights or selecting a single noisy network, we regularize ↵via P(↵) in the objective of (OPT2). In our application, we chose P(↵) so that the entropy of ↵is high, but one may select other penalties for P(↵). (e.g. L1 or L2 penalties) While (OPT2) is non-convex with respect to all three variables S, L, ↵, the problem is convex with respect to each variable conditional on fixing the other variables. Therefore, we apply an alternating convex optimization method to solve this tri-convex problem efficiently. The three optimization problems are solved iteratively until all the solutions converge. The following explains how each variable is initialized and updated. (1) Initialization. The variables S, L and ↵are initialized as ↵(0) = 1 m1m, S(0) = X ` ↵(0) ` W`, F (0) = [v(0) 1 , ..., v(0) C ] where 1m is a length-m vector of ones, i.e, 1m = [1, ..., 1]>. The weight vector ↵is set to be a uniform vector to avoid bias, and S is initialized to be the sum of the individual observed networks Wi according to the initial weights. Finally, F is initialized to be the top C eigenvectors of S, denoted as v(0) 1 , ..., v(0) C . (2) Updating S with fixed F and ↵. When we minimize the objective function only with respect to the similarity matrix S in (OPT2), we can solve the equivalent problem: minimize − X i,j ⇣X ` ↵` (W`)i,j + λ(FF >)i,j ⌘ Si,j + β X i,j S2 i,j (OPT3) with respect to S 2 Rn⇥n subject to X j Sij = 1, Sij ≥0 for all (i, j). This optimization problem is clearly convex because the objective is quadratic in Si,j and the constraints are all linear. We used the KKT conditions to solve for the updates of S. Details of the solution are provided in Appendix 7.1. 4 (3) Updating F with fixed S and ↵. When we minimize the objective function only with respect to the similarity matrix F in (OPT2), we can solve the equivalent problem: minimize tr(F >(In −S)F) (OPT4) with respect to F 2 Rn⇥C subject to F >F = IC. This optimization problem can also be interpreted as solving the eigenvalue problem for (S −In) because the trace of F >(S −In)F is maximized when F is a set of orthogonal bases of the eigen-space associated with the C largest eigenvalues of (S −In). We used standard numerical toolboxes in MATLAB to solve for the eigenvectors. (4) Updating ↵with fixed F and S. Now treating S and F as parameters, the equivalent problem with respect to ↵becomes a simple linear programming problem: minimize − X ` ↵` X i,j(W`)i,jSi,j + γ X ` ↵` log ↵` (OPT5) with respect to ↵2 Rm subject to X ` ↵` = 1, ↵` ≥0 for all `. Using the optimality conditions, we derived a close-form solution for ↵` for each `: ↵` = exp ⇣P i,j(W`)i,jSi,j γ ⌘ P ` exp ⇣P i,j(W`)i,jSi,j γ ⌘, Details are provided in Appendix 7.2. (5) Termination. The alternating optimization terminates when all three variables S, F, and ↵converge. Even though alternating optimization techniques are widely-used heuristic approaches, the parameters converged in approximately 20 iterations in the applications we have considered. 2.3 Learning from multi-resolution networks and highly confidence links Now suppose in addition to a multi-resolution network, we are given noiseless (or highly confident) information about the presence of certain links in the network. More formally, we are given a set P, such that if a link (i, j) 2 P, then we know that it is almost surely a true positive link. If (i, j) /2 P, then we only know that this link was unobserved, and have no information whether or not it is present or absent in the true denoised network. In the applications we consider, there is typically a subset of nodes for which all of their incident links are unobserved. So if we consider a binary adjacency matrix on these nodes based on P, a number of columns (or rows) will indeed have all missing values. Therefore, the only information we have about these nodes are their incident noisy links in the multi-resolution network. The formulation in (OPT2) can easily incorporate the positive set P. For each node i, we denote Pi = {j : (i, j) 2 P} additional parameters and formulate an extended optimization problem minimize −f(S) −⌧tr ✓⇣X ` ↵`W` ⌘> S ◆ + λ L(S, F) + β||S||2 F + γP(↵) (OPT6) with respect to S 2 Rn⇥n, F 2 Rn⇥C, ↵2 Rm subject to F >F = IC, X j Sij = 1, X ` ↵` = 1, Sij ≥0 for all (i, j), ↵` ≥0 for all ` where f(S) = n X i=1 1 |Pi| X j2Pi Sij, L(S, F) and P(↵) follow from (OPT2). Notice that when applying alternating optimization to solve this problem, we can simply use the same approach used to solve (OPT2). The only change needed is to include f(S) in the objective of (OPT3) in order to update S. 5 3 Implementation Details 3.1 How to Determine C We provide an intuitive way to determine the number of communities, C, in our methods. The optimal value of C should be close to the true number of communities in the network. One possible approach to discover the number of groups is to analyze the eigenvalues of the weight matrix and searching for a drop in the magnitude of the eigenvalue gaps. However, this approach is very sensitive to the noise in the weight matrix therefore can be unstable in a noisy networks. We use an alternative approach by analyzing eigenvectors of the network, similar to [27]. Consider a network with C disjoint communities. It is well known that the eigenvectors of the network Laplacian form a full basis spanning the network subspace. Although presence of noise may cause this ideal case to fail, it can still shed light on community membership. Given a specific number of communities C, we aim to find an indication matrix Z(R) = XR, where X 2 Rn⇥C is the matrix of the top eigenvectors of the network Laplacian, and R 2 RC⇥C is a rotation matrix. Denote [M(R)]i = maxj[Z(R)]i,j. We search for R such that it minimizes the following cost function J(R) = X i,j [Z(R)]2 i,j [M(R)]2 i Minimizing this cost function over all possible rotations will provide the best alignment with the canonical coordinate system. This is done using the gradient descent scheme [27]. Instead of taking the number of communities to be the one providing the minimal cost as in [27], we seek the number of communities that result in the largest drop in the value of J(R). 3.2 Convergence Criterion The proposed method is an iterative algorithm. It is important to determine a convergence criterion to stop the iterations. Our method adopts a well-defined approach to decide convergence has been reached. Similar to spectral clustering [3], we use eigengap to measure the convergence of our method. Eigengap is defined as follows: eigengap(i) = λi+1 −λi (1) where λi is the i-th eigenvalue of the matrix S where we sort the eigenvalues in ascending order (λ1 λ2 . . . λn). For C clusters, we use eigengap(C) = λC+1 −λC. The intuition behind eigengap is that, if a similarity includes C perfectly strong clusters, then eigengap(C) should be near zero (which was proved in [28]). Due to the low-rank constraint in our optimization framework, we seek a small value of eigengap(C) for a good optimal value. We can set a stopping criterion for our method using eigengap(C) < T for a small threshold, T. However, due to the noise reaching a small threshold cannot be guaranteed, therefore, a practical stopping criterion adopted by our method is when eigengap(C) has stoped decreasing. In our experiments we have observed that, eigengap(C) usually decreases for around 10 iterations and then remains stable. 4 Experiments We apply the framework presented in (OPT6) to Hi-C and Capture-C data. As explained, detecting communities in these data has important scientific ramifications. Our denoising strategy can be part of the pipeline for discovering these communities. We evaluated our methods on real data and checked their robustness by adding additional noise and measuring performance. For the real data, we started with a ground truth of domains previously identified in the GM12878 cell line chromosomes 14 and 21 [10] , filtered to only contain domains that do not have ambiguous boundaries or that overlap due to noise in the ground truth, and stitched these together. We ran our algorithm using data at 8 different resolutions (5 kb,10kb, 25kb, 50kb, 100kb, 250kb, 500kb, 1Mb). A heat map of the highest and lowest resolution of the simulated data for chromosome 21 can be seen in Figure 1. Figure 2a shows a heat map of the denoised version of chromosome 14 using (OPT6). Below the heat map we show the ground truth blocks. 1) The baseline (Louvain algorithm [29]) was set to the clusters determined from the highest resolution Hi-C map (purple) . 2) The clustering improves after denoising this map using (OPT1) (orange). 3) Pooling data through the use of multi-resolution maps and (OPT2) further increases the size of the clusters. Finally 4) using the high confidence set, multi-resolution and (OPT6) (blue). 6 As mentioned earlier, in order to determine ground truth, we have chosen large disjoint blocks with low levels of noise. To test our algorithm in the presence of noise, we added distance dependent random noise to the network. We evaluated our performance by measuring the normalized mutual information (NMI) between the ground truth and the clusters resulting from the noisy data Figure 2b [30]. We see that while the NMI from the baseline falls rapidly the performance of our denoising algorithm stays relatively constant after a rapid (but significantly smaller) drop. Figure 2c shows the weights assigned to each resolution as noise is added. We see that the weight assigned to the highest resolution has a steep drop with a small amount of noise. This could partially explain the drop in the performance of baseline (which is computed from the high resolution data) in Figure 2b. To validate the obtained denoised network by our method, we check 2 features of domains: 1) increased covariation in genomic signals such as histone marks inside domains compared to across domains and 2) the binding of the protein CTCF at the boundaries of the domains (see Appendix 7.4). We quantify covariation in genomic signals by focusing on 3 histone marks (H3K4ME1, H3K4ME3 and H3K27AC), and computing the correlation of these across all pairs of genomic regions, based on measurements of these histone marks from 75 individuals [33]. We then compare the ratio between covariants with-in domains and covariants between domains . A higher ratio indicates better coherence of biological signals within domains while larger dispersions of signals between domains, therefore implying better quality of the identified domains. Second, we inspect another key biological phenomena that is binding strength of transcription factor CTCF on boundary regions [31, 35]. It has been observed that, CTCF usually binds with boundary of domains in HiC data. This serves as another way to validate the correctness of identified domain boundaries, by checking the fraction of domain boundaries that contain CTCF. Figure 2d shows that our method produces a higher ratio of specific histone marks and CTCF binding than the baseline, indicating better ability to detect biologically meaningful boundaries. In each experiment, we selected the number of communities C for clustering based on the implementation details in Section 3. The best C is highlighted in Figure 3a-b. The optimal C coincided with the true number of clusters, indicating that the selection criteria was well-suited for the two datasets. Furthermore, as shown in Figure 3c-d the alternating optimization in (OPT6) converged within 20 iterations according to the criteria in Section 3 where the eigen-gaps stabilized quickly. Figure 1: a) Heat map of data simulated from chromosome 21. The subclusters were chosen to be clearly distinguishable from each other (in order to have clear boundaries to determine the ground truth for the boundaries of the blocks). The blocks were subsequently stitched to each other. b) Simulated low resolution data. c) CaptureC network: these positions are treated as low-noise data. d) Denoised Network: (OPT6) was used to denoise the network using all 8 resolutions in addition to the Capture-C data in (c). 5 Conclusions and Future Work In this paper we proposed an unsupervised optimization framework to learn meaningful structures in a noisy network. We leverage multi-resolution networks to improve the robustness to noise by automatically learning weights for different resolutions. In addition, our framework naturally extends to incorporate partial labels. We demonstrate the performance of our approach using genomic interaction networks generated by noisy Hi-C data. In particular, we show how incorporating multiple Hi-C resolutions enhances the effectiveness in denoising the interaction networks. Given partial information from Capture-C data, we further denoise the network and discover more accurate community structures. In the future, it would be important to extend our method to whole genome Hi-C data to get a global view of the 3D structure of the genome. This will involve clever binning or partition of the genome to 7 H3K4ME1 H3K4ME3 H3K27AC CTCF Binding 0 0.2 0.4 0.6 0.8 1 1.2 1.4 1.6 1.8 2 Baseline Our Method (d)$Biology$Valida-on$ Figure 2: a) Denoised Network: heatmap of denoised network using with Hi-C and Capture-C according to (OPT6). The tracks below the heatmap indicate the division of the classified communities with respect to the ground truth. The use of multi-resolution Hi-C and capture-C achieves the best concordance with the ground truth. b) Clustering performance: The performance of the baseline degrades rapidly with the introduction of noise. Our method with various inputs perform significantly better than the baseline suggesting that denoising using our framework can significantly improve the task of clustering c) Weight Distribution: The weights (↵i) assigned to each resolution from the optimization in (OPT2). The noise increases the performance of the highest resolution matrix decreases rapidly at first. In response, the method rapidly decreases the weight for this matrix. d) Ratio between covariates: we used three specific histone marks and the CTCF binding sites as indicators of the accuracy in detecting the boundaries. Figure 3: a) - b) The gradient of J(R) over the number of communities C. The best C selected is based on the value that minimizes the gradient of J(R) (circled in red). c) - d) The eigen-gaps over the number of iterations in the optimization framework. The eigengaps stabilize at the same value within 20 iterations, indicating the optimization problem converges in only a few iterations. reduce the problem size to a more local level where clustering methods can reveal meaningful local structures. In addition, our current framework is very modular. Even though we demonstrate our approach with k-means clustering a module, other appropriate clustering or community detection algorithms can be substituted for this module for whole genome Hi-C analysis. Finally, it would be interesting to extend our approach to a semi-supervised setting where a subset of confident links are used to train a classifier for the missing links in Capture-C data. 6 Acknowledgments We would also like to thank Nasa Sinnott-Armstrong for initial advice on this project. JZ acknowledges support from Stanford Graduate Fellowship. AP was partially supported by Stanford Genome Training Program: NIH 5T32HG000044-17. AK was supported by the Alfred Sloan Foundation Fellowship. OU is supported by the HHMI International Students Research Fellowship. BW and SB were supported by NIH Sidow grant (1R01CA183904-01A1). 8 References [1] J. Yang, J. McAuley, and J. Leskovec Community detection in networks with node attributes IEEE International Conference on, pp. 1151-1156. (2013). [2] E. J. Candes and Y. Plan Matrix Completion With Noise. Proceedings of the IEEE 98, 925-936. (2010) [3] B. Wang, A. M. Mezlini, F. Demir, M. Fiume, Z. Tu, M. Brudno, B. Haibe-Kains and A. Goldenberg Similarity network fusion for aggregating data types on a genomic scale. Nat. Methods, 11, 333-337. (2014). [4] J. Dekker. Gene regulation in the third dimension. Science, 319(5871):1793-4. (2008). [5] L.A. Lettice, et al. A long-range Shh enhancer regulates expression in the developing limb and fin and is associated with preaxial polydactyly. Hum. Mol. Genet. , 12, 1725-1735. (2003). [6] Y. Qin, L.K. Kong, C. Poirier, C. Truong, P.A. Overbeek and C.E. Bishop Long-range activation of Sox9 in Odd Sex (Ods) mice. Hum. Mol. Genet., 13, 1213-1218. (2004). [7] W. de Laat, D. Duboule Topology of mammalian developmental enhancers and their regulatory landscapes. Nature, 502, pp. 499-506 (2013). [8] J. R. Dixon, S. Selvaraj, F. Yue, A. Kim, Y. Li, Y. Shen, M. Hu, J. S. Liu, B. Ren. Topological domains in mammalian genomes identified by analysis of chromatin interactions. Nature, 485:376380 (2012). [9] E. Lieberman-Aiden et al. Comprehensive Mapping of Long Range Interactions Reveals Folding Principles of the Human Genome. Science, 326.5950: 289293, (2009). [10] S. S. P. Rao et al. A 3D Map of the Human Genome at Kilobase Resolution Reveals Principles of Chromatin Looping. Cell, 159(7): 1665-1680, (2014). [11] Shaw P.J. Mapping chromatin conformation. F1000 Biol Rep. 2 doi: 10.3410/B2-18. (2010) [12] J. Dekker, K. Rippe, M. Dekker and N. Kleckner, Capturing Chromosome Conformation. Science 295, 1306 (2002). [13] Z. Zhao et al., Circular chromosome conformation capture (4C) uncovers extensive networks of epigenetically regulated intra- and interchromosomal interactions Nat. Genet. 38, 1341 (2006). [14] M. Simonis et al. Nuclear organization of active and inactive chromatin domains uncovered by chromosome conformation capture-onchip (4C) Nat. Genet. 38, 1348 (2006). [15] J. Dostie et al. Chromosome Conformation Capture Carbon Copy (5C): A massively parallel solution for mapping interactions between genomic elements Genome Res. 16, 1299 (2006). [16] J. Chiquet,Y. Grandvalet, and C. Ambroise. Inferring multiple graphical structures Statistics and Computing (2011) [17] E.M. Marcotte, M. Pellegrini, H.-L. Ng, D.W. Rice, T.O. Yeates, and D. Eisenberg. Detecting protein function and protein-protein interactions from genome sequences. Science, 285, pp 751-753, (1999). [18] J. Chen and B. Yuan. Detecting functional modules in the yeast protein protein interaction network. Bioinformatics, (2006). [19] J. K. Pritchard, M. Stephens, and P. Donnelly. Inference of Population Structure Using Multilocus Genotype Data. Genetics, (2000). [20] M. Girvan and M. E. J. Newman. Community structure in social and biological networks. PANS, 99(12):7821-7826, (2002). [21] J. Shi and J. Malik. Normalized cuts and image segmentation. TPAMI, 22:888-905, (1997). [22] G. Linden, B. Smith, and J. York. Amazon.com recommendations: Item-to-item collaborative filtering. IEEE Internet Computing, 7(1):76-80, (2003). [23] I. Cabreros, E. Abbe, and A. Tsirigos Detecting Community Structures in Hi-C Genomic Data. ArXiv e-prints 1509.05121 (2015). [24] S. S.P. Rao, et al. A 3D Map of the Human Genome at Kilobase Resolution Reveals Principles of Chromatin Looping. Cell 159, 2014. [25] Wang, Bo, and Tu, Zhuowen Sparse subspace denoising for image manifolds. Computer Vision and Pattern Recognition (CVPR), 2013. [26] G. Liu, Z. Lin, S. Yan, J. Sun, Y. Yu, and Y. Ma. Robust recovery of subspace structures by low-rank representation. TPAMI, (2013). [27] L. Zelnik-Manor and P. Perona. In L. K. Saul, Y. Weiss, and L. Bottou, Self-tuning spectral clustering. NIPS, pages 1601-1608. (2005). [28] U. Von Luxburg. A tutorial on spectral clustering. Statistics and computing 17.4 : 395-416 (2007). [29] V. D. Blondel et al. Fast unfolding of communities in large networks. Journal of statistical mechanics: theory and experiment 2008.10 : P10008 (2008). [30] S. Alexander, and J. Ghosh. Cluster ensembles—a knowledge reuse framework for combining multiple partitions. JMLR, (2003). [31] ENCODE Project Consortium An integrated encyclopedia of DNA elements in the human genome. Nature, (2012). [32] Wang, B., Jiang, J., Wang, W., Zhou, Z. H., and Tu, Z. Unsupervised metric fusion by cross diffusion. Computer Vision and Pattern Recognition, (2012). [33] Grubert, Fabian, et al. Genetic control of chromatin states in humans involves local and distal chromosomal interactions. Cell 162.5 (2015): 1051-1065. [34] Ernst, Jason, and Manolis Kellis. ChromHMM: automating chromatin-state discovery and characterization. Nature methods 9.3 (2012): 215-216. [35] Mifsud, Borbala, et al. Mapping long-range promoter contacts in human cells with high-resolution capture Hi-C. Nature genetics 47.6 (2015): 598-606. 9 | 2016 | 512 |
6,453 | Scan Order in Gibbs Sampling: Models in Which it Matters and Bounds on How Much Bryan He, Christopher De Sa, Ioannis Mitliagkas, and Christopher Ré Stanford University {bryanhe,cdesa,imit,chrismre}@stanford.edu Abstract Gibbs sampling is a Markov Chain Monte Carlo sampling technique that iteratively samples variables from their conditional distributions. There are two common scan orders for the variables: random scan and systematic scan. Due to the benefits of locality in hardware, systematic scan is commonly used, even though most statistical guarantees are only for random scan. While it has been conjectured that the mixing times of random scan and systematic scan do not differ by more than a logarithmic factor, we show by counterexample that this is not the case, and we prove that that the mixing times do not differ by more than a polynomial factor under mild conditions. To prove these relative bounds, we introduce a method of augmenting the state space to study systematic scan using conductance. 1 Introduction Gibbs sampling, or Glauber dynamics, is a Markov chain Monte Carlo method that draws approximate samples from multivariate distributions that are difficult to sample directly [9; 15, p. 40]. A major use of Gibbs sampling is marginal inference: the estimation of the marginal distributions of some variables of interest [8]. Some applications include various computer vision tasks [9, 23, 24], information extraction [7], and latent Dirichlet allocation for topic modeling [11]. Gibbs sampling is simple to implement and quickly produces accurate samples for many models, so it is widely used and available in popular libraries such as OpenBUGS [16], FACTORIE [17], JAGS [18], and MADlib [14]. Gibbs sampling (Algorithm 1) iteratively selects a single variable and resamples it from its conditional distribution, given the other variables in the model. The method that selects the variable index to sample (s in Algorithm 1) is called the scan order. Two scan orders are commonly used: random scan and systematic scan (also known as deterministic or sequential scan). In random scan, the variable to sample is selected uniformly and independently at random at each iteration. In systematic scan, a fixed permutation is selected, and the variables are repeatedly selected in that order. The existence of these two distinct options raises an obvious question—which scan order produces accurate samples more quickly? This question has two components: hardware efficiency (how long does each iteration take?) and statistical efficiency (how many iterations are needed to produce an accurate sample?). From the hardware efficiency perspective, systematic scans are clearly superior [21, 22]. Systematic scans have good spatial locality because they access the variables in linear order, which makes their iterations run faster on hardware. As a result, systematic scans are commonly used in practice. Comparing the two scan orders is much more interesting from the perspective of statistical efficiency, which we focus on for the rest of this paper. Statistical efficiency is measured by the mixing time, which is the number of iterations needed to obtain an accurate sample [15, p. 55]. The mixing times of random scan and systematic scan have been studied, and there is a longstanding conjecture [3; 15, p. 300] that systematic scan (1) never mixes more than a constant factor slower than random scan and (2) never mixes more than a logarithmic factor faster than random scan. This conjecture implies that the choice of scan order does not have a large effect on performance. 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. Algorithm 1 Gibbs sampler input Variables xi for 1 ≤i ≤n, and target distribution π Initialize x1, . . . , xn loop Select variable index s from {1, . . . , n} Sample xs from the conditional distribution Pπ Xs | X{1,...,n}\{s} end loop Recently, Roberts and Rosenthal [20] described a model in which systematic scan mixes more slowly than random scan by a polynomial factor; this disproves direction (1) of this conjecture. Independently, we constructed other models for which the scan order has a significant effect on mixing time. This raises the question: what are the true bounds on the difference between these mixing times? In this paper, we address this question and make the following contributions. • In Section 3, we study the effect of the variable permutation chosen for systematic scan on the mixing time. In particular, in Section 3.1, we construct a model for which a systematic scan mixes a polynomial factor faster than random scan, disproving direction (2) of the conjecture, and in Section 3.2, we construct a model for which the systematic scan with the worst-case permutation results in a mixing time that is slower by a polynomial factor than both the best-case systematic scan permutation and random scan. • In Section 4, we empirically verify the mixing times of the models we construct, and we analyze how the mixing time changes as a function of the permutation. • In Section 5, we prove a weaker version of the conjecture described above, providing relative bounds on the mixing times of random and systematic scan. Specifically, under mild conditions, different scan orders can only change the mixing time by a polynomial factor. To obtain these bounds, we introduce a method of augmenting the state space of Gibbs sampling so that the method of conductance can be applied to analyze its dynamics. 2 Related Work Recent work has made progress on analyzing the mixing time of Gibbs sampling, but there are still major limitations to our understanding. In particular, most results are only for specific models or for random scan. For example, mixing times are known for Mallow’s model [1, 4], and colorings of a graph [5] for both random and systematic scan, but these are not applicable to general models. On the other hand, random scan has been shown to mix in polynomial time for models that satisfy structural conditions – such as having close-to-modular energy functions [10] or having bounded hierarchy width and factor weights [2] – but corresponding results for for systematic scan are not known. The major exception to these limitations is Dobrushin’s condition, which guarantees O(n log n) mixing for both random scan and systematic scan [6, 13]. However, many models of interest with close-to-modular energy functions or bounded hierarchy width do not satisfy Dobrushin’s condition. A similar choice of scan order appears in stochastic gradient descent (SGD), where the standard SGD algorithm uses random scan, and the incremental gradient method (IGM) uses systematic scan. In contrast to Gibbs sampling, avoiding “bad permutations” in the IGM is known to be important to ensure fast convergence [12, 19]. In this paper, we bring some intuition about the existence of bad permutations from SGD to Gibbs sampling. 3 Models in Which Scan Order Matters Despite a lack of theoretical results regarding the effect of scan order on mixing times, it is generally believed that scan order only has a small effect on mixing time. In this section, we first define relevant terms and state some common conjectures regarding scan order. Afterwards, we give several counterexamples showing that the scan order can have asymptotic effects on the mixing time. The total variation distance between two probability distributions µ and ν on Ωis [15, p. 47] ∥µ −ν∥TV = max A⊆Ω|µ(A) −ν(A)|. 2 Table 1: Models and Approximate Mixing Times Model tmix(R) min α tmix(Sα) max α tmix(Sα) Sequence of Dependencies n2 n n2 Two Islands 2n 2n n2n Discrete Pyramid [20] n n3 n3 Memorize and Repeat n3 n2 n2 Soft Dependencies n3/2 n n2 The mixing time is the minimum number of steps needed to guarantee that the total variation distance between the true and estimated distributions is below a given threshold ϵ from any starting distribution. Formally, the mixing time of a stochastic process P with transition matrix P (t) after t steps and stationary distribution π is [15, p. 55] tmix(P, ϵ) = min t : max µ ∥P (t)µ −π∥TV ≤ϵ , where the maximum is taken over the distribution µ of the initial state of the process. When comparing the statistical efficiency of systematic scan and random scan, it would be useful to establish, for any systematic scan process S and random scan process R on the same n-variable model, a relative bound of the form F1(ϵ, n, tmix(R, ϵ)) ≤tmix(S, ϵ) ≤F2(ϵ, n, tmix(R, ϵ)) (1) for some functions F1 and F2. Similarly, to bound the effect that the choice of permutation can have on the mixing time, it would be useful to know, for any two systematic scan processes Sα and Sβ with different permutations on the same model, that for some function F3, tmix(Sα, ϵ) ≤F3(ϵ, n, tmix(Sβ, ϵ)). (2) Diaconis [3] and Levin et al. [15, p. 300] conjecture that systematic scan is never more than a constant factor slower or a logarithmic factor faster than random scan. This is equivalent to choosing F1(ϵ, n, t) = C1(ϵ)·t·(log n)−1 and F2(ϵ, n, t) = C2(ϵ)·t in the inequality in (1), for some functions C1 and C2. It is also commonly believed that all systematic scans mix at the same asymptotic rate, which is equivalent to choosing F3(ϵ, n, t) = C3(ϵ) · t in (2). These conjectures imply that using systematic scan instead of random scan will not result in significant consequences, at least asymptotically, and that the particular permutation used for systematic scan is not important. However, we show that neither conjecture is true by constructing models (listed in Table 1) in which the scan order has substantial asymptotic effects on mixing time. In the rest of this section, we go through two models in detail to highlight the diversity of behaviors that different scan orders can have. First, we construct the sequence of dependencies model, for which a single “good permutation” of systematic scan mixes faster, by a polynomial factor, than both random scan and systematic scans using most other permutations. This serves as a counterexample to the conjectured lower bounds (i.e. the choice of F1 and F3) on the mixing time of systematic scan. Second, we construct the two islands model, for which a small set of “bad permutations” mix very slowly in comparison to random scan and most other systematic scans. This contradicts the conjectured upper bounds (i.e. the choice of F2 and F3). For completeness, we also discuss the discrete pyramid model introduced by Roberts and Rosenthal [20], which contradicts the conjectured choice of F2. Table 1 lists several additional models we constructed: these models further explore the space of asymptotic comparisons among scan orders, but for brevity we defer them to the appendix. 3.1 Sequence of Dependencies The first model we describe is the sequence of dependencies model (Figure 1a), where we explore how fast systematic scan can be by allowing a specific good permutation to mix rapidly. The sequence of dependencies model achieves this by having the property that, at any time, progress towards mixing is only made if a particular variable is sampled; this variable is always the one that is chosen by the good permutation. As a result, while a systematic scan using the good permutation makes progress at 3 s0 s1 · · · si · · · sn x1 x2 xi−1 xi xn (a) Sequence of Dependencies Model b sx1 sx2 ... sxn sy1 sy2 ... syn x1 x2 xn y1 y2 yn ... ... ... ... Island x Island y (b) Two Islands Model s0 s1 s2 s3 · · · · · · · · · · · · · · · · · · · · · · · · sn x1 x2 x3 xn (c) Discrete Pyramid Model Figure 1: State space of the models. every step, both random scan and other systematic scans often fail to progress, which leads to a gap between their mixing times. Thus, this model exhibits two surprising behaviors: (1) one systematic scan is polynomially better than random scan and (2) systematic scans using different permutations have polynomial differences in mixing times. We now describe this model in detail. Variables There are n binary variables x1, . . . , xn. Independently, each variable has a very strong prior of being true. However, variable xi is never true unless xi−1 is also true. The unnormalized probability distribution is the following, where M is a very large constant.1 P(x) ∝ ( 0 if xi is true and xi−1 is false for some i ∈{2, . . . , n} M Pn i=1 xi otherwise State Space There are n + 1 states with non-zero probability: s0, . . . , sn, where si is the state where the first i variables are true and the remaining n −i variables are false. In the stationary distribution, sn has almost all of the mass due to the strong priors on the variables, so reaching sn is essentially equivalent to mixing because the total variation distance from the stationary distribution is equal to the mass not on sn. Notice that sampling xi will almost always move the state from si−1 to si, very rarely move it from si to si−1, and can have no other effect. The worst-case starting state is s0, where the variables must be sampled in the order x1, . . . , xn for this model to mix. Random Scan The number of steps needed to transition from s0 to s1 is distributed as a geometric random variable with mean n (variables are randomly selected, and specifically x1 must be selected). Similarly, the number of steps needed to transition from si−1 to si is distributed as a geometric random variable with mean n. In total, there are n transitions, so O(n2) steps are needed to mix. Best Systematic Scan The best systematic scan uses the order x1, x2, . . . , xn. For this scan, one sweep will reach sn no matter what the starting state is, so the mixing time is n. Worst Systematic Scan The worst systematic scan uses the order xn, xn−1, . . . , x1. The first sweep only uses x1, the second sweep only uses x2, and in general, any sweep only makes progress using one transition. Finally, in the n-th sweep, xn is used in the first step. Thus, this process mixes in n(n −1) + 1 steps, which is O(n2). 3.2 Two Islands With the sequence of dependencies model, we showed that a single good permutation can mix much faster than other scan orders. Next, we describe the two islands model (Figure 1b), which has the 1We discuss the necessary magnitude of M in Appendix B 4 opposite behavior: it has bad permutations that yield much slower mixing times. The two islands model achieves this by having two disjoint blocks of variables such that consecutively sampling two variables from the same block accomplishes very little. As a result, a systematic scan that uses a permutation that frequently consecutively samples from the same block mixes a polynomial factor slower than both random scan and most other systematic scans. We now describe this model in detail. Variables There are 2n binary variables grouped into two blocks: x1, . . . , xn and y1, . . . , yn. Conditioned on all other variables being false, each variable is equally likely to be true or false. However, the x variables and the y variables contradict each other. As a result, if any of the x’s are true, then all of the y’s must be false, and if any of the y’s are true, then all of the x’s must be false. The unnormalized probability distribution for this model is the following. P(x, y) ∝ ( 0 if ∃xi true and ∃yj true 1 otherwise (3) This model can be interpreted as a machine learning inference problem in the following way. Each variable represents whether the reasoning in some sentence is sound. The sentences corresponding to x1, . . . , xn and the sentences corresponding to y1, . . . , yn reach contradicting conclusions. If any variable is true, its conclusion is correct, so all of the sentences that reached the opposite conclusion must be not be sound, and their corresponding variables must be false. However, this does not guarantee that all other sentences that reached the same conclusion have sound reasoning, so it is possible for some variables in a block to be true while others are false. Under these assumptions alone, the natural way to model this system is with the two islands distribution in (3). State Space The states are divided into three groups: states in island x (at least one x variable is true), states in island y (at least one y variable is true), and a single bridge state b (all variables are false). The islands are well-connected internally, so the islands mix rapidly. but it is impossible to directly move from one island to the other – the only way to move from one island to the other is through the bridge. To simplify the analysis, we assume that the bridge state has very low mass.2 This allows us to assume that the chains always move off of the bridge when a variable is sampled. The bridge is the only way to move from one island to the other, so it acts as a bottleneck. As a result, the efficiency of bridge usage is critical to the mixing time. We will use bridge efficiency to refer to the probability that the chain moves to the other island when it reaches the bridge. Because mixing within the islands is rapid in comparison to the time needed to move onto the bridge, the mixing time is inversely proportional to the bridge efficiency of the chain. Random Scan In random scan, the variable selected after getting on the bridge is independent of the previous variable. As a result, with probability 1/2, the chain will move onto the other island, and with probability 1/2, the chain will return to the same island, so the bridge efficiency is 1/2. Best Systematic Scan Several different systematic scans achieve the fastest mixing time. One such scan is x1, y1, x2, y2, . . . , xn, yn. Since the sampled variables alternate between the blocks, if the chain moves onto the bridge (necessarily by sampling a variable from the island it was previously on), it will always proceed to sample a variable from the other block, which will cause it to move onto the other island. Thus, the bridge efficiency is 1. More generally, any systematic scan that alternates between sampling from x variables and sampling from y variables will have a bridge efficiency of 1. Worst Systematic Scan Several different systematic scans achieve the slowest mixing time. One such scan is x1, . . . , xn, y1, . . . , yn. In this case, if the chain moves onto the bridge, it will almost always proceed to sample a variable from the same block, and return to the same island. In fact, the only way for this chain to move across islands is if it moves from island x to the bridge using transition xn and then moves to island y using transition y1, or if it moves from island y to the bridge using transition yn and then moves to island x using transition x1. Thus, only 2 of the 2n transitions will cross the bridge, and the bridge efficiency is 1/n. More generally, any systematic scan that consecutively samples all x variables and then all y variables will have a bridge efficiency of 1/n. Comparison of Mixing Times The mixing times of the chains are inversely proportional to the bridge efficiency. As a result, random scan takes twice as long to mix as the best systematic scan, and mixes n/2 times faster than the worst systematic scan. 2We show that the same asymptotic result holds without this assumption in Appendix C. 5 3.3 Discrete Pyramid In the discrete pyramid model (Figure 1c) introduced by Roberts and Rosenthal [20], there are n binary variables xi, and the mass is uniformly distributed over all states where at most one xi is true. In this model, the mixing time of random scan, O(n), is asymptotically better than that of systematic scan for any permutation, which all have the same mixing time, O(n3). 4 Experiments In this section, we run several experiments to illustrate the effect of scan order on mixing times. First, in Figure 2a, we plot the mixing times of the models from Section 3 as a function of the number of variables. These experiments validate our results about the asymptotic scaling of the mixing time, as well as show that the scan order can have a significant effect on the mixing time for even small models. (Due to the exponential state space of the two islands model, we modify it slightly to make the computation of mixing times feasible: we simplify the model by only considering the states that are adjacent to the bridge, and assume that the states on each individual island mix instantly.) In the following experiments, we consider a modified version of the two islands model, in which the mass of the bridge state is set to 0.1 of the mass of the other states to allow the effect of scan order to be clear even for a small number of variables. Figure 2b illustrates the rate at which different scan orders explore this modified model. Due to symmetry, we know that half of the mass should be on each island in the stationary distribution, so getting half of the mass onto the other island is necessary for mixing. This experiment illustrates that random scan and a good systematic scan move to the other island quickly, while a bad systematic scan requires many more iterations. Figure 2c illustrates the effect that the permutation chosen for systematic scan can have on the mixing time. In this experiment, the mixing time for each permutation was found and plotted in sorted order. For the sequence of dependencies model, there are a small number of good permutations which mix very quickly compared to the other permutations and random scan. However, no permutation is bad compared to random scan. In the two islands model, as we would expect based on the analysis in Section 3, there are a small number of bad permutations which mix very slowly compared to the other permutations and random scan. Some permutations are slightly better than random scan, but none of the scan orders are substantially better. In addition, the mixing times for systematic scan approximately discretized due to the fact that mixing time depends so heavily on the bridge efficiency. 5 Relative Bounds on Mixing Times via Conductance In Section 3, we described two models for which a systematic scan can mix a polynomial factor faster or slower than random scan, thus invalidating conventional wisdom that the scan order does not have an asymptotically significant effect on mixing times. This raises a question of how different the mixing times of different scans can be. In this section, we derive the following weaker – but correct – version of the conjecture stated by Diaconis [3] and Levin et al. [15]. One of the obstacles to proving this result is that the systematic scan chain is not reversible. A standard method of handling non-reversible Markov chains is to study a lazy version of the Markov chain instead [15, p. 9]. In the lazy version of a Markov chain, each step has a probability of 1/2 of staying at the current state, and acts as a normal step otherwise. This is equivalent to stopping at a random time that is distributed as a binomial random variable. Due to the fact that systematic scan is not reversible, our bounds are on the lazy systematic scan, rather than the standard systematic scan. Theorem 1. For any random scan Gibbs sampler R and lazy systematic scan sampler S with the same stationary distribution π, their relative mixing times are bounded as follows. (1/2 −ϵ)2 tmix(R, ϵ) ≤2t2 mix(S, ϵ) log 1 ϵπmin (1/2 −ϵ)2 tmix(S, ϵ) ≤ 8n2 (minx,i Pi(x, x))2 t2 mix(R, ϵ) log 1 ϵπmin , where Pi is the transition matrix corresponding to resampling just variable i, and πmin is the probability of the least likely state in π. 6 0 25 50 0 0.5 1 n tmix (thousands) Sequence of Dependencies 0 25 50 n Two Islands 0 25 50 n Discrete Pyramid (a) Mixing times for ϵ = 1/4. Best Systematic Worst Systematic Other Systematic Random True Value 0 25 50 75 100 0 0.25 0.5 Iterations (thousands) Mass on Island Two Islands (n = 10) (b) Marginal island mass over time. 0 25 50 75 100 0 50 100 150 Percentile tmix Sequence of Dependencies (n = 10) 0 25 50 75 100 0 1 2 3 Percentile tmix (thousands) Two Islands (n = 6) (c) Sorted mixing times of different permutations (ϵ = 1/4). Figure 2: Empirical analysis of the models. Under mild conditions, namely ϵ being fixed and the quantities log(π−1 min) and (minx,i Pi(x, x))−1 being at most polynomial in n, this theorem implies that the choice of scan order can only affect the mixing time by up to polynomial factors in n and tmix. We now outline the proof of this theorem and include full proofs in Appendix D. In the two islands models, the mixing time of a scan order was determined by its ability to move through a single bridge state that restricted flow. This suggests that a technique with the ability to model the behavior of this bridge state is needed to bound the relative mixing times of different scans. Conductance, also known as the bottleneck ratio, is a topological property of Markov chains used to bound mixing times by considering the flow of mass around the model [15, p. 88]. This ability to model bottlenecks in a Markov chain makes conductance a natural technique both for studying the two islands model and bounding mixing times in general. More formally, consider a Markov chain on state space Ωwith transition matrix P and stationary distribution π. The conductance of a set S and of the whole chain are respectively defined as Φ(S) = P x∈S,y /∈S π(x)P(x, y) π(S) Φ⋆= min S:π(S)≤1 2 Φ(S). Conductance can be directly applied to analyze random scan. Let Pi be the transition matrix corresponding to sampling variable i. The state space Ωis used without modification, and the transition matrix is P = 1 n Pn i=1 Pi. The stationary distribution is the expected target distribution π. On the other hand, conductance cannot be directly applied to systematic scan. Systematic scan is not a homogeneous Markov chain because it uses a sequence of transition matrices rather than a single transition matrix. One standard method of converting systematic scan into a homogeneous Markov chain is to consider each full scan as one step of a Markov chain. However, this makes it difficult to compare with random scan because it completely changes which states are connected by single steps of the transition matrix. To allow systematic and random scan to be compared more easily, we introduce an alternative way of converting systematic scan to a homogeneous Markov chain by augmenting the state space. The augmented state space is Ψ = Ω× [n], which represents an ordered pair of the normal state and the index of the variable to be sampled. The transition probability is P ((x, i), (y, j)) = Pi(x, y)s(i, j), where s(i, j) = I[i + 1 ≡j (mod n)] is an indicator that shows if the correct variable will be sampled next. 7 Additionally, augmenting the state space for random scan allows easier comparison with systematic scan in some cases. For augmented random scan, the state space is also Ψ = Ω× [n], the same as for systematic scan. The transition probability is P ((x, i), (y, j)) = 1 nPi(x, y), which means that the next variable to sample is selected uniformly. The stationary distributions of the augmented random scan and systematic scan chains are both π ((x, i)) = n−1π(x). Because the state space and stationary distribution are the same, augmented random scan and augmented systematic scan can be compared directly, which lets us prove the following lemma. Lemma 1. For any random scan Gibbs sampler and systematic scan sampler with the same stationary distribution π, let ΦRS denote the conductance of the random scan process, let ΦRS-A denote the conductance of the augmented random scan process, and let ΦSS-A denote the conductance of the augmented systematic scan process. Then, 1 2n · min x,i Pi(x, x) · ΦRS-A ≤ΦSS-A ≤ΦRS. In Lemma 1, the upper bound states that the conductance of systematic scan is no larger than the conductance of random scan. We use this result in the proof of Theorem 1 to show that systematic scan cannot mix too much more quickly than random scan. To prove this upper bound, we show that for any set S under random scan, the set ˆS containing the corresponding augmented states for systematic scan will have the same conductance under systematic scan as S had under random scan. The lower bound in Lemma 1 states that the conductance of systematic scan is no smaller than a function of the conductance of augmented random scan. This function depends on the number of variables n and minx,i Pi(x, x), which is the minimum holding probability of any state. To prove this lower bound, we show that for any set S under augmented systematic scan, we can bound its conductance under augmented random scan. There are well-known bounds on the mixing time of a Markov chain in terms of its conductance, which we state in Theorem 2 [15, pp. 89, 235]. Theorem 2. For any lazy or reversible Markov chain, 1/2 −ϵ Φ⋆ ≤tmix(ϵ) ≤2 Φ2⋆ log 1 ϵπmin . It is straightforward to prove the result of Theorem 1 by combining the bounds from Theorem 2 with the conductance bounds from Lemma 1. 6 Conclusion We studied the effect of scan order on mixing times of Gibbs samplers, and found that for particular models, the scan order can have an asymptotic effect on the mixing times. These models invalidate conventional wisdom about scan order and show that we cannot freely change scan orders without considering the resulting changes in mixing times. In addition, we found bounds on the mixing times of different scan orders, which replaces a common conjecture about the mixing times of random scan and systematic scan. Acknowledgments The authors acknowledge the support of: DARPA FA8750-12-2-0335; NSF IIS-1247701; NSF CCF-1111943; DOE 108845; NSF CCF-1337375; DARPA FA8750-13-2-0039; NSF IIS-1353606; ONR N000141210041 and N000141310129; NIH U54EB020405; NSF DGE-114747; DARPA’s SIMPLEX program; Oracle; NVIDIA; Huawei; SAP Labs; Sloan Research Fellowship; Moore Foundation; American Family Insurance; Google; and Toshiba. The views and conclusions expressed in this material are those of the authors and should not be interpreted as necessarily representing the official policies or endorsements, either expressed or implied, of DARPA, AFRL, NSF, ONR, NIH, or the U.S. Government. 8 References [1] I. Benjamini, N. Berger, C. Hoffman, and E. Mossel. Mixing times of the biased card shuffling and the asymmetric exclusion process. Transactions of the American Mathematical Society, 357(8):3013–3029, 2005. [2] C. De Sa, C. Zhang, K. Olukotun, and C. Ré. Rapidly mixing gibbs sampling for a class of factor graphs using hierarchy width. In Advances in Neural Information Processing Systems, 2015. [3] P. Diaconis. Some things we’ve learned (about markov chain monte carlo). Bernoulli, 19(4):1294–1305, 2013. [4] P. Diaconis and A. Ram. Analysis of systematic scan metropolis algorithms using iwahori-hecke algebra techniques. The Michigan Mathematical Journal, 48(1):157–190, 2000. [5] M. Dyer, L. A. Goldberg, and M. Jerrum. Systematic scan for sampling colorings. The Annals of Applied Probability, 16(1):185–230, 2006. [6] M. Dyer, L. A. Goldberg, and M. Jerrum. Dobrushin conditions and systematic scan. Combinatorics, Probability and Computing, 17(06):761–779, 2008. [7] J. R. Finkel, T. Grenager, and C. Manning. Incorporating non-local information into information extraction systems by gibbs sampling. In Proceedings of the 43rd Annual Meeting on Association for Computational Linguistics, 2005. [8] A. E. Gelfand and A. F. M. Smith. Sampling-based approaches to calculating marginal densities. Journal of the American Statistical Association, 85(410):398–409, 1990. [9] S. Geman and D. Geman. Stochastic relaxation, gibbs distributions, and the bayesian restoration of images. IEEE Transactions on Pattern Analysis and Machine Intelligence, (6):721–741, 1984. [10] A. Gotovos, H. Hassani, and A. Krause. Sampling from probabilistic submodular models. In Advances in Neural Information Processing Systems, 2015. [11] T. L. Griffiths and M. Steyvers. Finding scientific topics. Proceedings of the National Academy of Sciences, 101(suppl 1):5228–5235, 2004. [12] M. Gürbüzbalaban, A. Ozdaglar, and P. Parrilo. Convergence rate of incremental gradient and newton methods. arXiv preprint arXiv:1510.08562, 2015. [13] T. P. Hayes. A simple condition implying rapid mixing of single-site dynamics on spin systems. In 47th Annual IEEE Symposium on Foundations of Computer Science, 2006. [14] J. M. Hellerstein, C. Ré, F. Schoppmann, D. Z. Wang, E. Fratkin, A. Gorajek, K. S. Ng, C. Welton, X. Feng, K. Li, et al. The madlib analytics library: or mad skills, the sql. Proceedings of the VLDB Endowment, 5 (12):1700–1711, 2012. [15] D. A. Levin, Y. Peres, and E. L. Wilmer. Markov chains and mixing times. American Mathematical Society, 2009. [16] D. Lunn, D. Spiegelhalter, A. Thomas, and N. Best. The bugs project: Evolution, critique and future directions. Statistics in medicine, 28(25):3049–3067, 2009. [17] A. McCallum, K. Schultz, and S. Singh. Factorie: Probabilistic programming via imperatively defined factor graphs. In Advances in Neural Information Processing Systems, 2009. [18] M. Plummer. Jags: A program for analysis of bayesian graphical models using gibbs sampling. In Proceedings of the 3rd international workshop on distributed statistical computing, 2003. [19] B. Recht and C. Ré. Beneath the valley of the noncommutative arithmetic-geometric mean inequality: conjectures, case-studies, and consequences. In Proceedings of the 25th Annual Conference on Learning Theory, 2012. [20] G. O. Roberts and J. S. Rosenthal. Surprising convergence properties of some simple gibbs samplers under various scans. International Journal of Statistics and Probability, 5(1):51–60, 2015. [21] A. Smola and S. Narayanamurthy. An architecture for parallel topic models. Proceedings of the VLDB Endowment, 3(1):703–710, 2010. [22] C. Zhang and C. Ré. Towards high-throughput gibbs sampling at scale: A study across storage managers. In Proceedings of the 2013 ACM SIGMOD International Conference on Management of Data, 2013. [23] Y. Zhang, M. Brady, and S. Smith. Segmentation of brain mr images through a hidden markov random field model and the expectation-maximization algorithm. IEEE Transactions on Medical Imaging, 20(1): 45–57, 2001. [24] S. C. Zhu, Y. Wu, and D. Mumford. Filters, random fields and maximum entropy (frame): Towards a unified theory for texture modeling. International Journal of Computer Vision, 27(2):107–126, 1998. 9 | 2016 | 513 |
6,454 | Deep Neural Networks with Inexact Matching for Person Re-Identification Arulkumar Subramaniam Indian Institute of Technology Madras Chennai, India 600036 aruls@cse.iitm.ac.in Moitreya Chatterjee Indian Institute of Technology Madras Chennai, India 600036 metro.smiles@gmail.com Anurag Mittal Indian Institute of Technology Madras Chennai, India 600036 amittal@cse.iitm.ac.in Abstract Person Re-Identification is the task of matching images of a person across multiple camera views. Almost all prior approaches address this challenge by attempting to learn the possible transformations that relate the different views of a person from a training corpora. Then, they utilize these transformation patterns for matching a query image to those in a gallery image bank at test time. This necessitates learning good feature representations of the images and having a robust feature matching technique. Deep learning approaches, such as Convolutional Neural Networks (CNN), simultaneously do both and have shown great promise recently. In this work, we propose two CNN-based architectures for Person Re-Identification. In the first, given a pair of images, we extract feature maps from these images via multiple stages of convolution and pooling. A novel inexact matching technique then matches pixels in the first representation with those of the second. Furthermore, we search across a wider region in the second representation for matching. Our novel matching technique allows us to tackle the challenges posed by large viewpoint variations, illumination changes or partial occlusions. Our approach shows a promising performance and requires only about half the parameters as a current state-of-the-art technique. Nonetheless, it also suffers from false matches at times. In order to mitigate this issue, we propose a fused architecture that combines our inexact matching pipeline with a state-of-the-art exact matching technique. We observe substantial gains with the fused model over the current state-of-the-art on multiple challenging datasets of varying sizes, with gains of up to about 21%. 1 Introduction Successful object recognition systems, such as Convolutional Neural Networks (CNN), extract “distinctive patterns” that describe an object (e.g. a human) in an image, when “shown” several images known to contain that object, exploiting Machine Learning techniques [1]. Through successive stages of convolutions and a host of non-linear operations such as pooling, non-linear activation, etc., CNNs extract complex yet discriminative representation of objects that are then classified into categories using a classifier, such as softmax. 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. Figure 1: Some common challenges in Person Re-Identification. 1.1 Problem Definition One of the key subproblems of the generic object recognition task is recognizing people. Of special interest to the surveillance and Human-Computer interaction (HCI) community is the task of identifying a particular person across multiple images captured from the same/different cameras, from different viewpoints, at the same/different points in time. This task is also known as Person Re-Identification. Given a pair of images, such systems should be able to decipher if both of them contain the same person or not. This is a challenging task, since appearances of a person across images can be very different due to large viewpoint changes, partial occlusions, illumination variations, etc. Figure 1 highlights some of these challenges. This also leads to a fundamental research question: Can CNN-based approaches effectively handle the challenges related to Person Re-Identification? CNN-based approaches have recently been applied to this task, with reasonable success [2, 3] and are amongst the most competitive approaches for this task. Inspired by such approaches, we explore a set of novel CNN-based architectures for this task. We treat the problem as a classification task. During training, for every pair of images, the model is told whether they are from the same person or not. At test time, the posterior classification probabilities obtained from the models are used to rank the images in a gallery image set in terms of their similarity to a query image (probe). In this work, we propose two novel CNN-based schemes for Person Re-Identification. Our first model hinges on the key observation that due to a wide viewpoint variation, the task of finding a match between the pixels of a pair of images needs to be carried out over a larger region, since “matching pixels” on the object may have been displaced significantly. Secondly, illumination variations might cause the absolute intensities of image regions to vary, rendering exact matching approaches ineffective. Finally, coupling these two solutions might provide a recipe for taking care of partial occlusions as well. We call this first model of ours, Normalized X-Corr. However, the flexibility of inexact (soft) matching over a wider search space comes at the cost of occasional false matches. To remedy this, we propose a second CNN-based model which fuses a state-of-the-art exact matching technique [2] with Normalized X-Corr. We hypothesize that proper training allows the two components of the fused network to learn complimentary patterns from the data, thus aiding the final classification. Empirical results show Normalized X-Corr to hold promise and the Fused network outperforming all baseline approaches on multiple challenging datasets, with gains of upto 21% over the baselines. In the next section, we touch upon relevant prior work. We present our methodology in Section 3. Sections 4 and 5 deal with the Experiments and the discussion of the obtained Results thereof. Finally, we conclude in Section 6, outlining some avenues worthy of exploration in the future. 2 Related Work In broad terms, we categorize the prior work in this field into Non-Deep and Deep Learning approaches. 2.1 Non-Deep Learning Approaches Person Re-Identification systems have two main components: Feature Extraction and Similarity Metric for matching. Traditional approaches for Person Re-Identification either proposed useful features, or discriminative similarity metrics for comparison, or both. 2 Typical features that have proven useful include color histograms and dense SIFT [4] features computed over local patches in the image [5, 6]. Farenzena et al. represent image patches by exploiting features that model appearance, chromatic content, etc [7]. Another interesting line of work on feature representation attempts to learn a bag-of-features (a.k.a. a dictionary)-based approach for image representation [8, 9]. Further, Prosser et al. show the effectiveness of learning a subspace for representing the data, modeled using a set of standard features [10]. While these approaches show promise, their performance is bounded by the ability to engineer good features. Our models, based on deep learning, overcome this handicap by learning a representation from the data. There is also a substantial body of work that attempts to learn an effective similarity metric for comparing images [11, 12, 13, 14, 15, 16]. Here, the objective is to learn a distance measure that is indicative of the similarity of the images. The Mahalanobis distance has been the most common metric that has been adopted for matching in person re-identification [5, 17, 18, 19]. Some other metric learning approaches attempt to learn transformations, which when applied to the feature space, aligns similar images closer together [20]. Yet other successful metric learning approaches are an ensemble of multiple metrics [21]. In contrast to these approaches, we jointly learn both features and discriminative metric (using a classifier) in a deep learning framework. Another interesting line of non-deep approaches for person re-identification have claimed novelty both in terms of features as well as matching metrics [22, 23]. Many of them rely on weighing the hand-engineered image features first, based on some measure such as saliency and then performing matching [6, 24, 25]. However, this is done in a non-deep framework unlike ours. 2.2 Deep Learning based Approaches There has been relatively fewer prior work based on deep learning for addressing the challenge of Person Re-Identification. Most deep learning approaches exploit the CNN-framework for the task, i.e. they first extract highly non-linear representations from the images, then they compute some measure of similarity. Yi et al. propose a Siamese Network that takes as input the image pair that is to be compared, performs 3 stages of convolution on them (with the kernels sharing weights), and finally uses cosine similarity to judge their extent of match [26]. Both of our models differ by performing a novel inexact matching of the images after two stages of convolution and then processing the output of the matching layer to arrive at a decision. Li et al. also adopt a two-input network architecture [3]. They take the product of the responses obtained right after the first set of convolutions corresponding to the two inputs and process its output to obtain a measure of similarity. Our models, on the other hand, are significantly deeper. Besides, Normalized X-Corr stands out by retaining the matching outcome corresponding to every candidate in the search space of a pixel rather than choosing only the maximum match. Ahmed et al. too propose a very promising architecture for Person Re-Identification [2]. Our models are inspired from their work and does incorporate some of their features, but we substantially differ from their approach by performing an inexact matching over a wider search space after two stages of convolution. Further, Normalized X-Corr has fewer parameters than Ahmed et al. [2]. Finally, our Fused model is a one of a kind deep learning architecture for Person Re-Identification. This is because a combination (fusion) of multiple deep frameworks has hitherto remained unexplored for this task. 3 Proposed Approach 3.1 Our Architecture In this work, we propose two architectures for Person Re-Identification. Both of our architectures are a type of “Siamese”-CNN model which take as input two images for matching and outputs the likelihood that the two images contain the same person. 3.1.1 Normalized X-Corr The following are the principal components of the Normalized X-Corr model, as shown in Fig 2. 3 37 12 NORMALIZED CORRELATION + RELU 37 25 1x1x1500 ⟶ 25 10 35 25 3x3x25 ⟶ 25 5 25 same different Fully connected Layer 500 5x5x3 ⟶ 20 CONV + RELU 156 56 20 20 28 78 MAXPOOL 2x2 5x5x20 ⟶ 25 CONV + RELU 74 24 25 25 12 37 MAXPOOL 2x2 5x5x3 ⟶ 20 CONV + RELU 156 56 20 20 28 78 MAXPOOL 2x2 5x5x20 ⟶ 25 CONV + RELU 74 25 25 12 37 MAXPOOL 2x2 1500 12 CONV + RELU MAXPOOL 2x2 CONV 17 24 Shared weights 60 60 160 160 Cross Patch Feature Aggregation Softmax layer Figure 2: Architecture of the Normalized X-Corr Model. 37 12 NORMALIZED CORRELATION + RELU 37 25 1x1x1500 ⟶ 25 10 35 25 3x3x25 ⟶ 25 5 25 same different 500 5x5x3 ⟶ 20 CONV + RELU 156 56 20 20 28 78 MAXPOOL 2x2 5x5x20 ⟶ 25 CONV + RELU 74 24 25 25 12 37 MAXPOOL 2x2 5x5x3 ⟶ 20 CONV + RELU 156 56 20 20 28 78 MAXPOOL 2x2 5x5x20 ⟶ 25 CONV + RELU 74 25 25 12 37 MAXPOOL 2x2 1500 12 CONV + RELU MAXPOOL 2x2 CONV 24 Shared weights 60 60 160 160 12 CROSS INPUT NEIGHBORHOOD + RELU 37 25 1x1x1250 ⟶ 25 10 35 25 3x3x25 ⟶ 25 5 25 1250 12 CONV + RELU MAXPOOL 2x2 CONV 17 500 37 17 Cross Patch Feature Aggregation Patch summary Fully connected Layer Softmax layer Figure 3: Architecture of the Fused Network Model. Tied Convolution Layers: Convolutional features have been shown to be effective representation of images [1, 2]. In order to measure similarity between the input images, the applied transformations must be similar. Therefore, along the lines of Ahmed et al., we perform two stages of convolutions and pooling on both the input images by passing them through two input pipelines of a “Siamese” Network, that share weights [2]. The first convolution layer takes as input images of size 60×160×3 and applies 20 learned filters of size 5×5×3, while the second one applies 25 learned filters of size 5×5×20. Both convolutions are followed by pooling layers, which reduce the output dimension by a factor of 2, and ReLU (Rectified Linear Unit) clipping. This gives us 25 maps of dimension 12×37 as output from each branch which are fed to the next layer. Normalized Correlation Layer: This is the first layer that captures the similarity of the two input images; subsequent layers build on the output of this layer to finally arrive at a decision as to whether the two images are of the same person or not. Different from [2, 3], we incorporate both inexact matching and wider search. Given two corresponding input feature maps X and Y , we compute the normalized correlation as follows. We start with every pixel of X located at (x, y), where x is along the width and y along the height (denoted as X(x, y)). We then create two matrices. The first is a 5×5 matrix representing the 5×5 neighborhood of X(x, y), while the second is the corresponding 5×5 neighborhood of Y centered at (a, b), where 1 ≤a ≤12 and y −2 ≤b ≤y + 2. Now, markedly different from Ahmed et al. [2], we perform inexact matching over a wider search space, by computing a Normalized Correlation between the two patch matrices. Given two matrices, E and F, whose elements are arranged as two N-dimensional vectors, the Normalized Correlation is given by: normxcorr(E, F) = PN i=1(Ei −µE)(Fi −µF ) (N −1).σE.σF , where µE, µF denotes the means of the elements of the 2 matrices, E and F respectively, while σE, σF denotes their respective standard deviations (a small ϵ = 0.01 is added to σE and σF to avoid division by 0). Interestingly, Normalized Correlation being symmetric, we need to model the computation only in one-way, thereby cutting down the number of parameters in subsequent layers. For every pair of 5×5 matrices corresponding to a given pixel in image X, we arrange the normalized correlation values in different feature maps. These feature maps preserve the spatial ordering of 4 pixels in X and are also 12×37 each, but their pixel values represent normalized correlation. This gives us 60 feature maps of dimension 12×37 each. Now similarly, we perform the same operation for all 25 pairs of maps that are input to the Normalized Correlation layer, to obtain an output of 1500, 12×37 maps. One subtle but important difference between our approach and that of Li et al. [3] is that we preserve every correlation output corresponding to the search space of a pixel, X(x, y), while they only keep the maximum response. We then pass these set of feature maps through a ReLU, to discard probable noisy matches. The mean subtraction and standard deviation normalization step incorporates illumination invariance, a step unaccounted for in Li et al. [3]. Thus two patches which differ only in absolute intensity values but are similar in the intensity variation pattern would be treated as similar by our models. The wider search space, compared to Ahmed et al. [2], gives invariance to large viewpoint variation. Further, performing inexact matching (correlation measure) over a wider search space gives us robustness to partial occlusions. Due to partial occlusions, a part(s) (P) of a person/object visible in one view may not be visible in others. Using a wider search space, our model looks for a part which is similar to the missing P within a wider neighborhood of P’s original location. This is justified since typically adjacent regions of objects in an image have regularity/similarity in appearance. e.g. Bottom and upper half of torso. Now, since we are comparing two different parts due to the occlusion of P, we need to perform flexible matching. Thus, inexact matching is used. Cross Patch Feature Aggregation Layers: The Normalized Correlation layer incorporates information from the local neighborhood of a pixel. We now seek to incorporate greater context information, to obtain a summarization effect. In order to do so, we perform 2 successive layers of convolution (with a ReLU filtered output) followed by pooling (by a factor of 2) of the output feature maps from the previous layer. We use 1×1×1500 convolution kernels for the first layer and 3×3×25 convolution kernels for the second convolution layer. Finally, we get 25 maps of dimension 5×17 each. Fully Connected Layers: The fully connected layers collate information from pixels that are very far apart. The feature map outputs obtained from the previous layer are reshaped into one long 2125-dimensional vector. This vector is fed as input to a 500-node fully connected layer, which connects to another fully connected layer containing 2 softmax units. The first unit outputs the probability that the two images are same and the latter, the probability that the two are different. One key advantage of the Normalized X-Corr model is that it has about half the number of parameters (about 1.121 million) as the model proposed by Ahmed et al. [2] (refer supplementary section for more details). 3.1.2 Fused Model While the Normalized X-Corr model incorporates inexact matching over a wider search space to handle important challenges such as illumination variations, partial occlusions, or wide viewpoint changes, however it also suffers from occasional false matches. Upon investigation, we found that these false matches tended to recur, especially when the background of the false matches had a similar appearance to the person being matched (see supplementary). For such cases, an exact matching, such as taking a difference and constraining the search window might be beneficial. We therefore fuse the model proposed by Ahmed et al. [2] with Normalized X-Corr to obtain a Fused model, in anticipation that it incorporates the benefits of both models. Figure 3 shows a representative diagram. We keep the tied convolution layers unchanged like before, then we fork off two separate pipelines: one for Normalized X-Corr and the other for Ahmed et. al.’s model [2]. The two separate pipelines output a 2125-dimensional vector each and then they are fused in a 1000-node fully connected layer. The outputs from the fully connected layer are then fed into a 2 unit softmax layer as before. 3.2 Training Algorithm All the proposed architectures are trained using the Stochastic Gradient Descent (SGD) algorithm, as in Ahmed et al. [2]. The gradient computation is fairly simple except for the Normalized Correlation layer. Given two matrices, E (from the first branch of the Siamese network) and F (from the second branch of the Siamese network), represented by a N-dimensional vector each, the gradient pushed from the Normalized Correlation layer back to the convolution layers on the top branch is given by: ∂normxcorr(E, F) ∂Ei = 1 (N −1)σE Fi −µF σF −normxcorr(E, F)(Ei −µE) σE , 5 where Ei is the ith element of the vector representing E and other symbols have their usual meaning. Similar notation is used for the subnetwork at the bottom. The full derivation is available in the supplementary section. 4 Experiments Table 1: Performance of different algorithms at ranks 1, 10, and 20 on CUHK03 Labeled (left) and CUHK03 Detected (right) Datasets. Method r = 1 r = 10 r = 20 Fused Model (ours) 72.43 95.51 98.40 Norm X-Corr (ours) 64.73 92.77 96.78 Ensembles [21] 62.1 92.30 97.20 LOMO+MLAPG [5] 57.96 94.74 98.00 Ahmed et al. [2] 54.74 93.88 98.10 LOMO+XQDA [22] 52.20 92.14 96.25 Li et al. [3] 20.65 68.74 83.06 KISSME [18] 14.17 52.57 70.03 LDML [14] 13.51 52.13 70.81 eSDC [25] 8.76 38.28 53.44 Method r = 1 r = 10 r = 20 Fused Model (ours) 72.04 96.00 98.26 Norm X-Corr (ours) 67.13 94.49 97.66 LOMO+MLAPG [5] 51.15 92.05 96.90 Ahmed et al. [2] 44.96 83.47 93.15 LOMO+XQDA [22] 46.25 88.55 94.25 Li et al. [3] 19.89 64.79 81.14 KISSME [18] 11.70 48.08 64.86 LDML [14] 10.92 47.01 65.00 eSDC [25] 7.68 33.38 50.58 4.1 Datasets, Evaluation Protocol, Baseline Methods We conducted experiments on the large CUHK03 dataset [3], the mid-sized CUHK01 Dataset [23], and the small QMUL GRID dataset [27]. The datasets are divided into training and test sets for our experiments. The goal of every algorithm is to rank images in the gallery image bank of the test set by their similarity to a probe image (which is also from the test set). To do so, they can exploit the training set, consisting of matched and unmatched image pairs. An oracle would always rank the ground truth match (from the gallery) in the first position. All our experiments are conducted in the single shot setting, i.e. there is exactly one image of every person in the gallery image bank and the results averaged over 10 test trials are reported using tables and Cumulative Matching Characteristics (CMC) Curves (see supplementary). For all our experiments, we use a momentum of 0.9, starting learning rate of 0.05, learning rate decay of 1 × 10−4, weight decay of 5 × 10−4. The implementation was done in a machine with NVIDIA Titan GPUs and the code was implemented using Torch and is available online 1. We also conducted an ablation study, to further analyze the contribution of the individual components of our model. CUHK03 Dataset: The CUHK03 dataset is a large collection of 13,164 images of 1360 people captured from 6 different surveillance cameras, with each person observed by 2 cameras with disjoint views [3]. The dataset comes with manual and algorithmically labeled pedestrian bounding boxes. In this work, we conduct experiments on both these sets. For our experiments, we follow the protocol used by Ahmed et al. [2] and randomly pick a set of 1260 identities for training and 100 for testing. We use 100 identities from the training set for validation. We compare the performance of both Normalized X-Corr and the Fused model with several baselines for both labeled [2, 3, 5, 14, 18, 21, 22, 25] and detected [2, 3, 5, 14, 18, 22, 25] sets. Of these, the comparison with Ahmed et al. [2] and with Li et al. [3] is of special interest to us since these are deep learning approaches as well. For our models, we use mini-batch sizes of 128 and train our models for about 200,000 iterations. CUHK01 Dataset: The CUHK01 dataset is a mid-sized collection of 3,884 images of 971 people, with each person observed by 2 cameras with disjoint views [23]. There are 4 images of every identity. For our experiments, we follow the protocol used by Ahmed et al. [2] and conduct 2 sets of experiments with varying training set sizes. In the first, we randomly pick a set of 871 identities for training and 100 for testing, while in the second, 486 identities are used for testing and the rest for training. We compare the performance of both of our models with several baselines for both 100 test identities [2, 3, 14, 18, 25] and 486 test identities [2, 8, 9, 20, 21]. For our models, we use mini-batch sizes of 128 and train our models for about 50,000 iterations. QMUL GRID Dataset: The QMUL underGround Re-Identification (GRID) dataset is a small and a very challenging dataset [27]. It is a collection of only 250 people captured from 2 views. Besides, the 2 images of every identity, there are 775 unmatched images, i.e. for these identities only 1 view is available. For our experiments, we follow the protocol used by Liao and Li [5]. We randomly pick a set of 125 identities (who have 2 views each) for training and leave the remaining 125 for testing. Additionally, the gallery image bank of the test is enriched with the 775 unmatched images. This makes the ranking task even more challenging. We compare the performance of both of our models with several baselines [11, 12, 15, 19, 22, 24]. For our models, we use mini-batch sizes of 128 and train our models for about 20,000 iterations. 1https://github.com/InnovArul/personreid_normxcorr 6 Table 2: Performance of different algorithms at ranks 1, 10, and 20 on CUHK01 100 Test Ids (left) and 486 Test Ids (right) Datasets Method r = 1 r = 10 r = 20 Fused Model (ours) 81.23 97.39 98.60 Norm X-Corr (ours) 77.43 96.67 98.40 Ahmed et al. [2] 65.00 93.12 97.20 Li et al. [3] 27.87 73.46 86.31 KISSME [18] 29.40 72.43 86.07 LDML [14] 26.45 72.04 84.69 eSDC [25] 22.84 57.67 69.84 Method r = 1 r = 10 r = 20 Fused Model (ours) 65.04 89.76 94.49 Norm X-Corr (ours) 60.17 86.26 91.47 CPDL [8] 59.5 89.70 93.10 Ensembles [21] 51.9 83.00 89.40 Ahmed et al. [2] 47.50 80.00 87.44 Mirror-KFMA [20] 40.40 75.3 84.10 Mid-Level Filters [9] 34.30 65.00 74.90 4.2 Training Strategies for the Neural Network The large number of parameters of a deep neural network necessitate special training strategies [2]. In this work, we adopt 3 main strategies to train our model. Data Augmentation: For almost all the datasets, the number of negative pairs far outnumbers the number of positive pairs in the training set. This poses a serious challenge to deep neural nets, which can overfit and get biased in the process. Further, the positive samples may not have all the variations likely to be encountered in a real scenario. We therefore, hallucinate positive pairs and enrich the training corpus, along the lines of Ahmed et al. [2]. For every image in the training set of size W×H, we sample 2 images for CUHK03 (5 images for CUHK01 & QMUL) around the original image center and apply 2D translations chosen from a uniform random distribution in the range of [−0.05W, 0.05W] × [−0.05H, 0.05H]. We also augment the data with images reflected on a vertical mirror. Fine-Tuning: For small datasets such as QMUL, training parameter-intensive models such as deep neural networks can be a significant challenge. One way to mitigate this issue is to fine-tune the model while training. We start with a model pre-trained on a large dataset such as CUHK01 with 871 training identities rather than an untrained model and then refine this pre-trained model by training on the small dataset, QMUL in our case. During fine-tuning, we use a learning rate of 0.001. Others: Training deep neural networks is time taking. Therefore, to speed up the training, we implemented our code such that it spawns threads across multiple GPUs. 5 Results and Discussion CUHK03 Dataset: Table 1 summarizes the results of the experiments on the CUHK03 Labeled dataset. Our Fused model outperforms the existing state-of-the-art models by a wide margin, of about 10% (about 72% vs. 62%) on rank-1 accuracy, while the Normalized X-Corr model gives a 3% gain. This serves as a promising response to our key research endeavor for an effective deep learning model for person re-identification. Further, both models are significantly better than Ahmed et al.’s model [2]. We surmise that this is because our models are more adept at handling variations in illumination, partial occlusion and viewpoint change. Interestingly, we also note that the existing best performing system is a non-deep approach. This shows that designing an effective deep learning architecture is a fairly non-trivial task. Our models’ performance, viz.-a-viz. non-deep methods, once again underscores the benefits of learning representations from the data rather than using hand-engineered ones. A visualization of some filter responses of our model, some of the result plots, and some ranked matching results may be found in the supplementary material. Table 1 also presents the results on the CUHK03 Detected dataset. Here too, we see the superior performance of our models over the existing state-of-the-art baselines. Interestingly, here our models take a wider lead over the existing baselines (about 21%) and our models’ performance rivals its own performance on the Labeled dataset. We hypothesize that incorporating a wider search space makes our models more robust to the challenges posed by images in which the person is not centered, such as the CUHK03 Detected dataset. CUHK01 Dataset: Table 2 summarizes the results of the experiments on the CUHK01 dataset with 100 and 486 test identities. For the 486 test identity setting, our models were pre-trained on the training set of the larger CUHK03 Labeled dataset and then fine-tuned on the CUHK01-486 training set, owing to the paucity of training data. As the tables show, our models give us a gain of upto 16% over the existing state-of-the-art on the rank-1 accuracies. QMUL GRID Dataset: QMUL GRID is a challenging dataset for person re-identification due to its small size and the additional 775 unmatched gallery images in the test set. This is evident from the low performances of 7 Table 3: Performance of different algorithms at ranks 1, 5, 10, and 20 on the QMUL GRID Dataset Method r = 1 r = 5 r = 10 r = 20 Deep Learning Model Fused Model (ours) 19.20 38.40 53.6 66.4 Yes Norm X-Corr (ours) 16.00 32.00 40.00 55.2 Yes KEPLER [24] 18.40 39.12 50.24 61.44 No LOMO+XQDA [22] 16.56 33.84 41.84 52.40 No PolyMap [11] 16.30 35.80 46.00 57.60 No MtMCML [19] 14.08 34.64 45.84 59.84 No MRank-RankSVM [15] 12.24 27.84 36.32 46.56 No MRank-PRDC [15] 11.12 26.08 35.76 46.56 No LCRML [12] 10.68 25.76 35.04 46.48 No XQDA [22] 10.48 28.08 38.64 52.56 No existing state-of-the-art algorithms. In order to train our models on this small dataset, we start with a model trained on CUHK01 dataset with 100 test identities, then we fine-tune the models on the QMUL GRID training set. Table 3 summarizes the results of the experiments on the QMUL GRID dataset. Here too, our Fused model performs the best. Even though, our gain in rank-1 accuracy is a modest 1% but we believe this is significant for a challenging dataset like QMUL. The ablation study across multiple datasets reveals that a wider search and inexact match each buy us at least 6% individually, in terms of performance. The supplementary presents these results in more detail and also compares the number of parameters across different models. Multi-GPU training, on the other hand gives us a 3x boost to training speed. 6 Conclusions and Future Work In this work, we address the central research question of proposing simple yet effective deep-learning models for Person Re-Identification by proposing two new models. Our models are capable of handling the key challenges of illumination variations, partial occlusions and viewpoint invariance by incorporating inexact matching over a wider search space. Additionally, the proposed Normalized X-Corr model benefits from having fewer parameters than the state-of-the-art deep learning model. The Fused model, on the other hand, allows us to cut down on false matches resulting from a wide matching search space, yielding superior performance. For future work, we intend to use the proposed Siamese architectures for other matching tasks in Vision such as content-based image retrieval. We also intend to explore the effect of incorporating more feature maps on performance. References [1] Alex Krizhevsky, Ilya Sutskever, and Geoffrey E Hinton. Imagenet classification with deep convolutional neural networks. In Advances in neural information processing systems, pages 1097–1105, 2012. [2] Ejaz Ahmed, Michael Jones, and Tim K Marks. An improved deep learning architecture for person re-identification. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pages 3908–3916, 2015. [3] Wei Li, Rui Zhao, Tong Xiao, and Xiaogang Wang. Deepreid: Deep filter pairing neural network for person re-identification. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pages 152–159, 2014. [4] David G Lowe. Distinctive image features from scale-invariant keypoints. International journal of computer vision, 60(2):91–110, 2004. [5] Shengcai Liao and Stan Z Li. Efficient psd constrained asymmetric metric learning for person reidentification. In Proceedings of the IEEE International Conference on Computer Vision, pages 3685–3693, 2015. [6] Rui Zhao, Wanli Ouyang, and Xiaogang Wang. Person re-identification by salience matching. In Proceedings of the IEEE International Conference on Computer Vision, pages 2528–2535, 2013. [7] Michela Farenzena, Loris Bazzani, Alessandro Perina, Vittorio Murino, and Marco Cristani. Person re-identification by symmetry-driven accumulation of local features. In Computer Vision and Pattern Recognition (CVPR), 2010 IEEE Conference on, pages 2360–2367. IEEE, 2010. 8 [8] Sheng Li, Ming Shao, and Yun Fu. Cross-view projective dictionary learning for person re-identification. In Proceedings of the 24th International Conference on Artificial Intelligence, AAAI Press, pages 2155–2161, 2015. [9] Rui Zhao, Wanli Ouyang, and Xiaogang Wang. Learning mid-level filters for person re-identification. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pages 144–151, 2014. [10] Bryan Prosser, Wei-Shi Zheng, Shaogang Gong, Tao Xiang, and Q Mary. Person re-identification by support vector ranking. In BMVC, volume 2, page 6, 2010. [11] Dapeng Chen, Zejian Yuan, Gang Hua, Nanning Zheng, and Jingdong Wang. Similarity learning on an explicit polynomial kernel feature map for person re-identification. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pages 1565–1573, 2015. [12] Jiaxin Chen, Zhaoxiang Zhang, and Yunhong Wang. Relevance metric learning for person re-identification by exploiting global similarities. In Pattern Recognition (ICPR), 2014 22nd International Conference on, pages 1657–1662. IEEE, 2014. [13] Jason V Davis, Brian Kulis, Prateek Jain, Suvrit Sra, and Inderjit S Dhillon. Information-theoretic metric learning. In Proceedings of the 24th international conference on Machine learning, pages 209–216. ACM, 2007. [14] Matthieu Guillaumin, Jakob Verbeek, and Cordelia Schmid. Is that you? metric learning approaches for face identification. In 2009 IEEE 12th International Conference on Computer Vision, pages 498–505. IEEE, 2009. [15] Chen Change Loy, Chunxiao Liu, and Shaogang Gong. Person re-identification by manifold ranking. In 2013 IEEE International Conference on Image Processing, pages 3567–3571. IEEE, 2013. [16] Wei-Shi Zheng, Shaogang Gong, and Tao Xiang. Reidentification by relative distance comparison. IEEE transactions on pattern analysis and machine intelligence, 35(3):653–668, 2013. [17] Martin Hirzer, Peter M Roth, and Horst Bischof. Person re-identification by efficient impostor-based metric learning. In Advanced Video and Signal-Based Surveillance (AVSS), 2012 IEEE Ninth International Conference on, pages 203–208. IEEE, 2012. [18] Martin Köstinger, Martin Hirzer, Paul Wohlhart, Peter M Roth, and Horst Bischof. Large scale metric learning from equivalence constraints. In Computer Vision and Pattern Recognition (CVPR), 2012 IEEE Conference on, pages 2288–2295. IEEE, 2012. [19] Lianyang Ma, Xiaokang Yang, and Dacheng Tao. Person re-identification over camera networks using multi-task distance metric learning. IEEE Transactions on Image Processing, 23(8):3656–3670, 2014. [20] Ying-Cong Chen, Wei-Shi Zheng, and Jianhuang Lai. Mirror representation for modeling view-specific transform in person re-identification. In Proc. IJCAI, pages 3402–3408. Citeseer, 2015. [21] Sakrapee Paisitkriangkrai, Chunhua Shen, and Anton van den Hengel. Learning to rank in person reidentification with metric ensembles. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pages 1846–1855, 2015. [22] Shengcai Liao, Yang Hu, Xiangyu Zhu, and Stan Z Li. Person re-identification by local maximal occurrence representation and metric learning. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pages 2197–2206, 2015. [23] Wei Li, Rui Zhao, and Xiaogang Wang. Human reidentification with transferred metric learning. In Asian Conference on Computer Vision, pages 31–44. Springer, 2012. [24] Niki Martinel, Christian Micheloni, and Gian Luca Foresti. Kernelized saliency-based person reidentification through multiple metric learning. IEEE Transactions on Image Processing, 24(12):5645– 5658, 2015. [25] Rui Zhao, Wanli Ouyang, and Xiaogang Wang. Unsupervised salience learning for person re-identification. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pages 3586–3593, 2013. [26] Dong Yi, Zhen Lei, Shengcai Liao, Stan Z Li, et al. Deep metric learning for person re-identification. In ICPR, volume 2014, pages 34–39, 2014. [27] Chen Change Loy, Tao Xiang, and Shaogang Gong. Multi-camera activity correlation analysis. In Computer Vision and Pattern Recognition, 2009. CVPR 2009. IEEE Conference on, pages 1988–1995. IEEE, 2009. 9 | 2016 | 514 |
6,455 | Efficient Neural Codes under Metabolic Constraints Zhuo Wang ∗† Department of Mathematics University of Pennsylvania wangzhuo@nyu.edu Xue-Xin Wei ∗‡ Department of Psychology University of Pennsylvania weixxpku@gmail.com Alan A. Stocker Department of Psychology University of Pennsylvania astocker@sas.upenn.edu Daniel D. Lee Department of Electrical and System Engineering University of Pennsylvania ddlee@seas.upenn.edu Abstract Neural codes are inevitably shaped by various kinds of biological constraints, e.g. noise and metabolic cost. Here we formulate a coding framework which explicitly deals with noise and the metabolic costs associated with the neural representation of information, and analytically derive the optimal neural code for monotonic response functions and arbitrary stimulus distributions. For a single neuron, the theory predicts a family of optimal response functions depending on the metabolic budget and noise characteristics. Interestingly, the well-known histogram equalization solution can be viewed as a special case when metabolic resources are unlimited. For a pair of neurons, our theory suggests that under more severe metabolic constraints, ON-OFF coding is an increasingly more efficient coding scheme compared to ON-ON or OFF-OFF. The advantage could be as large as one-fold, substantially larger than the previous estimation. Some of these predictions could be generalized to the case of large neural populations. In particular, these analytical results may provide a theoretical basis for the predominant segregation into ONand OFF-cells in early visual processing areas. Overall, we provide a unified framework for optimal neural codes with monotonic tuning curves in the brain, and makes predictions that can be directly tested with physiology experiments. 1 Introduction The efficient coding hypothesis [1, 2] plays a fundamental role in understanding neural codes, particularly in early sensory processing. Going beyond the original idea of redundancy reduction by Horace Barlow [2], efficient coding has become a general conceptual framework for studying optimal neural coding [3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14]. Efficient coding theory hypothesizes that the neural code is organized in a way such that maximal information is conveyed about the stimulus variable. Notably, any formulation of efficient coding necessarily relies on a set of constraints due to real world limitations imposed on neural systems. For example, neural noise, metabolic energy budgets, tuning curve characteristics and the size of the neural population all can have impacts on the quality of the neural code. Most previous studies have only considered a small subset of these constraints. For example, the original redundancy reduction argument proposed by Barlow has focused on utilizing the dynamical ∗equal contribution †current affiliation: Center for Neural Science, New York University ‡current affiliation: Department of Statistics and Center for Theoretical Neuroscience, Columbia University 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. range of the neurons efficiently [2, 15], but did not take neural noise model and energy consumption into consideration. Some studies explicitly dealt with the metabolic costs of the system but did not consider the constraints imposed by the limited firing rates of neurons as well as their detailed tuning properties [16, 7, 17, 18]. As another prominent example, histogram equalization has been proposed as the mechanism for determining the optimal tuning curve of a single neuron with monotonic response characteristics [19]. However, this result only holds for a specific neural noise model and does not take metabolic costs into consideration either. In terms of neural population, most previous studies have focused on bell-shaped tuning curves. Optimal neural coding for neural population with monotonic tuning curves have received much less attention [20, 21]. We develop a formulation of efficient coding that explicitly deals with multiple biologically relevant constraints, including neural noise, limited range of the neural output, and metabolic consumption. With this formulation, we can study neural codes based on monotonic response characteristics that have been frequently observed in biological neural systems. We are able to derive analytical solutions for a wide range of conditions in the small noise limit. We present results for neural populations of different sizes, including the cases of a single neuron, pairs of neurons, as well as a brief treatment for larger neural populations. The results are in general agreements with observed coding schemes for monotonic tuning curves. The results also provide various quantitative predictions which are readily testable with targeted physiology experiments. 2 Optimal Code for a Single Neuron 2.1 Models and Methods We start with the simple case where a scalar stimulus s with prior p(s) is encoded by a single neuron. To model the neural response for a stimulus s, we first denote the mean output level as a deterministic function h(s). Here h(s) could denote the mean firing rate in the context of rate coding or just the mean membrane potential. In either case, the actual response r is noisy and can be modeled by a probabilistic model P(r|h(s)). Throughout the paper, we limit the neural codes to be monotonic functions h(s). The mutual information between the input stimulus r and the neural response is denoted as MI(s, r). We formulate the efficient coding problem as the maximization of the mutual information between the stimulus and the response, e.g., MI(s, r) [3]. To complete the formulation of this problem, it is crucial to choose a set of constraints which characterizes the limited resource available to the neural system. One important constraint is the finite range of the neural output [19]. Another constraint is on the mean metabolic cost [16, 7, 17, 18], which limits the mean activity level of neural output, averaged over the stimulus prior. Under these constraints, the efficient coding problem can mathematically be formulated as following: maximize MI(s, r) subject to 0 ≤h(s) ≤rmax, h′(s) ≥0 (range constraint) Es[K(h(s))] ≤Ktotal (metabolic constraint) We seek the optimal response function h(s) under various choices of the neural noise model P(r|h(s)) and certain metabolic cost function K(h(s)), as discussed below. Neural Noise Models: Neural noise can often be well characterized by a Poisson distribution at relatively short time scale [22]. Under the Poisson noise model, the number of spikes NT over a duration of T is a Poisson random variable with mean h(s)T and variance h(s)T. In the long T limit, the mean response r = NT /T approximately follows a Gaussian distribution r ∼N(h(s), h(s)/T) (1) Non-Poisson noise have also been observed physiologically. In these cases, the variance of response NT can be greater or smaller than the mean firing rate [22, 23, 24, 25]. We thus consider a more generic family of noise models parametrized by α r ∼N(h(s), h(s)α/T) (2) This generalized family of noise model naturally includes the additive Gaussian noise case (when α = 0), which is useful for describing the stochasticity of the membrane potential of a neuron. 2 Metabolic Cost: We model the metabolic cost K is a power-law function of the neural output K(h(s)) = h(s)β (3) where β > 0 is a parameter to model how does the energy cost scale up as the neural output is increasing. For a single neuron we will demonstrate with the general energy cost function but when we generalize to the case of multiple neurons, we will assume β = 1 for simplicity. Note that it does not require extra effort to solve the problem if the cost function takes the general form of ˜K(h(s)) = K0 +K1h(s)β, as reported in [26]. This is because of the linear nature of the expectation term in the metabolic constraint. 2.2 Derivation of the Optimal h(s) This efficient coding problem can be greatly simplified due to the fact that it is invariant under any re-parameterization of the stimulus variable s. We take this advantage by mapping s to another uniform random variable u ∈[0, 1] via the cumulative distribution function u = F(s) [27]. If we choose g(u) = g(F(s)) = h(s), it suffices to solve the following new problem which optimizes g(u) for a re-parameterized input u with uniform prior maximize MI(u, r) subject to 0 ≤g(u) ≤rmax, g′(u) ≥0 Eu[K(g(u))] ≤Ktotal Once the optimal form of g∗(u) is obtained, the optimal h∗(s) is naturally given by g∗(F(s)). To solve this simplified problem, first we express the objective function in terms of g(u). In the small noise limit (large integration time T), the Fisher information IF (u) of the neuron with noise model in Eq. (2) is calculated and the mutual information can be approximated as (see [28, 14]) IF (u) = T g′(u)2 g(u)α + O(1) (4) MI(u, r) = H(U) + 1 2 Z p(u) log IF (u) du = 1 2 Z 1 0 log g′(u)2 g(u)α du + 1 2 log T + O(1/T) (5) where H(U) = 0 is the entropy and p(u) = 1{0≤u≤1} is the density of the uniform distribution. Furthermore, each constraints can be rewritten as integrals of g′(u) and g(u) respectively: g(1) −g(0) = Z 1 0 g′(u) du ≤rmax (6) Eu[K(g(u))] = Z 1 0 g(u)β du ≤Ktotal (7) This form of the problem (Eq. 5-7) can be analytically solved by using the Lagrangian multiplier method and the optimal response function must take the form g(u) = rmax · 1 aγ−1 q (uγq(a)) 1/β , h(s) = g(F(s)) (8) where q def = (1 −α/2)/β, γq(x) def = Z x 0 zq−1 exp(−z) dz. (9) The function γq(x) is called the incomplete gamma function and γ−1 q is its inverse. Due to space limitation we only present a sketch derivation. Readers who are interested in the detailed proof are referred to the supplementary materials. Let us now turn to some intuitive conclusions behind this solution (also see Fig.1, in which we have assumed rmax = 1 for simplicity). From Eq. (8), it is clear that the optimal solution g(u) depend on the constant a which should be determined by equalizing the metabolic constraint (see the horizontal dash lines in Fig.1a). Furthermore, the optimal solution h(s) depends on the specific input distribution p(s). Depending on the relative magnitude of rmax and Ktotal: 3 • Range constraint dominates: This is the case when there is more than sufficient energy to achieve the optimal solution so that the metabolic constraint becomes completely redundant. Determined by α, β and rmax, Kthre is the energy consumption of the optimal code with unconstrained metabolic budget. When the available metabolic cost exceeds this threshold Ktotal ≥Kthre, the constant a is very close to zero and the optimal g(u) is proportional to a power function g(u) = rmax · u1/q. See red curves in Fig.1. • Both constraints: This is the general case when Ktotal ≲Kthre. The constant a is set to the minimum value for which the metabolic constraint is satisfied. See purple curves in Fig.1. • Metabolic constraint dominates: This happens when Ktotal ≪Kthre. In this case a is often very large. See blue curves in Fig.1. x γ−1 q (x) low cost high cost max cost 0 0.5 1 0 0.5 1 u g(u) p(u) −2 0 2 0 0.5 1 s h(s) p(s) 0 2 4 0 0.5 1 s h(s) p(s) x γ−1 q (x) 0 0.5 1 0 0.5 1 u g(u) p(u) −2 0 2 0 0.5 1 s h(s) p(s) 0 2 4 0 0.5 1 s h(s) p(s) e f g h a b c d Gaussian noise Poisson noise uniform prior Gaussian prior heavy-tail prior Figure 1: Deriving optimal tuning curves g(u) and corresponding h(s) for different prior distributions and different noise models. Top row: constant Gaussian noise (α, β, q) = (0, 1, 1); Bottom row: Poisson noise (α, β, q) = (1, 1, 1/2). (a) A segment of the inverse incomplete gamma function is cropped out by dashed boxes. The higher the horizontal dash lines (constant a), the lower the average metabolic cost, which corresponds to a more substantial metabolic constraint. We thus use “low",“high" and “max" to label the energy costs under different metabolic constraints. (b) The optimal solution g(u) for a uniform variable u. (c) The corresponding optimal h(s) for Gaussian prior. (d) The corresponding optimal h(s) for Gamma distribution p(s) ∝sq−1 exp(−s). Specifically for this prior, the optimal tuning curve is exactly linear without maximum response constraint. (e-h) Similar to (a-d), but for Poisson noise. 2.3 Properties of the Optimal h(s) We have predicted the optimal response function for arbitrary values of α (which corresponds to the noise model) and β (which quantifies the metabolic cost model). Here we specifically focus on a few situations with most biological relevance. We begin with the simple additive Gaussian noise model, i.e. α = 0. This model could provide a good characterization of the response mapping from the input stimulus to the membrane potential of a neuron [19]. With more than sufficient metabolic supply, the optimal solution falls back to the histogram equalization principle where each response magnitude is utilized to the same extent (red curve in Fig. 1b and Fig.2a). With less metabolic budget, the optimal tuning curve bends downwards to satisfy this constraint and large responses will be penalized, resulting in more density at smaller response magnitude (purple curve in Fig.2a). In the other extreme, when the available metabolic budget Ktotal is diminishing, the response magnitude converges to the max-entropy distribution under the metabolic constraint E[g(u)β] = const (blue curve in Fig.2a). Next we discuss the case of Poisson spiking neurons. In the extreme case when the range constraint dominates, the model predicts a square tuning curve for uniform input (red curve in Fig.1f), which is consistent with previous studies [29, 30]. We also found that Poisson noise model leads to heavier 4 penalization on large response magnitude compared to Gaussian noise, suggesting an interaction between noise and metabolic cost in shaping the optimal neural response distribution. In the other extreme when Ktotal goes to 0, the response distribution converges to a gamma distribution, with heavy tail (see Fig.2). Our analytical result gives a simple yet quantitative explanation of the emergence of sparse coding [7] from an energy-efficiency perspective. 0 0.5 1 response magnitude probability low cost high cost max cost 0 0.5 1 response magnitude probability a b Gaussian noise Poisson noise Figure 2: Probability of generating certain response g(u) based on the optimal tuning of a single neuron under (a) Gaussian noise model and (b) Poisson noise model. In the extreme case of Gaussian noise with effectively no metabolic constraint, the distribution is uniformly distributed on the whole range. 3 Optimal Code for a Pair of Neurons We next study the optimal coding in the case of two neurons with monotonic response functions. We denote the neural responses as r = (r1, r2). Therefore the efficient coding problem becomes: maximize MI(s, r) subject to 0 ≤hi(s) ≤rmax, i = 1, 2. (range constraint) Es [K(h1(s)) + K(h2(s))] ≤2Ktotal (metabolic constraint) Assuming the neural noise is independent across neurons, the system of two neurons has total Fisher information just as the linear sum of Fisher information contributed from each neuron IF (s) = I1(s) + I2(s). 3.1 Optimal response functions Previous studies on neural coding with monotonic response functions have typically assumed that each hi(s) has sigmoidal shape. It is important to emphasize that we do not make any a priori assumptions on the detailed shape of the tuning curve other than being monotonic and smooth. We define each neuron’s active region Ai = A+ i ∪A− i , where A+ i = {s|h′ i(s) > 0}, A− i = {s| −h′ i(s) > 0}. Due to the monotonicity of tuning curve, either A+ i or A− i has to be empty. We find the following results (proof in the supplementary materials) 1. Different neurons should have non-overlapping active regions. 2. If the metabolic constraint is binding, ON-OFF coding is better than ON-ON coding or OFFOFF coding. Otherwise all three coding schemes can achieve the same mutual information. 3. For ON-OFF coding, it is better to have ON regions on the right side. 4. For ON-ON coding (or OFF-OFF), each neuron should have roughly the same tuning curve hi(s) ≈hj(s) while still have disjoint active regions. Note that a conceptually similar coding scheme has been previously discussed by [29]. Within the ON-pool or OFF-pool, the optimal tuning curve is same as the optimal solution from the single neuron case. In Fig.3a-d, we illustrate how these conclusions can be used to determine the optimal pair of neurons, assuming additive Gaussian noise α = 0 and linear metabolic cost β = 1 (for other α and β the process is similar). Our analytical results allow us to predict the precise shape of the optimal response functions, which goes beyond previous work on ON-OFF coding schemes [13, 31]. 5 3.2 Comparison between ON-OFF and ON-ON codes We aim to compare the coding performance of ON-OFF and ON-ON codes. In Fig.3e we show how the mutual information depends on the available metabolic budget. For both ON-FF and ON-ON scheme, the mutual information is monotonically increasing as a function of energy available. We compare these two curves in two different ways. First, we notice that both mutual information curve saturate the limit at KON-ON = 0.5rmax and KON-OFF = 0.25rmax respectively (see the red tuning curves in Fig.3a-d). Note that this specific saturation limit is only valid for α = 0 and β = 1. For any other mutual information, we find out that the optimal ON-ON pair (or OFF-OFF pair) always cost twice energy compared to the optimal ON-OFF pair. Second, one can compare the ON-ON and ON-OFF scheme by fixing the energy available. The optimal mutual information achieved by ON-ON neurons is always smaller than that achieved by ON-OFF neurons and the difference is plotted in Fig.3. When the available energy is extremely limited Ktotal ≪rmax, such difference saturates at −1 in the logarithm space of MI (base 2). This shows that, in the worst scenario, the ON-ON code is only half as efficient as the ON-OFF code from mutual information perspective. In other words, it would take twice the amount of time T for the ON-ON code to convey same amount of mutual information as the ON-OFF code under same noise level. These analyses quantitatively characterize the advantage of ON-OFF over ON-ON and show how it varies when the relative importance of the metabolic constraint changes. The encoding efficiency of ON-OFF ranges from double (with very limited metabolic budget) to equal amount of the ON-ON efficiency (with unlimited metabolic budget). This wide range includes the previous conclusion reported by Gjorgjieva et.al., where a mild advantage (∼15%) of ON-OFF scheme is found under short integration time limit [31]. It is well known that the split of ON and OFF pathways exists in 0 0.5 1 0 0.5 1 u g(u) low cost, ON low cost, OFF max cost, ON max cost, OFF p(u) −4 −2 0 2 4 0 0.5 1 s h(s) p(s) 0 0.5 1 0 0.5 1 u g(u) low cost, ON−1 low cost, ON−2 max cost, ON−1 max cost, ON−2 p(u) −4 −2 0 2 4 0 0.5 1 s h(s) p(s) 0 0.25 0.5 −3 −2 −1 0 Ktotal/rmax log2(MI) ON−ON ON−OFF difference c d a b e ON-OFF ON-ON uniform prior heavy-tail prior Figure 3: The optimal response functions for a pair of neurons assuming Gaussian noise. (a) The optimal response functions for a uniform input distribution assuming ON-OFF coding scheme. Solid red curve and dash red curve represent the optimal response functions for a pair of neurons with no metabolic constraint (“max cost"). Solid blue and dash blue curves are the optimal response functions with substantial metabolic constraint (“low cost"). (b) Similar to panel a, but for input stimuli with heavy tail distribution. (c) The optimal response functions for a uniform input distribution assuming ON-ON coding scheme. Solid and dash red curves are for no metabolic constraint. Notice that two curves appear to be identical but are actually different at finer scales (see the inserted panel). Solid and dash blue are for substantial metabolic constraint. (d) Similar to panel c, but for input stimuli with heavy tail distribution. (e) A comparison between the ON-ON and ON-OFF schemes. The x-axis represents how substantial the metabolic constraint is – any value greater than the threshold 0.5 implies no metabolic constraint in effect. The y-axis represents the mutual information, relative to the maximal achievable mutual information without metabolic constraints (which is the same for ON-ON and ON-OFF schemes). The green dash line represents the difference between the information transmitted by the two schemes. Negative difference indicates an advantage of ON-OFF over ON-ON. 6 the retina of many species [32, 33]. The substantial increase of efficiency under strong metabolic constraint we discovered supports the argument that metabolic constraint may be one of the main reasons for such pathway splitting in evolution. In a recent study by Karklin and Simoncelli [13], it is observed numerically that ON-OFF coding scheme can naturally emerge when a linear-nonlinear population of neurons are trained to maximize mutual information with image input and under metabolic constraint. It is tempting to speculate a generic connection of these numerical observations to our theoretical results, although our model is much more simplified in the sense that we do not directly model the higher dimensional stimulus (natural image) but just a one dimensional projection (local contrast). Intriguingly, we find that if the inputs follow certain heavy tail distribution ( Fig.3b), the optimal response functions are two rectified non-linear functions which split the encoding range. Such rectified non-linearity is consistent with both the non-linearity observed physiologically[34] and the numerical results in [13] . 4 Discussion In this paper we presented a theoretical framework for studying optimal neural codes under biologically relevant constraints. Compared to previous works, we emphasize the importance of two types of constraint – the noise characteristics of the neural responses and the metabolic cost. Throughout the paper, we have focused on neural codes with smooth monotonic response functions. We demonstrated that, maybe surprisingly, analytical solutions exist for a wide family of noise characteristics and metabolic cost functions. These analytical results rely on the techniques of approximating mutual information using Fisher information. There are cases when such approximation would bread down, in particular for short integration time or non-Gaussian noise. For a more detailed discussion on the validity of Fisher approximation, see [29, 14, 35]. We have focused on the cases of a single neuron and a pair of neurons. However, the framework can be generalized to the case of larger population of neurons. For the case of N = 2k (k is large) neurons, we again find the corresponding optimization problem could be solved analytically by exploiting the Fisher information approximation of mutual information [28, 14]. Interestingly, we found the optimal codes should be divided into two pools of neurons of equal size k. One pool of neuron with monotonic increasing response function (ON-pool), and the other with monotonic decreasing response function (OFF-pool). For neurons within the same pool, the optimal response functions appear to be identical on the macro-scale but are quite different when zoomed in. In fast, the optimal code must have disjoint active regions for each neuron. This is similar to what has been illustrated in the inset panel of Fig.3c, where two seemingly identical tuning curves for ON-neurons are compared. We can also quantify the increase of the mutual information by using optimal coding schemes versus using all ON neurons (or all OFF). Interestingly, some of the key results presented in the Fig 3e for the a pair of neurons generalize to 2K case. When N = 2k + 1, the optimal solution is similar to N = 2k for a large pool of neurons. However, when k is small, the difference caused by asymmetry between ON/OFF pools can substantially change the configuration of the optimal code. Due to the limited scope of the paper, we have ignored several important aspects when formulating the efficient coding problem. First, we have not modeled the spontaneous activity (baseline firing rate) of neurons. Second, we have not considered the noise correlations between the responses of neurons. Third, we have ignored the noise in the input to the neurons. We think that the first two factors are unlikely to change our main results. However, incorporating the input noise may significantly change the results. In particular, for the cases of multiple neurons, our current results predict that there is no overlap between the active regions of the response functions for ON and OFF neurons. However, it is possible that this prediction does not hold in the presence of the input noise. In that case, it might be beneficial to have some redundancy by making the response functions partially overlap. Including these factors into the framework should facilitate a detailed and quantitative comparison to physiologically measured data in the future. As for the objective function, we have only considered the case of maximizing mutual information; it is interesting to see whether the results can be generalized to other objective functions such as, e.g., minimizing decoding error[36, 37]. Also, our theory is based on a one dimensional input. To fully explain the ON-OFF split in visual pathway, it seems necessary to consider a more complete model with the images as the input. To this end, our current model lacks the spatial component, and it doesn’t explain the difference between the number of ON and OFF neurons in retina [38]. Nonetheless, the insight from these analytical results based on the simple model may prove to be useful for a more complete understanding of the functional 7 organization of the early visual pathway. Last but not least, we have assumed a stationary input distribution. However, in the natural environment the input distribution often fluctuate at different time scales, it remains to be investigated how to incorporate these dynamical aspects into a theory of efficient coding. References [1] Fred Attneave. Some informational aspects of visual perception. Psychological review, 61(3):183, 1954. [2] Horace B Barlow. Possible principles underlying the transformation of sensory messages. Sensory communication, pages 217–234, 1961. [3] Ralph Linsker. Self-organization in a perceptual network. Computer, 21(3):105–117, 1988. [4] Joseph J Atick and A Norman Redlich. Towards a theory of early visual processing. Neural Computation, 2(3):308–320, 1990. [5] Joseph J Atick. Could information theory provide an ecological theory of sensory processing? Network: Computation in neural systems, 3(2):213–251, 1992. [6] F Rieke, DA Bodnar, and W Bialek. Naturalistic stimuli increase the rate and efficiency of information transmission by primary auditory afferents. Proceedings of the Royal Society of London. Series B: Biological Sciences, 262(1365):259–265, 1995. [7] Bruno Olshausen and David Field. Emergence of simple-cell receptive field properties by learning a sparse code for natural images. Nature, 381:607–609, 1996. [8] Anthony J Bell and Terrence J Sejnowski. The “independent components" of natural scenes are edge filters. Vision research, 37(23):3327–3338, 1997. [9] Eero P Simoncelli and Bruno A Olshausen. Natural image statistics and neural representation. Annual review of neuroscience, 24(1):1193–1216, 2001. [10] Allan Gottschalk. Derivation of the visual contrast response function by maximizing information rate. Neural computation, 14(3):527–542, 2002. [11] Nicol S Harper and David McAlpine. Optimal neural population coding of an auditory spatial cue. Nature, 430(7000):682–686, 2004. [12] Mark D McDonnell and Nigel G Stocks. Maximally informative stimuli and tuning curves for sigmoidal rate-coding neurons and populations. Physical review letters, 101(5):058103, 2008. [13] Yan Karklin and Eero P Simoncelli. Efficient coding of natural images with a population of noisy linear-nonlinear neurons. Advances in neural information processing systems, 24:999, 2011. [14] Xue-Xin Wei and Alan A Stocker. Mutual information, fisher information, and efficient coding. Neural computation, 2016. [15] Horace Barlow. Redundancy reduction revisited. Network: computation in neural systems, 12(3):241–253, 2001. [16] William B Levy and Robert A Baxter. Energy efficient neural codes. Neural computation, 8(3):531–543, 1996. [17] Simon B Laughlin, Rob R de Ruyter van Steveninck, and John C Anderson. The metabolic cost of neural information. Nature neuroscience, 1(1):36–41, 1998. [18] Vijay Balasubramanian, Don Kimber, and Michael J Berry II. Metabolically efficient information processing. Neural Computation, 13(4):799–815, 2001. [19] Simon B Laughlin. A simple coding procedure enhances a neuron’s information capacity. Z. Naturforsch, 36(910-912):51, 1981. 8 [20] Deep Ganguli and Eero P Simoncelli. Efficient sensory encoding and Bayesian inference with heterogeneous neural populations. Neural Computation, 26(10):2103–2134, 2014. [21] David B Kastner, Stephen A Baccus, and Tatyana O Sharpee. Critical and maximally informative encoding between neural populations in the retina. Proceedings of the National Academy of Sciences, 112(8):2533–2538, 2015. [22] George J Tomko and Donald R Crapper. Neuronal variability: non-stationary responses to identical visual stimuli. Brain research, 79(3):405–418, 1974. [23] DJ Tolhurst, JA Movshon, and ID Thompson. The dependence of response amplitude and variance of cat visual cortical neurones on stimulus contrast. Experimental brain research, 41(3-4):414–419, 1981. [24] Mark M Churchland et al. Stimulus onset quenches neural variability: a widespread cortical phenomenon. Nature neuroscience, 13(3):369–378, 2010. [25] Moshe Gur and D Max Snodderly. High response reliability of neurons in primary visual cortex (v1) of alert, trained monkeys. Cerebral cortex, 16(6):888–895, 2006. [26] David Attwell and Simon B Laughlin. An energy budget for signaling in the grey matter of the brain. Journal of Cerebral Blood Flow & Metabolism, 21(10):1133–1145, 2001. [27] Xue-Xin Wei and Alan A Stocker. A bayesian observer model constrained by efficient coding can explain’anti-bayesian’percepts. Nature Neuroscience, 2015. [28] Nicolas Brunel and Jean-Pierre Nadal. Mutual information, Fisher information, and population coding. Neural Computation, 10(7):1731–1757, 1998. [29] Matthias Bethge, David Rotermund, and Klaus Pawelzik. Optimal short-term population coding: when fisher information fails. Neural Computation, 14(10):2317–2351, 2002. [30] Don H Johnson and Will Ray. Optimal stimulus coding by neural populations using rate codes. Journal of computational neuroscience, 16(2):129–138, 2004. [31] Julijana Gjorgjieva, Haim Sompolinsky, and Markus Meister. Benefits of pathway splitting in sensory coding. The Journal of Neuroscience, 34(36):12127–12144, 2014. [32] Peter H Schiller. The on and off channels of the visual system. Trends in neurosciences, 15(3):86–92, 1992. [33] Heinz Wässle. Parallel processing in the mammalian retina. Nature Reviews Neuroscience, 5(10):747–757, 2004. [34] Matteo Carandini. Amplification of trial-to-trial response variability by neurons in visual cortex. PLoS Biol, 2(9):e264, 2004. [35] Zhuo Wang, Alan A Stocker, and Daniel D Lee. Efficient neural codes that minimize lp reconstruction error. Neural Computation, 2016. [36] Tvd Twer and Donald IA MacLeod. Optimal nonlinear codes for the perception of natural colours. Network: Computation in Neural Systems, 12(3):395–407, 2001. [37] Zhuo Wang, Alan A Stocker, and Daniel D Lee. Optimal neural tuning curves for arbitrary stimulus distributions: Discrimax, infomax and minimum Lp loss. In Advances in Neural Information Processing Systems NIPS, pages 2177–2185, 2012. [38] Charles P Ratliff, Bart G Borghuis, Yen-Hong Kao, Peter Sterling, and Vijay Balasubramanian. Retina is structured to process an excess of darkness in natural scenes. Proceedings of the National Academy of Sciences, 107(40):17368–17373, 2010. 9 | 2016 | 515 |
6,456 | Learning Kernels with Random Features Aman Sinha1 John Duchi1,2 Departments of 1Electrical Engineering and 2Statistics Stanford University {amans,jduchi}@stanford.edu Abstract Randomized features provide a computationally efficient way to approximate kernel machines in machine learning tasks. However, such methods require a user-defined kernel as input. We extend the randomized-feature approach to the task of learning a kernel (via its associated random features). Specifically, we present an efficient optimization problem that learns a kernel in a supervised manner. We prove the consistency of the estimated kernel as well as generalization bounds for the class of estimators induced by the optimized kernel, and we experimentally evaluate our technique on several datasets. Our approach is efficient and highly scalable, and we attain competitive results with a fraction of the training cost of other techniques. 1 Introduction An essential element of supervised learning systems is the representation of input data. Kernel methods [27] provide one approach to this problem: they implicitly transform the data to a new feature space, allowing non-linear data representations. This representation comes with a cost, as kernelized learning algorithms require time that grows at least quadratically in the data set size, and predictions with a kernelized procedure require the entire training set. This motivated Rahimi and Recht [24, 25] to develop randomized methods that efficiently approximate kernel evaluations with explicit feature transformations; this approach gives substantial computational benefits for large training sets and allows the use of simple linear models in the randomly constructed feature space. Whether we use standard kernel methods or randomized approaches, using the “right” kernel for a problem can make the difference between learning a useful or useless model. Standard kernel methods as well as the aforementioned randomized-feature techniques assume the input of a user-defined kernel—a weakness if we do not a priori know a good data representation. To address this weakness, one often wishes to learn a good kernel, which requires substantial computation. We combine kernel learning with randomization, exploiting the computational advantages offered by randomized features to learn the kernel in a supervised manner. Specifically, we use a simple pre-processing stage for selecting our random features rather than jointly optimizing over the kernel and model parameters. Our workflow is straightforward: we create randomized features, solve a simple optimization problem to select a subset, then train a model with the optimized features. The procedure results in lowerdimensional models than the original random-feature approach for the same performance. We give empirical evidence supporting these claims and provide theoretical guarantees that our procedure is consistent with respect to the limits of infinite training data and infinite-dimensional random features. 1.1 Related work To discuss related work, we first describe the supervised learning problem underlying our approach. We have a cost c : R × Y →R, where c(·, y) is convex for y ∈Y, and a reproducing kernel Hilbert space (RKHS) of functions F with kernel K. Given a sample {(xi, yi)}n i=1, the usual ℓ2-regularized 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. learning problem is to solve the following (shown in primal and dual forms respectively): minimize f∈F n X i=1 c(f(xi), yi) + λ 2 ∥f∥2 2 , or maximize α∈Rn − n X i=1 c∗(αi, yi) −1 2λαT Gα, (1) where ∥·∥2 denotes the Hilbert space norm, c∗(α, y) = supz{αz −c(z, y)} is the convex conjugate of c (for fixed y) and G = [K(xi, xj)]n i,j=1 denotes the Gram matrix. Several researchers have studied kernel learning. As noted by Gönen and Alpaydın [14], most formulations fall into one of a few categories. In the supervised setting, one assumes a base class or classes of kernels and either uses heuristic rules to combine kernels [2, 23], optimizes structured (e.g. linear, nonnegative, convex) compositions of the kernels with respect to an alignment metric [9, 16, 20, 28], or jointly optimizes kernel compositions with empirical risk [17, 20, 29]. The latter approaches require an eigendecomposition of the Gram matrix or costly optimization problems (e.g. quadratic or semidefinite programs) [10, 14], but these models have a variety of generalization guarantees [1, 8, 10, 18, 19]. Bayesian variants of compositional kernel search also exist [12, 13]. In un- and semi-supervised settings, the goal is to learn an embedding of the input distribution followed by a simple classifier in the embedded space (e.g. [15]); the hope is that the input distribution carries the structure relevant to the task. Despite the current popularity of these techniques, especially deep neural architectures, they are costly, and it is difficult to provide guarantees on their performance. Our approach optimizes kernel compositions with respect to an alignment metric, but rather than work with Gram matrices in the original data representation, we work with randomized feature maps that approximate RKHS embeddings. We learn a kernel that is structurally different from a user-supplied base kernel, and our method is an efficiently (near linear-time) solvable convex program. 2 Proposed approach At a high level, we take a feature mapping, find a distribution that aligns this mapping with the labels y, and draw random features from the learned distribution; we then use these features in a standard supervised learning approach. For simplicity, we focus on binary classification: we have n datapoints (xi, yi) ∈Rd × {−1, 1}. Letting φ : Rd × W →[−1, 1] and Q be a probability measure on a space W, define the kernel KQ(x, x′) := Z φ(x, w)φ(x′, w)dQ(w). (2) We want to find the “best” kernel KQ over all distributions Q in some (large, nonparametric) set P of possible distributions on random features; we consider a kernel alignment problem of the form maximize Q∈P X i,j KQ(xi, xj)yiyj. (3) We focus on sets P defined by divergence measures on the space of probability distributions. For a convex function f with f(1) = 0, the f-divergence between distributions P and Q is Df (P||Q) = R f( dP dQ)dQ. Then, for a base (user-defined) distribution P0, we consider collections P := {Q : Df (Q||P0) ≤ρ} where ρ > 0 is a specified constant. In this paper, we focus on divergences f(t) = tk −1 for k ≥2. Intuitively, the distribution Q maximizing the alignment (3) gives a feature space in which pairwise distances are similar to those in the output space Y. Unfortunately, the problem (3) is generally intractable as it is infinite dimensional. Using the randomized feature approach, we approximate the integral (2) as a discrete sum over samples W i iid ∼P0, i ∈[Nw]. Defining the discrete approximation PNw := {q : Df (q||1/Nw) ≤ρ} to P, we have the following empirical version of problem (3): maximize q∈PNw X i,j yiyj Nw X m=1 qmφ(xi, wm)φ(xj, wm). (4) Using randomized features, matching the input and output distances in problem (4) translates to finding a (weighted) set of points among w1, w2, ..., wNw that best “describe” the underlying dataset, or, more directly, finding weights q so that the kernel matrix matches the correlation matrix yyT . 2 Given a solution bq to problem (4), we can solve the primal form of problem (1) in two ways. First, we can apply the Rahimi and Recht [24] approach by drawing D samples W 1, . . . , W D iid ∼bq, defining features φi = [φ(xi, w1) · · · φ(xi, wD)]T , and solving the risk minimization problem bθ = argmin θ n X i=1 c 1 √ DθT φi, yi + r(θ) (5) for some regularization r. Alternatively, we may set φi = [φ(xi, w1) · · · φ(xi, wNw)]T , where w1, . . . , wNw are the original random samples from P0 used to solve (4), and directly solve bθ = argmin θ n X i=1 c(θT diag(bq) 1 2 φi, yi) + r(θ) . (6) Notably, if bq is sparse, the problem (6) need only store the random features corresponding to non-zero entries of bq. Contrast our two-phase procedure to that of Rahimi and Recht [25], which samples W 1, . . . , W D iid ∼P0 and solves the minimization problem minimize α∈RNw n X i=1 c D X m=1 αmφ(xi, wm), yi subject to ∥α∥∞≤C/Nw, (7) where C is a numerical constant. At first glance, it appears that we may suffer both in terms of computational efficiency and in classification or learning performance compared to the one-step procedure (7). However, as we show in the sequel, the alignment problem (4) can be solved very efficiently and often yields sparse vectors bq, thus substantially decreasing the dimensionality of problem (6). Additionally, we give experimental evidence in Section 4 that the two-phase procedure yields generalization performance similar to standard kernel and randomized feature methods. 2.1 Efficiently solving problem (4) The optimization problem (4) has structure that enables efficient (near linear-time) solutions. Define the matrix Φ = [φ1 · · · φn] ∈RNw×n, where φi = [φ(xi, w1) · · · φ(xi, wNw)]T ∈RNw is the randomized feature representation for xi and wm iid ∼P0. We can rewrite the optimization objective as X i,j yiyj Nw X m=1 qmφ(xi, wm)φ(xj, wm) = Nw X m=1 qm n X i=1 yiφ(xi, wm) 2 = qT ((Φy) ⊙(Φy)) , where ⊙denotes the Hadamard product. Constructing the linear objective requires the evaluation of Φy. Assuming that the computation of φ is O(d), construction of Φ is O(nNwd) on a single processor. However, this construction is trivially parallelizable. Furthermore, computation can be sped up even further for certain distributions P0. For example, the Fastfood technique can approximate Φ in O(nNw log(d)) time for the Gaussian kernel [21]. The problem (4) is also efficiently solvable via bisection over a scalar dual variable. Using λ ≥0 for the constraint Df (Q||P0) ≤ρ, a partial Lagrangian is L(q, λ) = qT ((Φy) ⊙(Φy)) −λ (Df (q||1/Nw) −ρ) . The corresponding dual function is g(λ) = supq∈∆L(q, λ), where ∆:= {q ∈RNw + : qT 1 = 1} is the probability simplex. Minimizing g(λ) yields the solution to problem (4); this is a convex optimization problem in one dimension so we can use bisection. The computationally expensive step in each iteration is maximizing L(q, λ) with respect to q for a given λ. For f(t) = tk −1, we define v := (Φy) ⊙(Φy) and solve maximize q∈∆ qT v −λ 1 Nw Nw X m=1 (Nwqm)k. (8) This has a solution of the form qm = vm/λN k−1 w + τ 1 k−1 + , where τ is chosen so that P m qm = 1. We can find such a τ by a variant of median-based search in O(Nw) time [11]. Thus, for any k ≥2, an ϵ-suboptimal solution to problem (4) can be found in O(Nw log(1/ϵ)) time (see Algorithm 1). 3 Algorithm 1 Kernel optimization with f(t) = tk −1 as divergence INPUT: distribution P0 on W, sample {(xi, yi)}n i=1, Nw ∈N, feature function φ, ϵ > 0 OUTPUT: q ∈RNw that is an ϵ-suboptimal solution to (4). SETUP: Draw Nw samples wm iid ∼P0, build feature matrix Φ, compute v := (Φy) ⊙(Φy). Set λu ←∞, λl ←0, λs ←1 while λu = ∞ q ←argmaxq∈∆L(q, λs) // (solution to problem (8)) if Df (q||1/Nw) < ρ then λu ←λs else λs ←2λs while λu −λl > ϵλs λ ←(λu + λl)/2 q ←argmaxq∈∆L(q, λ) // (solution to problem (8)) if Df (q||1/Nw) < ρ then λu ←λ else λl ←λ 3 Consistency and generalization performance guarantees Although the procedure (4) is a discrete approximation to a heuristic kernel alignment problem, we can provide guarantees on its performance as well as the generalization performance of our subsequent model trained with the optimized kernel. Consistency First, we provide guarantees that the solution to problem (4) approaches a population optimum as the data and random sampling increase (n →∞and Nw →∞, respectively). We consider the following (slightly more general) setting: let S : X × X →[−1, 1] be a bounded function, where we intuitively think of S(x, x′) as a similarity metric between labels for x and x′, and denote Sij := S(xi, xj) (in the binary case with y ∈{−1, 1}, we have Sij = yiyj). We then define the alignment functions T(P) := E[S(X, X′)KP (X, X′)], bT(P) := 1 n(n −1) X i̸=j SijKP (xi, xj), where the expectation is taken over S and the independent variables X, X′. Lemmas 1 and 2 provide consistency guarantees with respect to the data sample (xi and Sij) and the random feature sample (wm); together they give us the overall consistency result of Theorem 1. We provide proofs in the supplement (Sections A.1, A.2, and A.3 respectively). Lemma 1 (Consistency with respect to data). Let f(t) = tk −1 for k ≥2. Let P0 be any distribution on the space W, and let P = {Q : Df (Q||P0) ≤ρ}. Then P sup Q∈P bT(Q) −T(Q) ≥t ≤ √ 2 exp − nt2 16(1 + ρ) . Lemma 1 shows that the empirical quantity bT is close to the true T. Now we show that, independent of the size of the training data, we can consistently estimate the optimal Q ∈P via sampling (i.e. Q ∈PNw). Lemma 2 (Consistency with respect to sampling features). Let the conditions of Lemma 1 hold. Then, with Cρ = 2(ρ+1) √1+ρ−1 and Dρ = p 8(1 + ρ), we have sup Q∈PNw bT(Q) −sup Q∈P bT(Q) ≤4Cρ s log(2Nw) Nw + Dρ s log 2 δ Nw with probability at least 1 −δ over the draw of the samples W m iid ∼P0. Finally, we combine the consistency guarantees for data and sampling to reach our main result, which shows that the alignment provided by the estimated distribution bQ is nearly optimal. Theorem 1. Let bQw maximize bT(Q) over Q ∈PNw. Then, with probability at least 1 −3δ over the sampling of both (x, y) and W, we have T( bQw) −sup Q∈P T(Q) ≤4Cρ s log(2Nw) Nw + Dρ s log 2 δ Nw + 2Dρ s 2 log 2 δ n . 4 Generalization performance The consistency results above show that our optimization procedure nearly maximizes alignment T(P), but they say little about generalization performance for our model trained using the optimized kernel. We now show that the class of estimators employed by our method has strong performance guarantees. By construction, our estimator (6) uses the function class FNw := n h(x) = Nw X m=1 αm √qmφ(x, wm) | q ∈PNw, ∥α∥2 ≤B o , and we provide bounds on its generalization via empirical Rademacher complexity. To that end, define Rn(FNw) := 1 nE[supf∈FNw Pn i=1 σif(xi)], where the expectation is taken over the i.i.d. Rademacher variables σi ∈{−1, 1}. We have the following lemma, whose proof is in Section A.4. Lemma 3. Under the conditions of the preceding paragraph, Rn(FNw) ≤B q 2(1+ρ) n . Applying standard concentration results, we obtain the following generalization guarantee. Theorem 2 ([8, 18]). Let the true misclassification risk and ν-empirical misclassification risk for an estimator h be defined as follows: R(h) := P(Y h(X) < 0), bRν(h) := 1 n n X i=1 min n 1, 1 −yh(xi)/ν + o . Then suph∈FNw {R(h) −bRν(h)} ≤2 ν Rn(FNw) + 3 q log 2 δ 2n with probability at least 1 −δ. The bound is independent of the number of terms Nw, though in practice we let B grow with Nw. 4 Empirical evaluations We now turn to empirical evaluations, comparing our approach’s predictive performance with that of Rahimi and Recht’s randomized features [24] as well as a joint optimization over kernel compositions and empirical risk. In each of our experiments, we investigate the effect of increasing dimensionality of the randomized feature space D. For our approach, we use the χ2-divergence (k = 2 or f(t) = t2 −1). Letting bq denote the solution to problem (4), we use two variants of our approach: when D < nnz(bq) we use estimator (5), and we use estimator (6) otherwise. For the original randomized feature approach, we relax the constraint in problem (7) with an ℓ2 penalty. Finally, for the joint optimization in which we learn the kernel and classifier together, we consider the kernel-learning objective, i.e. finding the best Gram matrix G in problem (1) for the soft-margin SVM [14]: minimizeq∈PNw supα αT 1 −1 2 P i,j αiαjyiyj PNw m=1 qmφ(xi, wm)φ(xj, wm) subject to 0 ⪯α ⪯C1, αT y = 0. (9) We use a standard primal-dual algorithm [4] to solve the min-max problem (9). While this is an expensive optimization, it is a convex problem and is solvable in polynomial time. In Section 4.1, we visualize a particular problem that illustrates the effectiveness of our approach when the user-defined kernel is poor. Section 4.2 shows how learning the kernel can be used to quickly find a sparse set of features in high dimensional data, and Section 4.3 compares our performance with unoptimized random features and the joint procedure (9) on benchmark datasets. The supplement contains more experimental results in Section C. 4.1 Learning a new kernel with a poor choice of P0 For our first experiment, we generate synthetic data xi iid ∼N(0, I) with labels yi = sign(∥x∥2 − √ d), where x ∈Rd. The Gaussian kernel is ill-suited for this task, as the Euclidean distance used in this kernel does not capture the underlying structure of the classes. Nevertheless, we use the Gaussian kernel, which corresponds [24] to φ(x, (w, v)) = cos((x, 1)T (w, v)) where (W, V ) ∼ N(0, I) × Uni(0, 2π), to showcase the effects of our method. We consider a training set of size n = 104 and a test set of size 103, and we employ logistic regression with D = nnz(bq) for both our technique as well as the original random feature approach.1 1For 2 ≤d ≤15, nnz(bq) < 250 when the kernel is trained with Nw = 2 · 104, and ρ = 200. 5 -4 -2 0 2 4 -3 -2 -1 0 1 2 3 (a) Training data & optimized features for d = 2 2 4 6 8 10 12 14 0 0.05 0.1 0.15 0.2 0.25 0.3 0.35 0.4 0.45 GK-train GK-test OK-train OK-test (b) Error vs. d Figure 1. Experiments with synthetic data. (a) Positive and negative training examples are blue and red, and optimized randomized features (wm) are yellow. All offset parameters vm were optimized to be near 0 or π (not shown). (b) Misclassification error of logistic regression model vs. dimensionality of data. GK denotes random features with a Gaussian kernel, and our optimized kernel is denoted OK. 101 102 103 104 0.1 0.2 0.3 0.4 0.5 (a) Error vs. D 101 102 103 104 105 0 0.01 0.02 0.03 0.04 0.05 (b) bqi vs. i Figure 2. Feature selection in sparse data. (a) Misclassification error of ridge regression model vs. dimensionality of data. LK denotes random features with a linear kernel, and OK denotes our method. Our error is fixed above D = nnz(bq) after which we employ estimator (6). (b) Weight of feature i in optimized kernel (qi) vs. i. Vertical bars delineate separations between k-grams, where 1 ≤k ≤5 is nondecreasing in i. Circled features are prefixes of GGTTG and GTTGG at indices 60–64. Figure 1 shows the results of the experiments for d ∈{2, . . . , 15}. Figure 1(a) illustrates the output of the optimization when d = 2. The selected kernel features wm lie near (1, 1) and (−1, −1); the offsets vm are near 0 and π, giving the feature φ(·, w, v) a parity flip. Thus, the kernel computes similarity between datapoints via neighborhoods of (1, 1) and (−1, −1) close to the classification boundary. In higher dimensions, this generalizes to neighborhoods of pairs of opposing points along the surface of the d-sphere; these features provide a coarse approximation to vector magnitude. Performance degradation with d occurs because the neighborhoods grow exponentially larger and less dense (due to fixed Nw and n). Nevertheless, as shown in Figure 1(b), this degradation occurs much more slowly than that of the Gaussian kernel, which suffers a similar curse of dimensionality due to its dependence on Euclidean distance. Although somewhat contrived, this example shows that even in situations with poor base kernels our approach learns a more suitable representation. 4.2 Feature selection and biological sequences In addition to the computational advantages rendered by the sparsity of q after performing the optimization (4), we can use this sparsity to gain insights about important features in high-dimensional datasets; this can act as an efficient filtering mechanism before further investigation. We present one example of this task, studying an aptamer selection problem [6]. In this task, we are given n = 2900 nucleotide sequences (aptamers) xi ∈A81, where A = {A,C,G,T} and labels yi indicate (thresholded) binding affinity of the aptamer to a molecular target. We create one-hot encoded forms of k-grams of the sequence, where 1 ≤k ≤5, resulting in d = P5 k=1 |A|k(82 −k) = 105,476 6 102 103 0.14 0.16 0.18 0.2 0.22 0.24 (a) Error vs. D, adult 101 102 103 104 0.1 0.15 0.2 0.25 0.3 0.35 0.4 0.45 0.5 (b) Error vs. D, reuters 101 102 103 0.04 0.06 0.08 0.1 0.12 0.14 0.16 0.18 0.2 (c) Error vs. D, buzz 102 103 10-1 100 101 (d) Speedup vs. D, adult 101 102 103 104 10-1 100 101 102 103 (e) Speedup vs. D, reuters 101 102 103 100 101 (f) Speedup vs. D, buzz Figure 3. Performance analysis on benchmark datasets. The top row shows training and test misclassification rates. Our method is denoted as OK and is shown in red. The blue methods are random features with Gaussian, linear, or arc-cosine kernels (GK, LK, or ACK respectively). Our error and running time become fixed above D = nnz(bq) after which we employ estimator (6). The bottom row shows the speedup factor of using our method over regular random features (speedup = x indicates our method takes 1/x of the time required to use regular random features). Our method is faster at moderate to large D and shows better performance than the random feature approach at small to moderate D. Table 1: Best test results over benchmark datasets Dataset n, ntest d Model Our error (%), time(s) Random error (%), time(s) adult 32561, 16281 123 Logistic 15.54, 3.6 15.44, 43.1 reuters 23149, 781265 47236 Ridge 9.27, 0.8 9.36, 295.9 buzz 105530, 35177 77 Ridge 4.92, 2.0 4.58, 11.9 features. We consider the linear kernel, i.e. φ(x, w) = xw, where w ∼Uni({1, . . . , d}). Figure 2(a) compares the misclassification error of our method with that of random k-gram features, while Figure 2(b) indicates the weights qi given to features by our method. In under 0.2 seconds, we whittle down the original feature space to 379 important features. By restricting random selection to just these features, we outperform the approach of selecting features uniformly at random when D ≪d. More importantly, however, we can derive insights from this selection. For example, the circled features in Figure 2(b) correspond to k-gram prefixes for the 5-grams GGTTG and GTTGG at indices 60 through 64; G-complexes are known to be relevant for binding affinities in aptamers [6], so this is reasonable. 4.3 Performance on benchmark datasets We now show the benefits of our approach on large-scale datasets, since we exploit the efficiency of random features with the performance of kernel-learning techniques. We perform experiments on three distinct types of datasets, tracking training/test error rates as well as total (training + test) time. For the adult2 dataset we employ the Gaussian kernel with a logistic regression model, and for the reuters3 dataset we employ a linear kernel with a ridge regression model. For the buzz4 dataset we employ ridge regression with an arc-cosine kernel of order 2, i.e. P0 = N(0, I) and φ(x, w) = H(wT x)(wT x)2, where H(·) is the Heavyside step function [7]. 2https://archive.ics.uci.edu/ml/datasets/Adult 3http://www.ai.mit.edu/projects/jmlr/papers/volume5/lewis04a/lyrl2004_rcv1v2_README.htm. We consider predicting whether a document has a CCAT label. 4http://ama.liglab.fr/data/buzz/classification/. We use the Twitter dataset. 7 Table 2: Comparisons with joint optimization on subsampled data Dataset Our training / test error (%), time(s) Joint training / test error (%), time(s) adult 16.22 / 16.36, 1.8 14.88 / 16.31, 198.1 reuters 7.64 / 9.66, 0.6 6.30 / 8.96, 173.3 buzz 8.44 / 8.32, 0.4 7.38 / 7.08, 137.5 Comparison with unoptimized random features Results comparing our method with unoptimized random features are shown in Figure 3 for many values of D, and Table 1 tabulates the best test error and corresponding time for the methods. Our method outperforms the original random feature approach in terms of generalization error for small and moderate values of D; at very large D the random feature approach either matches our surpasses our performance. The trends in speedup are opposite: our method requires extra optimizations that dominate training time at extremely small D; at very large D we use estimator (6), so our method requires less overall time. The nonmonotonic behavior for reuters (Figure 3(e)) occurs due to the following: at D ≲nnz(bq), sampling indices from the optimized distribution takes a non-neglible fraction of total time, and solving the linear system requires more time when rows of Φ are not unique (due to sampling). Performance improvements also depend on the kernel choice for a dataset. Namely, our method provides the most improvement, in terms of training time for a given amount of generalization error, over random features generated for the linear kernel on the reuters dataset; we are able to surpass the best results of the random feature approach 2 orders of magnitude faster. This makes sense when considering the ability of our method to sample from a small subset of important features. On the other hand, random features for the arc-cosine kernel are able to achieve excellent results on the buzz dataset even without optimization, so our approach only offers modest improvement at small to moderate D. For the Gaussian kernel employed on the adult dataset, our method is able to achieve the same generalization performance as random features in roughly 1/12 the training time. Thus, we see that our optimization approach generally achieves competitive results with random features at lower computational costs, and it offers the most improvements when either the base kernel is not well-suited to the data or requires a large number of random features (large D) for good performance. In other words, our method reduces the sensitivity of model performance to the user’s selection of base kernels. Comparison with joint optimization Despite the fact that we do not choose empirical risk as our objective in optimizing kernel compositions, our optimized kernel enjoys competitive generalization performance compared to the joint optimization procedure (9). Because the joint optimization is very costly, we consider subsampled training datasets of 5000 training examples. Results are shown in Table 2, where it is evident that the efficiency of our method outweighs the marginal gain in classification performance for joint optimization. 5 Conclusion We have developed a method to learn a kernel in a supervised manner using random features. Although we consider a kernel alignment problem similar to other approaches in the literature, we exploit computational advantages offered by random features to develop a much more efficient and scalable optimization procedure. Our concentration bounds guarantee the results of our optimization procedure closely match the limits of infinite data (n →∞) and sampling (Nw →∞), and our method produces models that enjoy good generalization performance guarantees. Empirical evaluations indicate that our optimized kernels indeed “learn” structure from data, and we attain competitive results on benchmark datasets at a fraction of the training time for other methods. Generalizing the theoretical results for concentration and risk to other f−divergences is the subject of further research. More broadly, our approach opens exciting questions regarding the usefulness of simple optimizations on random features in speeding up other traditionally expensive learning problems. Acknowledgements This research was supported by a Fannie & John Hertz Foundation Fellowship and a Stanford Graduate Fellowship. 8 References [1] P. L. Bartlett and S. Mendelson. Rademacher and gaussian complexities: Risk bounds and structural results. The Journal of Machine Learning Research, 3:463–482, 2003. [2] A. Ben-Hur and W. S. Noble. Kernel methods for predicting protein–protein interactions. Bioinformatics, 21(suppl 1):i38–i46, 2005. [3] A. Ben-Tal, D. den Hertog, A. D. Waegenaere, B. Melenberg, and G. Rennen. Robust solutions of optimization problems affected by uncertain probabilities. Management Science, 59(2):341–357, 2013. [4] D. Bertsekas. Nonlinear Programming. Athena Scientific, 1999. [5] S. Boucheron, G. Lugosi, and P. Massart. Concentration Inequalities: a Nonasymptotic Theory of Independence. Oxford University Press, 2013. [6] M. Cho, S. S. Oh, J. Nie, R. Stewart, M. Eisenstein, J. Chambers, J. D. Marth, F. Walker, J. A. Thomson, and H. T. Soh. Quantitative selection and parallel characterization of aptamers. Proceedings of the National Academy of Sciences, 110(46), 2013. [7] Y. Cho and L. K. Saul. Kernel methods for deep learning. In Advances in neural information processing systems, pages 342–350, 2009. [8] C. Cortes, M. Mohri, and A. Rostamizadeh. Generalization bounds for learning kernels. In Proceedings of the 27th International Conference on Machine Learning (ICML-10), pages 247–254, 2010. [9] C. Cortes, M. Mohri, and A. Rostamizadeh. Algorithms for learning kernels based on centered alignment. The Journal of Machine Learning Research, 13(1):795–828, 2012. [10] N. Cristianini, J. Kandola, A. Elisseeff, and J. Shawe-Taylor. On kernel target alignment. In Innovations in Machine Learning, pages 205–256. Springer, 2006. [11] J. C. Duchi, S. Shalev-Shwartz, Y. Singer, and T. Chandra. Efficient projections onto the ℓ1-ball for learning in high dimensions. In Proceedings of the 25th International Conference on Machine Learning, 2008. [12] D. Duvenaud, J. R. Lloyd, R. Grosse, J. B. Tenenbaum, and Z. Ghahramani. Structure discovery in nonparametric regression through compositional kernel search. arXiv preprint arXiv:1302.4922, 2013. [13] M. Girolami and S. Rogers. Hierarchic bayesian models for kernel learning. In Proceedings of the 22nd international conference on Machine learning, pages 241–248. ACM, 2005. [14] M. Gönen and E. Alpaydın. Multiple kernel learning algorithms. The Journal of Machine Learning Research, 12:2211–2268, 2011. [15] G. E. Hinton and R. R. Salakhutdinov. Using deep belief nets to learn covariance kernels for gaussian processes. In Advances in neural information processing systems, pages 1249–1256, 2008. [16] J. Kandola, J. Shawe-Taylor, and N. Cristianini. Optimizing kernel alignment over combinations of kernel. 2002. [17] M. Kloft, U. Brefeld, S. Sonnenburg, and A. Zien. Lp-norm multiple kernel learning. The Journal of Machine Learning Research, 12:953–997, 2011. [18] V. Koltchinskii and D. Panchenko. Empirical margin distributions and bounding the generalization error of combined classifiers. Annals of Statistics, pages 1–50, 2002. [19] V. Koltchinskii, D. Panchenko, et al. Complexities of convex combinations and bounding the generalization error in classification. The Annals of Statistics, 33(4):1455–1496, 2005. [20] G. R. Lanckriet, N. Cristianini, P. Bartlett, L. E. Ghaoui, and M. I. Jordan. Learning the kernel matrix with semidefinite programming. The Journal of Machine Learning Research, 5:27–72, 2004. [21] Q. Le, T. Sarlós, and A. Smola. Fastfood-computing hilbert space expansions in loglinear time. In Proceedings of the 30th International Conference on Machine Learning, pages 244–252, 2013. [22] D. Luenberger. Optimization by Vector Space Methods. Wiley, 1969. [23] S. Qiu and T. Lane. A framework for multiple kernel support vector regression and its applications to sirna efficacy prediction. Computational Biology and Bioinformatics, IEEE/ACM Transactions on, 6(2): 190–199, 2009. [24] A. Rahimi and B. Recht. Random features for large-scale kernel machines. In Advances in Neural Information Processing Systems 20, 2007. [25] A. Rahimi and B. Recht. Weighted sums of random kitchen sinks: replacing minimization with randomization in learning. In Advances in Neural Information Processing Systems 21, 2008. [26] P. Samson. Concentration of measure inequalities for Markov chains and φ-mixing processes. Annals of Probability, 28(1):416–461, 2000. [27] J. Shawe-Taylor and N. Cristianini. Kernel Methods for Pattern Analysis. Cambridge University Press, 2004. [28] Y. Ying, K. Huang, and C. Campbell. Enhanced protein fold recognition through a novel data integration approach. BMC bioinformatics, 10(1):1, 2009. [29] A. Zien and C. S. Ong. Multiclass multiple kernel learning. In Proceedings of the 24th international conference on Machine learning, pages 1191–1198. ACM, 2007. 9 | 2016 | 516 |
6,457 | Combinatorial semi-bandit with known covariance Rémy Degenne LMPA, Université Paris Diderot CMLA, ENS Paris-Saclay degenne@cmla.ens-cachan.fr Vianney Perchet CMLA, ENS Paris-Saclay CRITEO Research, Paris perchet@normalesup.org Abstract The combinatorial stochastic semi-bandit problem is an extension of the classical multi-armed bandit problem in which an algorithm pulls more than one arm at each stage and the rewards of all pulled arms are revealed. One difference with the single arm variant is that the dependency structure of the arms is crucial. Previous works on this setting either used a worst-case approach or imposed independence of the arms. We introduce a way to quantify the dependency structure of the problem and design an algorithm that adapts to it. The algorithm is based on linear regression and the analysis develops techniques from the linear bandit literature. By comparing its performance to a new lower bound, we prove that it is optimal, up to a poly-logarithmic factor in the number of pulled arms. 1 Introduction and setting The multi-armed bandit problem (MAB) is a sequential learning task in which an algorithm takes at each stage a decision (or, “pulls an arm”). It then gets a reward from this choice, with the goal of maximizing the cumulative reward [Robbins, 1985]. We consider here its stochastic combinatorial extension, in which the algorithm chooses at each stage a subset of arms [Audibert et al., 2013, Cesa-Bianchi and Lugosi, 2012, Chen et al., 2013, Gai et al., 2012]. These arms could form, for example, the path from an origin to a destination in a network. In the combinatorial setting, contrary to the the classical MAB, the inter-dependencies between the arms can play a role (we consider that the distribution of rewards is invariant with time). We investigate here how the covariance structure of the arms affects the difficulty of the learning task and whether it is possible to design a unique algorithm capable of performing optimally in all cases from the simple scenario with independent rewards to the more challenging scenario of general correlated rewards. Formally, at each stage t ∈N, t ≥1, an algorithm pulls m ≥1 arms among d ≥m. Such a set of m arms is called an “action” and will be denoted by At ∈{0, 1}d, a vector with exactly m non-zero entries. The possible actions are restricted to an arbitrary fixed subset A ⊂{0, 1}d. After choosing action At, the algorithm receives the reward A⊤ t Xt, where Xt ∈Rd is the vector encapsulating the reward of the d arms at stage t. The successive reward vectors (Xt)t≥1 are i.i.d with unknown mean µ ∈Rd. We consider a semi-bandit feedback system: after choosing the action At, the algorithm observes the reward of each of the arms in that action, but not the other rewards. Other possible feedbacks previously studied include bandit (only A⊤ t Xt is revealed) and full information (Xt is revealed). The goal of the algorithm is to maximize the cumulated reward up to stage T ≥1 or equivalently to minimize the expected regret, which is the difference of the reward that would have been gained by choosing the best action in hindsight A∗and what was actually gained: ERT = E T X t=1 (A∗⊤µ −A⊤ t µ) . 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. For an action A ∈A, the difference ∆A = (A∗⊤µ −A⊤µ) is called gap of A. We denote by ∆t the gap of At, so that regret rewrites as ERT = E PT t=1 ∆t. We also define the minimal gap of an arm, ∆i,min = min{A∈A:i∈A} ∆A. This setting was already studied Cesa-Bianchi and Lugosi [2012], most recently in Combes et al. [2015], Kveton et al. [2015], where two different algorithms are used to tackle on one hand the case where the arms have independent rewards and on the other hand the general bounded case. The regret guaranties of the two algorithms are different and reflect that the independent case is easier. Another algorithm for the independent arms case based on Thompson Sampling was introduced in Komiyama et al. [2015]. One of the main objectives of this paper is to design a unique algorithm that can adapt to the covariance structure of the problem when prior information is available. The following notations will be used throughout the paper: given a matrix M (resp. vector v), its (i, j)th (resp. ith) coefficient is denoted by M (ij) (resp. v(i)). For a matrix M, the diagonal matrix with same diagonal as M is denoted by ΣM. We denote by ηt the noise in the reward, i.e. ηt := Xt −µ. We consider a subgaussian setting, in which we suppose that there is a positive semi-definite matrix C such that for all t ≥1, ∀u ∈Rd, E[eu⊤ηt] ≤e 1 2 u⊤Cu . This is equivalent to the usual setting for bandits where we suppose that the individual arms are subgaussian. Indeed if we have such a matrix C then each η(i) t is √ C(ii)-subgaussian. And under a subgaussian arms assumption, such a matrix always exists. This setting encompasses the case of bounded rewards. We call C a subgaussian covariance matrix of the noise (see appendix A of the supplementary material). A good knowledge of C can simplify the problem greatly, as we will show. In the case of 1-subgaussian independent rewards, in which C can be chosen diagonal, a known lower bound on the regret appearing in Combes et al. [2015] is d ∆log T, while Kveton et al. [2015] proves a dm ∆log T lower bound in general. Our goal here is to investigate the spectrum of intermediate cases between these two settings, from the uninformed general case to the independent case in which one has much information on the relations between the arm rewards. We characterize the difficulty of the problem as a function of the subgaussian covariance matrix C. We suppose that we know a positive semi-definite matrix Γ such that for all vectors v with positive coordinates, v⊤Cv ≤v⊤Γv, property that we denote by C ⪯+ Γ. Γ reflects the prior information available about the possible degree of independence of the arms. We will study algorithms that enjoy regret bounds as functions of Γ. The matrix Γ can be chosen such that all its coefficients are non-negative and verify for all i, j, Γ(ij) ≤ √ Γ(ii)Γ(jj). From now on, we suppose that it is the case. In the following, we will use ϵt such that ηt = C 1/2ϵt and write for the reward: Xt = µ + C 1/2ϵt. 2 Lower bound We first prove a lower bound on the regret of any algorithm, demonstrating the link between the subgaussian covariance matrix and the difficulty of the problem. It depends on the maximal off-diagonal correlation coefficient of the covariance matrix. This coefficient is γ = max{(i,j)∈[d],i̸=j} C(ij) √ C(ii)C(jj) . The bound is valid for consistent algorithms [Lai and Robbins, 1985], for which the regret on any problem verifies ERt = o(ta) as t →+∞for all a > 0. Theorem 1. Suppose to simplify that d is a multiple of m. Then, for any ∆> 0, for any consistent algorithm, there is a problem with gaps ∆, σ-subgaussian arms and correlation coefficients smaller than γ ∈[0, 1] on which the regret is such that lim inf t→+∞ ERt log t ≥(1 + γ(m −1))2σ2(d −m) ∆ This bound is a consequence of the classical result of Lai and Robbins [1985] for multi-armed bandits, applied to the problem of choosing one among d/m paths, each of which has m different successive edges (Figure 1). The rewards in the same path are correlated but the paths are independent. A complete proof can be found in appendix B.1 of the supplementary material. 2 Figure 1: Left: parallel paths problem. Right: regret of OLS-UCB as a function of m and γ in the parallel paths problem with 5 paths (average over 1000 runs). 3 OLS-UCB Algorithm and analysis Faced with the combinatorial semi-bandit at stage t ≥1, the observations from t −1 stages form as many linear equations and the goal of an algorithm is to choose the best action. To find the action with the highest mean, we estimate the mean of all arms. This can be viewed as a regression problem. The design of our algorithm stems from this observation and is inspired by linear regression in the fixed design setting, similarly to what was done in the stochastic linear bandit literature [Rusmevichientong and Tsitsiklis, 2010, Filippi et al., 2010]. There are many estimators for linear regression and we focus on the one that is simple enough and adaptive: Ordinary Least Squares (OLS). 3.1 Fixed design linear regression and OLS-UCB algorithm For an action A ∈A, let IA be the diagonal matrix with a 1 at line i if A(i) = 1 and 0 otherwise. For a matrix M, we also denote by MA the matrix IAMIA. At stage t, if all actions A1, . . . , At were independent of the rewards, we would have observed a set of linear equations IA1X1 = IA1µ + IA1η1 ... IAt−1Xt−1 = IAt−1µ + IAt−1ηt−1 and we could use the OLS estimator to estimate µ, which is unbiased and has a known subgaussian constant controlling its variance. This is however not true in our online setting since the successive actions are not independent. At stage t, we define n(i) t = t−1 X s=1 I{i ∈As}, n(ij) t = t−1 X s=1 I{i ∈As}I{j ∈As} and Dt = t−1 X s=1 IAs , where n(i) t is the number of times arm i has been pulled before stage t and Dt is a diagonal matrix of these numbers. The OLS estimator is, for an arm i ∈[d], ˆµ(i) t = 1 n(i) t X s<t:i∈As X(i) s = µ(i) + (D−1 t t−1 X s=1 IAsC 1/2ϵs)(i) . Then for all A ∈A, A⊤(ˆµt −µ) in the fixed design setting has a subgaussian matrix equal to D−1 t (Pt−1 s=1 CAs)D−1 t . We get confidence intervals for the estimates and can use an upper confidence bound strategy [Lai and Robbins, 1985, Auer et al., 2002]. In the online learning setting the actions are not independent but we will show that using this estimator still leads to estimates that are well concentrated around µ, with confidence intervals given by the same subgaussian matrix. The algorithm OLS-UCB (Algorithm 1) results from an application of an upper confidence bound strategy with this estimator. We now turn to an analysis of the regret of OLS-UCB. At any stage t ≥1 of the algorithm, let γt = max{(i,j)∈At,i̸=j} Γ(ij) √ Γ(ii)Γ(jj) be the maximal off-diagonal correlation coefficient of ΓAt and let γ = max{t∈[T ]} γt be the maximum up to stage T. 3 Algorithm 1 OLS-UCB. Require: Positive semi-definite matrix Γ, real parameter λ > 0. 1: Choose actions such that each arm is pulled at least one time. 2: loop: at stage t, 3: At = arg maxA A⊤ˆµt + Et(A) with Et(A) = p 2f(t) q A⊤D−1 t (λΣΓDt + Pt−1 s=1 ΓAs)D−1 t A. 4: Choose action At, observe IAtXt. 5: Update ˆµt, Dt. 6: end loop Theorem 2. The OLS-UCB algorithm with parameter λ > 0 and f(t) = log t + (m + 2) log log t + m 2 log(1 + e λ) enjoys for all times T ≥1 the regret bound E[RT ] ≤16f(T) X i∈[d] Γ(ii) ∆i,min 5(λ + 1 −γ) log m 1.6 2 + 45γm ! + 8dm2 maxi{C(ii)}∆max ∆2 min + 4∆max , where ⌈x⌉stands for the smallest positive integer bigger than or equal to x. In particular, ⌈0⌉= 1. This bound shows the transition between a general case with a dm log T ∆ regime and an independent case with a d log2 m log T ∆ upper bound (we recall that the lower bound is of the order of d log T ∆ ). The weight of each case is given by the maximum correlation parameter γ. The parameter λ seems to be an artefact of the analysis and can in practice be taken very small or even equal to 0. Figure 1 illustrates the regret of OLS-UCB on the parallel paths problem used to derive the lower bound. It shows a linear dependency in γ and supports the hypothesis that the true upper bound matches the lower bound with a dependency in m and γ of the form (1 + γ(m −1)). Corollary 1. The OLS-UCB algorithm with matrix Γ and parameter λ > 0 has a regret bounded as E[RT ] ≤O( v u u tdT log T max i∈[d]{Γ(ii)} 5(λ + 1 −γ) log m 1.6 2 + 45γm ! ) . Proof. We write that the regret up to stage T is bounded by ∆T for actions with gap smaller than some ∆and bounded using theorem 2 for other actions (with ∆min ≥∆). Maximizing over ∆then gives the result. 3.2 Comparison with other algorithms Previous works supposed that the rewards of the individual arms are in [0, 1], which gives them a 1/2-subgaussian property. Hence we suppose (∀i ∈[d], C(ii) = 1/2) for our comparison. In the independent case, our algorithm is the same as ESCB-2 from Combes et al. [2015], up to the parameter λ. That paper shows that ESCB-2 enjoys an O( d√m log T ∆ ) upper bound but our analysis tighten it to O( d log2 m log T ∆ ). In the general (worst) case, Kveton et al. [2015] prove an O( dm log T ∆ ) upper bound (which is tight) using CombUCB1, a UCB based algorithm introduced in Chen et al. [2013] which at stage t uses the exploration term √1.5 log t P i∈A 1/ q n(i) t . Our exploration term always verifies Et(A) ≤ p f(t) P i∈A 1/ q n(i) t with f(t) ≈log t (see section 3.6). Their exploration term is a worst-case confidence interval for the means. Their broader confidence intervals however have the desirable property that one can find the action that realizes the maximum index by solving a linear optimization problem, making their algorithm computationally efficient, quality that both ESCB and OLS-UCB are lacking. 4 None of the two former algorithms benefits from guaranties in the other regime. The regret of ESCB in the general possibly correlated case is unknown and the regret bound for CombUCB1 is not improved in the independent case. In contrast, OLS-UCB is adaptive in the sense that its performance gets better when more information is available on the independence of the arms. 3.3 Regret Decomposition Let Hi,t = {|ˆµ(i) t −µ(i)| ≥∆t 2m} and Ht = ∪d i=1Hi,t. Ht is the event that at least one coordinate of ˆµt is far from the true mean. Let Gt = {A∗⊤µ ≥A∗⊤ˆµt + Et(A∗)} be the event that the estimate of the optimal action is below its true mean by a big margin. We decompose the regret according to these events: RT ≤ T X t=1 ∆tI{Gt, Ht} + T X t=1 ∆tI{Gt} + T X t=1 ∆tI{Ht} Events Gt and Ht are rare and lead to a finite regret (see below). We first simplify the regret due to Gt ∩Ht and show that it is bounded by the "variance" term of the algorithm. Lemma 1. With the algorithm choosing at stage t the action At = arg maxA(A⊤ˆµt + Et(A)), we have ∆tI{Gt, Ht} ≤2Et(At)I{∆t ≤Et(At)}. Proof in appendix B.2 of the supplementary material. Then the regret is cut into three terms, RT ≤2 T X t=1 Et(At)I{∆t ≤2Et(At)} + T X t=1 ∆tI{Gt} + T X t=1 ∆tI{Ht} . The three terms will be bounded as follows: • The Ht term leads to a finite regret from a simple application of Hoeffding’s inequality. • The Gt term leads to a finite regret for a good choice of f(t). This is where we need to show that the exploration term of the algorithm gives a high probability upper confidence bound of the reward. • The Et(At) term, or variance term, is the main source of the regret and is bounded using ideas similar to the ones used in existing works on semi-bandits. 3.4 Expected regret from Ht Lemma 2. The expected regret due to the event Ht is E[PT t=1 ∆tI{Ht}] ≤8dm2 maxi{C(ii)}∆max ∆2 min . The proof uses Hoeffding’s inequality on the arm mean estimates and can be found in appendix B.2 of the supplementary material. 3.5 Expected regret from Gt We want to bound the probability that the estimated reward for the optimal action is far from its mean. We show that it is sufficient to control a self-normalized sum and do it using arguments from Peña et al. [2008], or Abbasi-Yadkori et al. [2011] who applied them to linear bandits. The analysis also involves a peeling argument, as was done in one dimension by Garivier [2013] to bound a similar quantity. Lemma 3. Let δt > 0. With ˜f(δt) = log(1/δt) + m log log t + m 2 log(1 + e λ) and an algorithm given by the exploration term Et(A) = q 2 ˜f(δt) q A⊤D−1 t (λΣΓDt + Pt−1 s=1 ΓAs)D−1 t A , then the event Gt = {A∗⊤µ ≥A∗⊤ˆµt + Et(A∗)} verifies P{Gt} ≤δt . With δ1 = 1 and δt = 1 t log2 t for t ≥2, such that ˜f(δt) = f(t), the regret due to Gt is finite in expectation, bounded by 4∆max. 5 Proof. We use a peeling argument: let η > 0 and for a = (a1, . . . , am) ∈Nm, let Da ⊂[T] be a subset of indices defined by (t ∈Da ⇔∀i ∈A∗, (1 + η)ai ≤n(i) t < (1 + η)ai+1). For any Bt ∈R, P A∗⊤(µ −ˆµt) ≥Bt ≤ X a P A∗⊤(µ −ˆµt) ≥Bt|t ∈Da . The number of possible sets Da for t is bounded by (log t/ log(1 + η))m, since each number of pulls n(i) t for i ∈A∗is bounded by t. We now search a bound of the form P A∗⊤(µ −ˆµt) ≥Bt|t ∈Da . Suppose t ∈Da and let D be a positive definite diagonal matrix (that depends on a). Let St = Pt−1 s=1 IAs∩A∗C 1/2ϵs, Vt = Pt−1 s=1 CAs∩A∗and IVt+D(ϵ) = 1 2 ∥St∥2 (Vt+D)−1. Lemma 4. Let δt > 0 and let ˜f(δt) be a function of δt. With a choice of D such that IA∗D ⪯ λIA∗ΣCDt for all t in Da, P A∗⊤(µ−ˆµt)≥ q 2 ˜f(δt)A∗⊤D−1 t (λΣCDt+Vt)D−1 t A∗ t∈Da ≤P n IVt+D(ϵ)≥˜f(δt)|t∈Da o . Proof in appendix B.2 of the supplementary material. The self-normalized sum IVt(ϵ) is an interesting quantity for the following reason: exp( 1 2IVt(ϵ)) = maxu∈Rd Qt−1 s=1 exp(u⊤IAs∩A∗C 1/2ϵs −u⊤CAs∩A∗u). For a given u, the exponential is smaller that 1 in expectation, from the subgaussian hypothesis. The maximum of the expectation is then smaller than 1. To control IVt(ϵ), we are however interested in the expectation of this maximum and cannot interchange max and E. The method of mixtures circumvents this difficulty: it provides an approximation of the maximum by integrating the exponential against a multivariate normal centered at the point V −1 t St, where the maximum is attained. The integrals over u and ϵ can then be swapped by Fubini’s theorem to get an approximation of the expectation of the maximum using an integral of the expectations. Doing so leads to the following lemma, extracted from the proof of Theorem 1 of Abbasi-Yadkori et al. [2011]. Lemma 5. Let D be a positive definite matrix that does not depend on t and Mt(D) = q det D det(Vt+D) exp(IVt+D(ϵ)). Then E[Mt(D)] ≤1. We rewrite P n IVt+D(ϵ) ≥˜f(δt) o to introduce Mt(D), P n IVt+D(ϵ) ≥˜f(δt)|t∈Da o = P ( Mt(D) ≥ 1 p det(Id + D−1/2VtD−1/2) exp( ˜f(δt)) t∈Da ) . The peeling lets us bound Vt. Let Da be the diagonal matrix with entry (i, i) equal to (1 + η)ai for i ∈A∗and 0 elsewhere. Lemma 6. With D = λΣCDa + I[d]\A∗, det(Id + D−1/2VtD−1/2) ≤(1 + 1+η λ )m . The union bound on the sets Da and Markov’s inequality give P A∗⊤(µ −ˆµt) ≥ q 2 ˜f(δt) q λA∗⊤ΣCD−1 t A∗+ A∗⊤D−1 t VtD−1 t A∗ ≤ X Da P Mt(D) ≥(1 + 1 + η λ )−m/2 exp( ˜f(δt))|t ∈Da ≤ log t log(1 + η) m (1 + 1 + η λ )m/2 exp(−˜f(δt)) For η = e −1 and ˜f(δt) as in lemma 3, this is bounded by δt. The result with Γ instead of C is a consequence of C ⪯+ Γ. With δ1 = 1 and δt = 1/(t log2 t) for t ≥2, the regret due to Gt is E[ T X t=1 ∆tI{Gt}] ≤∆max(1 + T X t=2 1 t log2 t) ≤4∆max . 6 3.6 Bounding the variance term The goal of this section is to bound Et(At) under the event {∆t ≤Et(At)}. Let γt ∈[0, 1] such that for all i, j ∈At with i ̸= j, Γ(ij) ≤γt √ Γ(ii)Γ(jj). From the Cauchy-Schwartz inequality, n(ij) t ≤ q n(i) t n(j) t . Using these two inequalities, A⊤ t D−1 t ( t−1 X s=1 ΓAs)D−1 t At = X i,j∈At n(ij) t Γ(ij) n(i) t n(j) t ≤(1 −γt) X i∈At Γ(ii) n(i) t + γt( X i∈At s Γ(ii) n(i) t )2 . We recognize here the forms of the indexes used in Combes et al. [2015] for independent arms (left term) and Kveton et al. [2015] for general arms (right term). Using ∆t ≤Et(At) we get ∆2 t 8f(t) ≤(λ + 1 −γt) X i∈At Γ(ii) n(i) t + γt( X i∈At s Γ(ii) n(i) t )2 . (1) The strategy from here is to find events that must happen when (1) holds and to show that these events cannot happen very often. For positive integers j and t and for e ∈{1, 2}, we define the set of arms in At that were pulled less than a given threshold: Sj t,e = {i ∈At, n(i) t ≤αj,e 8f(t)Γ(ii)ge(m,γt) ∆2 t }, with ge(m, γt) to be stated later and (αi,e)i≥1 a decreasing sequence. Let also S0 t,e = At. (Sj t,e)j≥0 is decreasing for the inclusion of sets and we impose limj→+∞αj,e = 0, such that there is an index j∅with Sj∅ t,e = ∅. We introduce another positive sequence (βj,e)j≥0 and consider the events that at least mβj,e arms in At are in the set Sj t,e and that the same is false for k < j, i.e. for t ≥1, Aj t,e = {|Sj t,e| ≥mβj,e; ∀k < j, |Sk t,e| < mβk,e}. To avoid having some of these events being impossible we choose (βj,e)j≥0 decreasing. We also impose β0,e = 1, such that |S0 t,e| = mβ0,e. Let then At,e = ∪+∞ j=1Aj t,e and At = At,1 ∪At,2. We will show that At must happen for (1) to be true. First, remark that under a condition on (βj,e)j≥0, At is a finite union of events, Lemma 7. For e ∈{1, 2}, if there exists j0,e such that βj0,e,e ≤1/m, then At,e = ∪j0 j=1Aj t,e. We now show that At is impossible by proving a contradiction in (1). Lemma 8. Under the event At,1, if there exists j0 such that βj0,1 ≤1/m, then X i∈At Γ(ii) n(i) t < m∆2 t 8f(t)g1(m, γt) j0 X j=1 βj−1,1 −βj,1 αj,1 + βj0,1 αj0,1 . Under the event At,2, if limj→+∞βj,2/√αj,2 = 0 and P+∞ j=1 βj−1,2−βj,2 √αj,2 exists, then X i∈At s Γ(ii) n(i) t ≤ m∆t p 8f(t)g2(m, γt) +∞ X j=1 βj−1,2 −βj,2 √αj,2 . A proof can be found in appendix B.2 of the supplementary material. To ensure that the conditions of these lemmas are fulfilled, we impose that (βi,1)i≥0 and (βi,2)i≥0 have limit 0 and that limj→+∞βj,2/√αj,2 = 0. Let j0,1 be the smallest integer such that βj0,1,1 ≤1/m. Let l1 = βj0,1,1 αj0,1,1 + Pj0,1 j=1 βj−1,1−βj,1 αj,1 and l2 = P+∞ j=1 βj−1,2−βj,2 √αj,2 . Using the two last lemmas with (1), we get that if At is true, ∆2 t 8f(t) < ∆2 t 8f(t) (λ + 1 −γt) ml1 g1(m, γt) + γt m2l2 2 g2(m, γt) . Taking g1(m, γt) = 2(λ + 1 −γt)ml1 and g2(m, γt) = 2γtm2l2 2, we get a contradiction. Hence with these choices At must happen. The regret bound will be obtained by a union bound on the events that form At. First suppose that all gaps are equal to the same ∆. 7 Lemma 9. Let γ = maxt≥1 γt. For j ∈ N∗, the event Aj t,e happens at most dαj,e8f(T ) maxi{Γ(ii)}ge(m,γ) mβj,e∆2 times. Proof. Each time that Aj t,e happens, the counter of plays n(i) t of at least mβje arms is incremented. After αj,e8f(T ) maxi{Γ(ii)}ge(m,γ) ∆2 increments, an arm cannot verify the condition on n(i) t any more. There are d arms, so the event can happen at most d 1 mβje αj,e8f(T ) maxi{Γ(ii)}ge(m,γ) ∆2 times. If all gaps are equal to ∆, an union bound for At gives E[ T X t=1 ∆I{Ht ∩Gt}] ≤16 max i∈[d]{Γ(ii)}f(T) ∆d (λ + 1 −γ)l1 j0,1 X j=1 αj,1 βj,1 + γml2 2 +∞ X j=1 αj,2 βj,2 . The general case requires more involved manipulations but the result is similar and no new important idea is used. The following lemma is proved in appendix B.2 of the supplementary material: Lemma 10. Let γ(i) = max{t,i∈At} γt. The regret from the event Ht ∩Gt is such that E[ T X t=1 ∆tI{Ht ∩Gt}] ≤16f(T) X i∈[d] Γ(ii) ∆i,min (λ + 1 −γ)l1 j0 X j=1 αj,1 βj,1 + γml2 2 +∞ X j=1 αj,2 βj,2 . Finally we can find sequences (αj,1)j≥1, (αj,2)j≥1, (βj,1)j≥0 and (βj,2)j≥0 such that E[ T X t=1 ∆I{Ht ∩Gt}] ≤16f(T) X i∈[d] Γ(ii) ∆i,min 5(λ + 1 −γ(i)) log m 1.6 2 + 45γ(i)m ! See appendix C of the supplementary material. In Combes et al. [2015], αi,1 and βi,1 were such that the log2 m term was replaced by √m. Our choice is also applicable to their ESCB algorithm. Our use of geometric sequences is only optimal among sequences such that βi,1 = αi,1 for all i ≥1. It is unknown to us if one can do better. With this control of the variance term, we finally proved Theorem 2. 4 Conclusion We defined a continuum of settings from the general to the independent arms cases which is suitable for the analysis of semi-bandit algorithms. We exhibited a lower bound scaling with a parameter that quantifies the particular setting in this continuum and proposed an algorithm inspired from linear regression with an upper bound that matches the lower bound up to a log2 m term. Finally we showed how to use tools from the linear bandits literature to analyse algorithms for the combinatorial bandit case that are based on linear regression. It would be interesting to estimate the subgaussian covariance matrix online to attain good regret bounds without prior knowledge. Also, our algorithm is not computationally efficient since it requires the computation of an argmax over the actions at each stage. It may be possible to compute this argmax less often and still keep the regret guaranty, as was done in Abbasi-Yadkori et al. [2011] and Combes et al. [2015]. On a broader scope, the inspiration from linear regression could lead to algorithms using different estimators, adapted to the structure of the problem. For example, the weighted least-square estimator is also unbiased and has smaller variance than OLS. Or one could take advantage of a sparse covariance matrix by using sparse estimators, as was done in the linear bandit case in Carpentier and Munos [2012]. Acknowledgements The authors would like to acknowledge funding from the ANR under grant number ANR-13-JS010004 as well as the Fondation Mathématiques Jacques Hadamard and EDF through the Program Gaspard Monge for Optimization and the Irsdi project Tecolere. 8 References Yasin Abbasi-Yadkori, David Pal, and Csaba Szepesvari. Improved Algorithms for Linear Stochastic Bandits. Neural Information Processing Systems, pages 1–19, 2011. Jean-Yves Audibert, Sébastien Bubeck, and Gábor Lugosi. Regret in online combinatorial optimization. Mathematics of Operations Research, 39(1):31–45, 2013. Peter Auer, Nicolo Cesa-Bianchi, and Paul Fischer. Finite-time analysis of the multiarmed bandit problem. Machine learning, 47(2-3):235–256, 2002. Alexandra Carpentier and Rémi Munos. Bandit Theory meets Compressed Sensing for high dimensional Stochastic Linear Bandit. Advances in Neural Information Processing Systems (NIPS), pages 251–259, 2012. Nicolo Cesa-Bianchi and Gábor Lugosi. Combinatorial bandits. Journal of Computer and System Sciences, 78 (5):1404–1422, 2012. Wei Chen, Yajun Wang, and Yang Yuan. Combinatorial multi-armed bandit: General framework and applications. Proceedings of the 30th International Conference on Machine Learning (ICML), pages 151–159, 2013. Richard Combes, M. Sadegh Talebi, Alexandre Proutiere, and Marc Lelarge. Combinatorial Bandits Revisited. Neural Information Processing Systems, pages 1–9, 2015. Sarah Filippi, Olivier Cappé, Aurélien Garivier, and Csaba Szepesvári. Parametric Bandits: The Generalized Linear Case. Neural Information Processing Systems, pages 1–9, 2010. Yi Gai, Bhaskar Krishnamachari, and Rahul Jain. Combinatorial network optimization with unknown variables: Multi-armed bandits with linear rewards and individual observations. IEEE/ACM Transactions on Networking, 20(5):1466–1478, 2012. Aurélien Garivier. Informational confidence bounds for self-normalized averages and applications. 2013 IEEE Information Theory Workshop, ITW 2013, 2013. Junpei Komiyama, Junya Honda, and Hiroshi Nakagawa. Optimal Regret Analysis of Thompson Sampling in Stochastic Multi-armed Bandit Problem with Multiple Plays. Proceedings of the 32nd International Conference on Machine Learning, 2015. Branislav Kveton, Zheng Wen, Azin Ashkan, and Csaba Szepesvari. Tight regret bounds for stochastic combinatorial semi-bandits. Proceedings of the 18th International Conference on Artificial Intelligence and Statistics, 2015. Tze Leung Lai and Herbert Robbins. Asymptotically efficient adaptive allocation rules. Advances in applied mathematics, 6(1):4–22, 1985. Victor H Peña, Tze Leung Lai, and Qi-Man Shao. Self-normalized processes: Limit theory and Statistical Applications. Springer Science & Business Media, 2008. Herbert Robbins. Some aspects of the sequential design of experiments. In Herbert Robbins Selected Papers, pages 169–177. Springer, 1985. Paat Rusmevichientong and John N. Tsitsiklis. Linearly Parameterized Bandits. Mathematics of Operations Research, (1985):1–40, 2010. 9 | 2016 | 517 |
6,458 | Perspective Transformer Nets: Learning Single-View 3D Object Reconstruction without 3D Supervision Xinchen Yan1 Jimei Yang2 Ersin Yumer2 Yijie Guo1 Honglak Lee1,3 1University of Michigan, Ann Arbor 2Adobe Research 3Google Brain {xcyan,guoyijie,honglak}@umich.edu, {jimyang,yumer}@adobe.com Abstract Understanding the 3D world is a fundamental problem in computer vision. However, learning a good representation of 3D objects is still an open problem due to the high dimensionality of the data and many factors of variation involved. In this work, we investigate the task of single-view 3D object reconstruction from a learning agent’s perspective. We formulate the learning process as an interaction between 3D and 2D representations and propose an encoder-decoder network with a novel projection loss defined by the perspective transformation. More importantly, the projection loss enables the unsupervised learning using 2D observation without explicit 3D supervision. We demonstrate the ability of the model in generating 3D volume from a single 2D image with three sets of experiments: (1) learning from single-class objects; (2) learning from multi-class objects and (3) testing on novel object classes. Results show superior performance and better generalization ability for 3D object reconstruction when the projection loss is involved. 1 Introduction Understanding the 3D world is at the heart of successful computer vision applications in robotics, rendering and modeling [19]. It is especially important to solve this problem using the most convenient visual sensory data: 2D images. In this paper, we propose an end-to-end solution to the challenging problem of predicting the underlying true shape of an object given an arbitrary single image observation of it. This problem definition embodies a fundamental challenge: Imagery observations of 3D shapes are interleaved representations of intrinsic properties of the shape itself (e.g., geometry, material), as well as its extrinsic properties that depend on its interaction with the observer and the environment (e.g., orientation, position, and illumination). Physically principled shape understanding should be able to efficiently disentangle such interleaved factors. This observation leads to insight that an end-to-end solution to this problem from the perspective of learning agents (neural networks) should involve the following properties: 1) the agent should understand the physical meaning of how a 2D observation is generated from the 3D shape, and 2) the agent should be conscious about the outcome of its interaction with the object; more specifically, by moving around the object, the agent should be able to correspond the observations to the viewpoint change. If such properties are embodied in a learning agent, it will be able to disentangle the shape from the extrinsic factors because these factors are trivial to understand in the 3D world. To enable the agent with these capabilities, we introduce a built-in camera system that can transform the 3D object into 2D images in-network. Additionally, we architect the network such that the latent representation disentangles the shape from view changes. More specifically, our network takes as input an object image and predicts its volumetric 3D shape so that the perspective transformations of predicted shape match well with corresponding 2D observations. We implement this neural network based on a combination of image encoder, volume decoder and perspective transformer (similar to spatial transformer as introduced by Jaderberg et al. [6]). During training, the volumetric 3D shape is gradually learned from single-view input and the feedback of other views through back-propagation. Thus at test time, the 3D shape can be directly 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. generated from a single image. We conduct experimental evaluations using a subset of 3D models from ShapeNetCore [1]. Results from single-class and multi-class training demonstrate excellent performance of our network for volumetric 3D reconstruction. Our main contributions are summarized below. • We show that neural networks are able to predict 3D shape from single-view without using the ground truth 3D volumetric data for training. This is made possible by introducing a 2D silhouette loss function based on perspective transformations. • We train a single network for multi-class 3D object volumetric reconstruction and show its generalization potential to unseen categories. • Compared to training with full azimuth angles, we demonstrate comparatively similar results when training with partial views. 2 Related Work Representation learning for 3D objects. Recently, advances have been made in learning deep neural networks for 3D objects using large-scale CAD databases [22, 1]. Wu et al. [22] proposed a deep generative model that extends the convolutional deep belief network [11] to model volumetric 3D shapes. Different from [22] that uses volumetric 3D representation, Su et al. [18] proposed a multi-view convolutional network for 3D shape categorization with a view-pooling mechanism. These methods focus more on 3D shape recognition instead of 3D shape reconstruction. Recent work [20, 14, 4, 2] attempt to learn a joint representation for both 2D images and 3D shapes. Tatarchenko et al. [20] developed a convolutional network to synthesize unseen 3D views from a single image and demonstrated the synthesized images can be used them to reconstruct 3D shape. Qi et al. [14] introduced a joint embedding by combining volumetric representation and multi-view representation together to improve 3D shape recognition performance. Girdhar et al. [4] proposed a generative model for 3D volumetric data and combined it with a 2D image embedding network for single-view 3D shape generation. Choy et al. [2] introduce a 3D recurrent neural network (3D-R2N2) based on long-short term memory (LSTM) to predict the 3D shape of an object from a single view or multiple views. Compared to these single-view methods, our 3D reconstruction network is learned end-to-end and the network can be even trained without ground truth volumes. Concurrent to our work, Renzede et al. [16] introduced a general framework to learn 3D structures from 2D observations with 3D-2D projection mechanism. Their 3D-2D projection mechanism either has learnable parameters or adopts non-differentiable component using MCMC, while our perspective projection nets is both differentiable and parameter-free. Representation learning by transformations. Learning from transformed sensory data has gained attention [12, 5, 15, 13, 23, 6, 24] in recent years. Memisevic and Hinton [12] introduced a gated Boltzmann machine that models the transformations between image pairs using multiplicative interaction. Reed et al. [15] showed that a disentangled hidden unit representations of Boltzmann Machines (disBM) could be learned based on the transformations on data manifold. Yang et al. [23] learned out-of-plane rotation of rendered images to obtain disentangled identity and viewpoint units by curriculum learning. Kulkarni et al. [9] proposed to learn a semantically interpretable latent representation from 3D rendered images using variational auto-encoders [8] by including specific transformations in mini-batches. Complimentary to convolutional networks, Jaderberg et al. [6] introduced a differentiable sampling layer that directly incorporates geometric transformations into representation learning. Concurrent to our work, Wu et al. [21] proposed a 3D-2D projection layer that enables the learning of 3D object structures using 2D keypoints as annotation. 3 Problem Formulation In this section, we develop neural networks for reconstructing 3D objects. From the perspective of a learning agent (e.g., neural network), a natural way to understand one 3D object X is from its 2D views by transformations. By moving around the 3D object, the agent should be able to recognize its unique features and eventually build a 3D mental model of it as illustrated in Figure 1(a). Assume that I(k) is the 2D image from k-th viewpoint α(k) by projection I(k) = P(X; α(k)), or rendering in graphics. An object X in a certain scene is the entanglement of shape, color and texture (its intrinsic properties) and the image I(k) is the further entanglement with viewpoint and illumination (extrinsic parameters). The general goal of understanding 3D objects can be viewed as disentangling intrinsic properties and extrinsic parameters from a single image. 2 2D image: I(1) I(2) I(3) I(4) … 3D object Camera (a) Input 2D Image I(1) Volume V (b) Target 2D mask S(1) S(2) S(3) S(4) S(5) Transformations {T(1),T(2),...T(n)} dmax dmin image volume U volume V camera (c) Figure 1: (a) Understanding 3D object from learning agent’s perspective; (b) Single-view 3D volume reconstruction with perspective transformation. (c) Illustration of perspective projection. The minimum and maximum disparity in the screen coordinates are denoted as dmin and dmax. In this paper, we focus on the 3D shape learning by ignoring the color and texture factors, and we further simplify the problem by making the following assumptions: 1) the scene is clean white background; 2) the illumination is constant natural lighting. We use the volumetric representation of 3d shape V where each voxel Vi is a binary unit. In other words, the voxel equals to one, i.e., Vi = 1, if the i-th voxel sapce is occupied by the shape; otherwise Vi = 0. Assuming the 2D silhouette S(k) is obtained from the k-th image I(k), we can specify the 3D-2D projection S(k) = P(V; α(k)). Note that 2D silhouette estimation is typically solved by object segmentation in real-world but it becomes trivial in our case due to the white background. In the following sub-sections, we propose a formulation for learning to predict the volumetric 3D shape V from an image I(k) with and without the 3D volume supervision. 3.1 Learning to Reconstruct Volumetric 3D Shape from Single-View We consider single-view volumetric 3D reconstruction as a dense prediction problem and develop a convolutional encoder-decoder network for this learning task denoted by ˆV = f(I(k)). The encoder network h(·) learns a viewpoint-invariant latent representation h(I(k)) which is then used by the decoder g(·) to generate the volume ˆV = g(h(I(k))). In case the ground truth volumetric shapes V are available, the problem can be easily considered as learning volumetric 3D shapes with a regular reconstruction objective in 3D space: Lvol(I(k)) = ||f(I(k)) −V||2 2. In practice, however, the ground truth volumetric 3D shapes may not be available for training. For example, the agent observes the 2D silhouette via its built-in camera without accessing the volumetric 3D shape. Inspired by the space carving theory [10], we propose a silhouette-based volumetric loss function. In particular, we build on the premise that a 2D silhouette ˆS(j) projected from the generated volume ˆV under certain camera viewpoint α(j) should match the ground truth 2D silhouette S(j) from image observations. In other words, if all the generated silhouettes ˆS(j) match well with their corresponding ground truth silhouettes S(j) for all j’s, then we hypothesize that the generated volume ˆV should be as good as one instance of visual hull equivalent class of the ground truth volume V [10]. Therefore, we formulate the learning objective for the k-th image as Lproj(I(k)) = n X j=1 L(j) proj(I(k); S(j), α(j)) = 1 n n X j=1 ||P(f(I(k)); α(j)) −S(j)||2 2, (1) where j is the index of output 2D silhouettes, n is the number of silhouettes used for each input image and P(·) is the 3D-2D projection function. Note that the above training objective Eq. (1) enables training without using ground-truth volumes. The network diagram is illustrated in Figure 1(b). A more general learning objective is given by a combination of both objectives: Lcomb(I(k)) = λprojLproj(I(k)) + λvolLvol(I(k)), (2) where λproj and λvol are constants that control the tradeoff between the two losses. 3.2 Perspective Transformer Nets As defined previously, 2D silhouette S(k) is obtained via perspective projection given input 3D volume V and specific camera viewpoint α(k). In this work, we implement the perspective projection 3 (see Figure 1(c)) with a 4-by-4 transformation matrix Θ4×4, where K is camera calibration matrix and (R, t) is extrinsic parameters. Θ4×4 = K 0 0T 1 R t 0T 1 (3) For each point ps i = (xs i, ys i , zs i , 1) in 3D world coordinates, we compute the corresponding point pt i = (xt i, yt i, 1, dt i) in screen coordinates (plus disparity dt i) using the perspective transformation: ps i ∼Θ4×4pt i. Similar to the spatial transformer network introduced in [6], we propose a 2-step procedure : (1) performing dense sampling from input volume (in 3D world coordinates) to output volume (in screen coordinates), and (2) flattening the 3D spatial output across disparity dimension. In the experiment, we assume that transformation matrix is always given as input, parametrized by the viewpoint α. Again, the 3D point (xs i, ys i , zs i ) in input volume V ∈RH×W ×D and corresponding point (xt i, yt i, dt i) in output volume U ∈RH′×W ′×D′ is linked by perspective transformation matrix Θ4×4. Here, (W, H, D) and (W ′, H′, D′) are the width, height and depth of input and output volume, respectively. We summarize the dense sampling step and channel-wise flattening step as follows. Ui = H X n W X m D X l Vnml max(0, 1 −|xs i −m|) max(0, 1 −|ys i −n|) max(0, 1 −|zs i −l|) Sn′m′ = max l′ Un′m′l′ (4) Here, Ui is the i-th voxel value corresponding to the point (xt i, yt i, dt i) (where i ∈{1, ..., W ′ × H′ × D′}). Note that we use the max operator for projection instead of summation along one dimension since the volume is represented as a binary cube where the solid voxels have value 1 and empty voxels have value 0. Intuitively, we have the following two observations: (1) each empty voxel will not contribute to the foreground pixel of S from any viewpoint; (2) each solid voxel can contribute to the foreground pixel of S only if it is visible from specific viewpoint. 3.3 Training As the same volumetric 3D shape is expected to be generated from different images of the object, the encoder network is required to learn a 3D view-invariant latent representation h(I(1)) = h(I(2)) = · · · = h(I(k)) (5) This sub-problem itself is a challenging task in computer vision [23, 9]. Thus, we adopt a two-stage training procedure: first we learn the encoder network for a 3D view-invariant latent representation h(I) and then train the volumetric decoder with perspective transformer networks. As shown in [23], a disentangled representation of 2D synthetic images can be learned from consecutive rotations with a recurrent network, we pre-train the encoder of our network using a similar curriculum strategy so that the latent representation only contains 3D view-invariant identity information of the object. Once we obtain an encoder network that recognizes the identity of single-view images, we next learn the volume generator regularized by the perspective transformer networks. To encourage the volume decoder to learn a consistent 3D volume from different viewpoints, we include the projections from neighboring viewpoints in each mini-batch so that the network has relatively sufficient information to reconstruct the 3D shape. 4 Experiments ShapeNetCore. This dataset contains about 51,300 unique 3D models from 55 common object categories [1]. Each 3D model is rendered from 24 azimuth angles (with steps of 15◦) with fixed elevation angles (30◦) under the same camera and lighting setup. We then crop and rescale the centering region of each image to 64 × 64 × 3 pixels. For each ground truth 3D shape, we create a volume of 32 × 32 × 32 voxels from its canonical orientation (0◦). Network Architecture. As shown in Figure 2, our encoder-decoder network has three components: a 2D convolutional encoder, a 3D up-convolutional decoder and a perspective transformer networks. The 2D convolutional encoder consists of 3 convolution layers, followed by 3 fully-connected layers (convolution layers have 64, 128 and 256 channels with fixed filter size of 5 × 5; the three fullyconnected layers have 1024, 1024 and 512 neurons, respectively). The 3D convolutional decoder 4 5x5 conv 5x5 conv 5x5 conv 64x64x3 32x32x64 16x16x128 8x8x256 Volume Generator Perspective Transformer 1x1x 512 latent unit 1x1x1024 1x32x32x32 6x6x6 conv 4x4 transformation 1x32x32 Encoder Decoder 1x1x1024 512x3x3x3 256x6x6x6 96x15x15x15 4x4x4 conv 5x5x5 conv Τθ(G) Grid generator Sampler 1x32x32x32 Input image Target projection Figure 2: Illustration of network architecture. consists of one fully-connected layer, followed by 3 convolution layers (the fully-connected layer have 3 × 3 × 3 × 512 neurons; convolution layers have 256, 96 and 1 channels with filter size of 4 × 4 × 4, 5 × 5 × 5 and 6 × 6 × 6). For perspective transformer networks, we used perspective transformation to project 3D volume to 2D silhouette where the transformation matrix is parametrized by 16 variables and sampling grid is set to 32 × 32 × 32. We use the same network architecture for all the experiments. Implementation Details. We used the ADAM [7] solver for stochastic optimization in all the experiments. During the pre-training stage (for encoder), we used mini-batch of size 32, 32, 8, 4, 3 and 2 for training the RNN-1, RNN-2, RNN-4, RNN-8, RNN-12 and RNN-16 as used in Yang et al. [23]. We used the learning rate 10−4 for RNN-1, and 10−5 for the rest of recurrent neural networks. During the fine-tuning stage (for volume decoder), we used mini-batch of size 6 and learning rate 10−4. For each object in a mini-batch, we include projections from all 24 views as supervision. The models including the perspective transformer nets are implemented using Torch [3]. To download the code, please refer to the project webpage: http://goo.gl/YEJ2H6. Experimental Design. As mentioned in the formulation, there are several variants of the model depending on the hyper-parameters of learning objectives λproj and λvol. In the experimental section, we denote the model trained with projection loss only, volume loss only, and combined loss as PTN-Proj (PR), CNN-Vol (VO), and PTN-Comb (CO), respectively. In the experiments, we address the following questions: (1) Will the model trained with combined loss achieve better single-view 3D reconstruction performance over model trained on volume loss only (PTN-Comb vs. CNN-Vol)? (2) What is the performance gap between the models with and without ground-truth volumes (PTN-Comb vs. PTN-Proj)? (3) How do the three models generalize to instances from unseen categories which are not present in the training set? To answer the questions, we trained the three models under two experimental settings: single category and multiple categories. 4.1 Training on single category We select chair category as the training set for single category experiment. For model comparisons, we first conduct quantitative evaluations on the generated 3D volumes from the test set single-view images. For each instance in the test set, we generate one volume per view image (24 volumes generated in total). Given a pair of ground-truth volume and our generated volume (threshold is 0.5), we computed its intersection-over-union (IU) score and the average IU score is calculated over 24 volumes of all the instances in the test set. In addition, we provide a baseline method based on nearest neighbor (NN) search. Specifically, for each of the test image, we extract VGG feature from fc6 layer (4096-dim vector) [17] and retrieve the nearest training example using Euclidean distance in the feature space. The ground-truth 3D volume corresponds to the nearest training example is naturally regarded as the retrieval result. Table 1: Prediction IU using the models trained on chair category. Below, “chair" corresponds to the setting where each object is observable with full azimuth angles, while “chair-N" corresponds to the setting where each object is only observable with narrow range (subset) of azimuth angles. Method / Evaluation Set chair chair-N training test training test PTN-Proj:single (no vol. supervision) 0.5712 0.5027 0.4882 0.4583 PTN-Comb:single (vol. supervision) 0.6435 0.5067 0.5564 0.4429 CNN-Vol:single (vol. supervision) 0.6390 0.4983 0.5518 0.4380 NN search (vol. supervision) — 0.3557 — 0.3073 5 Input GT (310) GT (130) PR (310) PR (130) CO (310) CO (130) VO (310) VO (130) Figure 3: Single-class results. GT: ground truth, PR: PTN-Proj, CO: PTN-Comb, VO: CNN-Vol (Best viewed in digital version. Zoom in for the 3D shape details). The angles are shown in the parenthesis. Please also see more examples and video animations on the project webpage. As shown in Table 1, the model trained without volume supervision (projection loss) performs as good as model trained with volume supervision (volume loss) on the chair category (testing set). In addition to the comparisons of overall IU, we measured the view-dependent IU for each model. As shown in Figure 4, the average prediction error (mean IU) changes as we gradually move from the first view to the last view (15◦to 360◦). For visual comparisons, we provide a side-by-side analysis for each of the three models we trained. As shown in Figure 3, each row shows an independent comparison. The first column is the 2D image we used as input of the model. The second and third column show the ground-truth 3D volume (same volume rendered from two views for better visualization purpose). Similarly, we list the model trained with projection loss only (PTN-Proj), combined loss (PTN-Comb) and volume loss only (CNN-Vol) from fourth column up to ninth column. The volumes predicted by PTN-Proj and PTN-Comb faithfully represent the shape. However, the volumes predicted by CNN-Vol do not form a solid chair shape in some cases. 0 50 100 250 300 350 150 200 Azimuth (degree) 0.44 0.42 0.4 0.46 0.48 0.52 0.5 Mean IU PTN-Proj PTN-Comb CNN-Vol Figure 4: View-dependent IU. For illustration, images of a sample chair with corresponding azimuth angles are shown below the curves. For example, 3D reconstruction from 0◦is more difficult than from 30◦due to self-occlusion. 6 Table 2: Prediction IU using the models trained on large-scale datasets. Test Category airplane bench dresser car chair display lamp PTN-Proj:multi 0.5556 0.4924 0.6823 0.7123 0.4494 0.5395 0.4223 PTN-Comb:multi 0.5836 0.5079 0.7109 0.7381 0.4702 0.5473 0.4158 CNN-Vol:multi 0.5747 0.5142 0.6975 0.7348 0.4451 0.5390 0.3865 NN search 0.5564 0.4875 0.5713 0.6519 0.3512 0.3958 0.2905 Test Category loudspeaker rifle sofa table telephone vessel PTN-Proj:multi 0.5868 0.5987 0.6221 0.4938 0.7504 0.5507 PTN-Comb:multi 0.5675 0.6097 0.6534 0.5146 0.7728 0.5399 CNN-Vol:multi 0.5478 0.6031 0.6467 0.5136 0.7692 0.5445 NN search 0.4600 0.5133 0.5314 0.3097 0.6696 0.4078 Input GT (310) GT (130) PR (310) PR (130) CO (310) CO (130) VO (310) VO (130) Figure 5: Multiclass results. GT: ground truth, PR: PTN-Proj, CO: PTN-Comb, VO: CNN-Vol (Best viewed in digital version. Zoom in for the 3D shape details). The angles are shown in the parenthesis. Please also see more examples and video animations on the project webpage. Training with partial views. We also conduct control experiments where each object is only observable from narrow range of azimuth angles (e.g., 8 out of 24 views such as 0◦, 15◦, · · · , 105◦). We include the detailed description in the supplementary materials. As shown in Table 1 (last two columns), performances of all three models drop a little bit but the conclusion is similar: the proposed network (1) learns better 3D shape with projection regularization and (2) is capable of learning the 3D shape by providing 2D observations only. 4.2 Training on multiple categories We conducted multiclass experiment using the same setup in the single-class experiment. For multicategory experiment, the training set includes 13 major categories: airplane, bench, dresser, car, chair, display, lamp, loudspeaker, rifle, sofa, table, telephone and vessel. Basically, we preserved 20% of instances from each category as testing data. As shown in Table 2, the quantitative results demonstrate (1) model trained with combined loss is superior to volume loss in most cases and (2) model trained with projection loss perform as good as volume/combined loss. From the visualization results shown in Figure 5, all three models predict volumes reasonably well. There is only subtle performance difference in object part such as the wing of airplane. 7 Table 3: Prediction IU in out-of-category tests. Method / Test Category bed bookshelf cabinet motorbike train PTN-Proj:single (no vol. supervision) 0.1801 0.1707 0.3937 0.1189 0.1550 PTN-Comb:single (vol. supervision) 0.1507 0.1186 0.2626 0.0643 0.1044 CNN-Vol:single (vol. supervision) 0.1558 0.1183 0.2588 0.0580 0.0956 PTN-Proj:multi (no vol. supervision) 0.1944 0.3448 0.6484 0.3216 0.3670 PTN-Comb:multi (vol. supervision) 0.1647 0.3195 0.5257 0.1914 0.3744 CNN-Vol:multi (vol. supervision) 0.1586 0.3037 0.4977 0.2253 0.3740 Input GT (310) GT (130) PR (310) PR (130) CO (310) CO (310) VO (130) VO (310) Figure 6: Out-of-category results. GT: ground truth, PR: PTN-Proj, CO: PTN-Comb, VO: CNN-Vol (Best viewed in digital version. Zoom in for the 3D shape details). The angles are shown in the parenthesis. Please also see more examples and video animations on the project webpage. 4.3 Out-of-Category Tests Ideally, an intelligent agent should have the ability to generalize the knowledge learned from previously seen categories to unseen categories. To this end, we design out-of-category tests for both models trained on a single category and multiple categories, as described in Section 4.1 and Section 4.2, respectively. We select 5 unseen categories from ShapeNetCore: bed, bookshelf, cabinet, motorbike and train for out-of-category tests. Here, the two categories cabinet and train are relatively easier than other categories since there might be instances in the training set with similar shapes (e.g., dresser, vessel, and airplane). But the bed,bookshelf and motorbike can be considered as completely novel categories in terms of shape. We summarized the quantitative results in Table 3. Suprisingly, the model trained on multiple categories still achieves reasonably good overall IU. As shown in Figure 6, the proposed projection loss generalizes better than model trained using combined loss or volume loss on train, motorbike and cabinet. The observations from the out-of-category tests suggest that (1) generalization from a single category is very challenging, but training from multiple categories can significantly improve generalization, and (2) the projection regularization can help learning a robust representation for better generalization on unseen categories. 5 Conclusions In this paper, we investigate the problem of single-view 3D shape reconstruction from a learning agent’s perspective. By formulating the learning procedure as the interaction between 3D shape and 2D observation, we propose to learn an encoder-decoder network which takes advantage of the projection transformation as regularization. Experimental results demonstrate (1) excellent performance of the proposed model in reconstructing the object even without ground-truth 3D volume as supervision and (2) the generalization potential of the proposed model to unseen categories. 8 Acknowledgments This work was supported in part by NSF CAREER IIS-1453651, ONR N00014-13-1-0762, Sloan Research Fellowship, and a gift from Adobe. We acknowledge NVIDIA for the donation of GPUs. We also thank Yuting Zhang, Scott Reed, Junhyuk Oh, Ruben Villegas, Seunghoon Hong, Wenling Shang, Kibok Lee, Lajanugen Logeswaran, Rui Zhang and Yi Zhang for helpful comments and discussions. References [1] A. X. Chang, T. Funkhouser, L. Guibas, P. Hanrahan, Q. Huang, Z. Li, S. Savarese, M. Savva, S. Song, H. Su, et al. Shapenet: An information-rich 3d model repository. arXiv preprint arXiv:1512.03012, 2015. [2] C. B. Choy, D. Xu, J. Gwak, K. Chen, and S. Savarese. 3d-r2n2: A unified approach for single and multi-view 3d object reconstruction. In ECCV, 2016. [3] R. Collobert, K. Kavukcuoglu, and C. Farabet. Torch7: A matlab-like environment for machine learning. In BigLearn, NIPS Workshop, number EPFL-CONF-192376, 2011. [4] R. Girdhar, D. F. Fouhey, M. Rodriguez, and A. Gupta. Learning a predictable and generative vector representation for objects. arXiv preprint arXiv:1603.08637, 2016. [5] G. E. Hinton, A. Krizhevsky, and S. D. Wang. Transforming auto-encoders. In ICANN. Springer, 2011. [6] M. Jaderberg, K. Simonyan, A. Zisserman, et al. Spatial transformer networks. In NIPS, 2015. [7] D. Kingma and J. Ba. Adam: A method for stochastic optimization. arXiv preprint arXiv:1412.6980, 2014. [8] D. P. Kingma and M. Welling. Auto-encoding variational bayes. arXiv preprint arXiv:1312.6114, 2013. [9] T. D. Kulkarni, W. Whitney, P. Kohli, and J. B. Tenenbaum. Deep convolutional inverse graphics network. In NIPS, 2015. [10] K. N. Kutulakos and S. M. Seitz. A theory of shape by space carving. International Journal of Computer Vision, 38(3):199–218, 2000. [11] H. Lee, R. Grosse, R. Ranganath, and A. Y. Ng. Convolutional deep belief networks for scalable unsupervised learning of hierarchical representations. In ICML, 2009. [12] R. Memisevic and G. Hinton. Unsupervised learning of image transformations. In CVPR, 2007. [13] V. Michalski, R. Memisevic, and K. Konda. Modeling deep temporal dependencies with recurrent grammar cells"". In NIPS, 2014. [14] C. R. Qi, H. Su, M. Niessner, A. Dai, M. Yan, and L. J. Guibas. Volumetric and multi-view cnns for object classification on 3d data. In CVPR, 2016. [15] S. Reed, K. Sohn, Y. Zhang, and H. Lee. Learning to disentangle factors of variation with manifold interaction. In ICML, 2014. [16] D. J. Rezende, S. Eslami, S. Mohamed, P. Battaglia, M. Jaderberg, and N. Heess. Unsupervised learning of 3d structure from images. In NIPS, 2016. [17] K. Simonyan and A. Zisserman. Very deep convolutional networks for large-scale image recognition. arXiv preprint arXiv:1409.1556, 2014. [18] H. Su, S. Maji, E. Kalogerakis, and E. Learned-Miller. Multi-view convolutional neural networks for 3d shape recognition. In ICCV, 2015. [19] R. Szeliski. Computer vision: algorithms and applications. Springer Science & Business Media, 2010. [20] M. Tatarchenko, A. Dosovitskiy, and T. Brox. Single-view to multi-view: Reconstructing unseen views with a convolutional network. In ECCV, 2016. [21] J. Wu, T. Xue, J. J. Lim, Y. Tian, J. B. Tenenbaum, A. Torralba, and W. T. Freeman. Single image 3d interpreter network. In ECCV, 2016. [22] Z. Wu, S. Song, A. Khosla, F. Yu, L. Zhang, X. Tang, and J. Xiao. 3d shapenets: A deep representation for volumetric shapes. In CVPR, 2015. [23] J. Yang, S. E. Reed, M.-H. Yang, and H. Lee. Weakly-supervised disentangling with recurrent transformations for 3d view synthesis. In NIPS, 2015. [24] E. Yumer and N. J. Mitra. Learning semantic deformation flows with 3d convolutional networks. In ECCV, 2016. 9 | 2016 | 518 |
6,459 | Exact Recovery of Hard Thresholding Pursuit Xiao-Tong Yuan B-DAT Lab Nanjing University of Info. Sci.&Tech. Nanjing, Jiangsu, 210044, China xtyuan@nuist.edu.cn Ping Li†‡ Tong Zhang† †Depart. of Statistics and ‡Depart. of CS Rutgers University Piscataway, NJ, 08854, USA {pingli,tzhang}@stat.rutgers.edu Abstract The Hard Thresholding Pursuit (HTP) is a class of truncated gradient descent methods for finding sparse solutions of ℓ0-constrained loss minimization problems. The HTP-style methods have been shown to have strong approximation guarantee and impressive numerical performance in high dimensional statistical learning applications. However, the current theoretical treatment of these methods has traditionally been restricted to the analysis of parameter estimation consistency. It remains an open problem to analyze the support recovery performance (a.k.a., sparsistency) of this type of methods for recovering the global minimizer of the original NP-hard problem. In this paper, we bridge this gap by showing, for the first time, that exact recovery of the global sparse minimizer is possible for HTP-style methods under restricted strong condition number bounding conditions. We further show that HTP-style methods are able to recover the support of certain relaxed sparse solutions without assuming bounded restricted strong condition number. Numerical results on simulated data confirms our theoretical predictions. 1 Introduction In modern high dimensional data analysis tasks, a routinely faced challenge is that the number of collected samples is substantially smaller than the dimensionality of features. In order to achieve consistent estimation in such small-sample-large-feature settings, additional assumptions need to be imposed on the model. Among others, the low-dimensional structure prior is the most popular assumption made in high dimensional analysis. This structure can often be captured by imposing sparsity constraint on model space, leading to the following ℓ0-constrained minimization problem: min x∈Rp f(x), s.t. ∥x∥0 ≤k, (1) where f : Rp 7→R is a smooth convex loss function and ∥x∥0 denotes the number of nonzero entries in x. Due to the cardinality constraint, Problem (1) is not only non-convex, but also NP-hard in general (Natarajan, 1995). Thus, it is desirable to develop efficient computational procedures to approximately solve this problem. When the loss function is squared regression error, Problem (1) reduces to the compressive sensing problem (Donoho, 2006) for which a vast body of greedy selection algorithms have been proposed including orthogonal matching pursuit (OMP) (Pati et al., 1993), compressed sampling matching pursuit (CoSaMP) (Needell & Tropp, 2009), hard thresholding pursuit (HTP) (Foucart, 2011) and iterative hard thresholding (IHT) (Blumensath & Davies, 2009) to name a few. The greedy algorithms designed for compressive sensing can usually be generalized to minimize non-quadratic loss functions (Shalev-Shwartz et al., 2010; Yuan & Yan, 2013; Bahmani et al., 2013). Comparing to those convex-relaxation-based methods (Beck & Teboulle, 2009; Agarwal et al., 2010), these greedy se30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. lection algorithms often exhibit similar accuracy guarantees but more attractive computational efficiency and scalability. Recently, the HTP/IHT-style methods have gained significant interests and they have been witnessed to offer the fastest and most scalable solutions in many cases (Yuan et al., 2014; Jain et al., 2014). The main theme of this class of methods is to iteratively perform gradient descent followed by a truncation operation to preserve the most significant entries, and an (optional) debiasing operation to minimize the loss over the selected entries. In (Blumensath, 2013; Yuan et al., 2014), the rate of convergence and parameter estimation error of HTP/IHT-style methods were established under proper Restricted Isometry Property (RIP) (or restricted strong condition number) bound conditions. Jain et al. (2014) presented and analyzed several relaxed variants of HTP/IHT-style algorithms for which the estimation consistency can be established without requiring the RIP conditions. Very recently, the extensions of HTP/IHT-style methods to structured and stochastic sparse learning problems have been investigated in (Jain et al., 2016; Li et al., 2016; Shen & Li, 2016). 1.1 An open problem: exact recovery of HTP In this paper, we are particularly interested in the exact recovery and support recovery performance of the HTP-style methods. A pseudo-code of HTP is outlined in Algorithm 1 which is also known as GraHTP in (Yuan et al., 2014). Although this type of methods have been extensively analyzed in the original paper (Foucart, 2011) for compressive sensing and several recent followup work (Yuan et al., 2014; Jain et al., 2014, 2016) for generic sparse minimization, the state-of-the-art is only able to derive convergence rates and parameter estimation error bounds for HTP. It remains an open and challenging problem to analyze its ability to exactly recover the global sparse minimizer of Problem (1) in general settings. Actually, the support/structure recovery analysis is the main challenge in many important sparsity models including compressive sensing and graphical models learning (Jalali et al., 2011; Ravikumar et al., 2011): once the support is recovered, computing the actual nonzero coefficients just boils down to solving a convex minimization problem restricted on the supporting set. Since the output of HTP is always k-sparse, the existing estimation error results in (Foucart, 2011; Yuan et al., 2014; Jain et al., 2014) naturally imply some support recovery conditions. For example, for perfect measurements, the results in (Foucart, 2011; Yuan et al., 2014) guarantee that HTP can exactly recover the underlying true sparse model parameters. For noisy models, roughly speaking, as long as the smallest (in magnitude) nonzero entry of the k-sparse minimizer of (1) is larger than the estimation error bound of HTP, an exact recovery of the minimizer can be guaranteed. However, these pieces of support recovery results implied by the estimation error bound turn out to be loose when compared to the main results we will derive in the current paper. Algorithm 1: Hard Thresholding Pursuit. Input :Loss function f(x), sparsity level k, step-size η. Initialization x(0) = 0, t = 1. Output:x(t). repeat (S1) Compute ˜x(t) = x(t−1) −η∇f(x(t−1)); (S2) Select F (t) = supp(˜x(t), k) be the indices of ˜x(t) with the largest k absolute values; (S3) Compute x(t) = arg min{f(x), supp(x) ⊆F (t)}; (S4) Update t ←t + 1; until F (t) = F (t−1); 1.2 Overview of our results The core contribution in this work is a deterministic support recovery analysis of HTP-style methods which to our knowledge has not been systematically conducted elsewhere in literature. Our first result (see Theorem 1) shows that HTP as described in Algorithm 1 is able to exactly recover the k-sparse minimizer x⋆= arg min∥x∥0≤k f(x) if x⋆ min, i.e., the smallest non-zero entry of x⋆, is significantly larger than ∥∇f(x⋆)∥∞and certain RIP-type condition can be fulfilled as well. Moreover, the exact recovery can be guaranteed in finite running of Algorithm 1 with geometric rate of convergence. Our second result (see Theorem 2) shows that the support recovery of an arbitrary k-sparse 2 Table 1: Comparison between our results and several prior results on HTP-style algorithms. Related Work Target Solution RIP Condition Free Support Recovery (Foucart, 2011) True k-sparse signal x × × (Yuan et al., 2014) Arbitrary ¯x with ∥¯x∥0 ≤k × × (Jain et al., 2014) ¯x = arg min∥x∥0≤¯k f(x) for proper ¯k ≪k √ × Ours Arbitrary ¯x with ∥¯x∥0 ≤k × (for ∥¯x∥0 = k), √(for ∥¯x∥0 ≪k) √ vector ¯x can be guaranteed if ¯xmin is well discriminated from √ k∥∇f(x⋆)∥∞or ∥∇f(x⋆)∥∞, pending on the optimality of ¯x over its own supporting set. Our third result (see Theorem 3) shows that HTP is able to recover the support of certain relaxed sparse minimizer ¯x with ∥¯x∥0 ≪k under an arbitrary restricted strong condition number. More formally, given the restricted strong smoothness/convexity (see Definition 1) constants M2k and m2k, the recovery of supp(¯x) is possible if k ≥(1 + 16M 2 2k/m2 2k)¯k and the smallest non-zero element in ¯x is significantly larger than the rooted objective value gap √ f(¯x) −f(x⋆). The support recovery can also be guaranteed in finite iteration for this case. By specifying our deterministic analysis to least squared regression and logistic regression, we are able to obtain the sparsistency guarantees of HTP for these statistical learning examples. Monte-Carlo simulation results confirm our theoretical predictions. Table 1 summarizes a high-level comparison between our work and the state-of-the-art analysis for HTP-style methods. 1.3 Notation and organization Notation Let x ∈Rp be a vector and F be an index set. We denote [x]i the ith entry of vector x, xF the restriction of x to index set F and xk the restriction of x to the top k (in absolute vale) entries. The notation supp(x) represents the index set of nonzero entries of x and supp(x, k) represents the index set of the top k (in absolute vale) entries of x. We conventionally define ∥x∥∞= maxi |[x]i| and define xmin = mini∈supp(x) |[x]i|. Organization This paper proceeds as follows: In §2, we analyze the exact recovery performance of HTP. The applications of our analysis to least squared regression and logistic regression models are presented in §3. Monte-Carlo simulation results are reported in §4. We conclude this paper in §5. Due to space limit, all the technical proofs of our results are deferred to an appendix section which is included in the supplementary material. 2 A Deterministic Exact Recovery Analysis In this section, we analyze the exact support recovery performance of HTP as outlined in Algorithm 1. In large picture, the theory developed in this section can be decomposed into the following three ingredients: • First, we will investigate the support recovery behavior of the global k-sparse minimizer x⋆= arg min∥x∥0≤k f(x). The related result is summarized in Proposition 1. • Second, we will present in Theorem 1 the guarantee of HTP for exactly recovering x⋆. • Finally, by combining the the above two results we will be able to establish the support recovery result of HTP in Theorem 2. Furthermore, we derive an RIP-condition-free support recovery result in Theorem 3. Our analysis relies on the conditions of Restricted Strong Convexity/Smoothness (RSC/RSS) which are conventionally used in previous analysis for HTP (Yuan et al., 2014; Jain et al., 2014). Definition 1 (Restricted Strong Convexity/Smoothness). For any integer s > 0, we say f(x) is restricted ms-strongly convex and Ms-smooth if there exist ms, Ms > 0 such that ms 2 ∥x −y∥2 ≤f(x) −f(y) −⟨∇f(y), x −y⟩≤Ms 2 ∥x −y∥2, ∀∥x −y∥0 ≤s. (2) 3 The ratio Ms/ms, which measures the curvature of the loss function over sparse subspaces, will be referred to as restricted strong condition number in this paper. 2.1 Preliminary: Support recovery of x⋆ Given a target solution ¯x, the following result establishes some sufficient conditions under which x⋆ is able to exactly recover the supporting set of ¯x. A proof of this result is provided in Appendix B (see the supplementary file). Proposition 1. Assume that f is M2k-smooth and m2k-strongly convex. Let ¯x be an arbitrary k-sparse vector. Let ¯x⋆= arg minsupp(x)⊆supp(¯x) f(x) and ¯l > 0 be a scalar such that f(¯x⋆) = f(¯x) + ⟨∇f(¯x), ¯x⋆−¯x⟩+ ¯l 2∥¯x⋆−¯x∥2 1. Then we have supp(¯x) = supp(x⋆) if either of the following two conditions is satisfied: (1) ¯xmin ≥2 √ 2k m2k ∥∇f(¯x)∥∞; (2) ¯xmin ≥ ( ¯ϑ M2k + 2 ¯ϑ+2 ¯l ) ∥∇f(¯x)∥∞, m2k M2k ≥max { 3 ¯ϑ+1 4 ¯ϑ , √ 3 2 } , for some ¯θ > 1. Remark 1. The quantity ¯l actually measures the strong-convexity of f at the point (¯x⋆−¯x) in ℓ1-norm. From its definition we can verify that ¯l is valued in the interval [m2k/k, M2k] if ¯x ̸= ¯x⋆. The closer ¯l is to M2k, the weaker lower bound condition can be imposed on ¯xmin in the condition (2). In (Nutini et al, 2015), a similar strong-convexity measurement has been defined over the entire vector space for refined convergence analysis of the coordinate descent methods. Different from (Nutini et al, 2015), we only require such an ℓ1-norm strong-convexity condition holds at certain target points of interest. Particularly if ¯x = ¯x⋆, i.e., ¯x is optimal over its supporting set, then we may simply set ¯l = ∞in Proposition 1. 2.2 Main results: Support recovery of HTP Equipped with Proposition 1, it will be straightforward to guarantee the support recovery of HTP if we can derive sufficient conditions under which HTP is able to exactly recover x⋆. Denote F ⋆= supp(x⋆). Intuitively, x⋆ min should be significantly larger than ∥∇f(x⋆)∥∞to attract HTP to be stuck at x⋆(see Lemma 5 in Appendix B for a formal elaboration). The exact recovery analysis also relies on the following quantity △−⋆which measures the gap between the minimal k-sparse objective value f(x∗) and the remaining ones over supporting sets other than supp(x∗): △−⋆:= f(x−⋆) −f(x⋆), where x−⋆= arg min∥x∥0≤k,supp(x)̸=supp(x⋆),f(x)>f(x⋆) f(x). Intuitively, the larger △−⋆is, the easier and faster x⋆can be recovered by HTP. It is also reasonable to expect that the step-size η should be well bounded away from zero to avoid undesirable early stopping. Inspired by these intuitive points, we present the following theorem which guarantees the exact recovery of HTP when the restricted strong condition number is well bounded. A proof of this theorem is provided in Appendix C (see the supplementary file). Theorem 1. Assume that f is M2k-smooth and m2k-strongly convex. Assume that ϑ⋆ := M2kx⋆ min ∥∇f(x⋆)∥∞> 1 and m2k M2k ≥ 7ϑ⋆+1 8ϑ⋆. If we set the step-size to be η = m2k M 2 2k , then the optimal k-sparse solution x⋆is unique and HTP will terminate with output x(t) = x⋆after at most t = ⌈ M 3 2k m2 2k(M2k −m2k) ln △(0) △−⋆ ⌉ steps of iteration, where △(0) = f(x(0)) − f(x⋆) and △−⋆ = min∥x∥0≤k,supp(x)̸=supp(x⋆),f(x)>f(x⋆) {f(x) −f(x⋆)}. Remark 2. Theorem 1 suggests that HTP is able to exactly recover x⋆provided that x⋆ min is strictly larger than ∥∇f(x⋆)∥∞/M2k and the restricted strong condition number is well bounded, i.e., M2k/m2k ≤ 8θ⋆ 7θ⋆+1 < 1.14. 4 As a consequence of Proposition 1 and Theorem 1, the following theorem establishes the performance of HTP for recovering the support of an arbitrary k-sparse vector. A proof of this result is provided in Appendix D (see the supplementary file). Theorem 2. Let ¯x be an arbitrary k-sparse vector and ¯l be defined in Proposition 1. Assume that the conditions in Theorem 1 hold. Then HTP will output x(t) satisfying supp(x(t)) = supp(¯x) in finite iteration, provided that either of the following two conditions is satisfied in addition: (1) ¯xmin ≥2 √ 2k m2k ∥∇f(¯x)∥∞; (2) ¯xmin ≥ ( ϑ⋆ M2k + 2ϑ⋆+ 2 ¯l ) ∥∇f(¯x)∥∞. In the following theorem, we further show that for proper ¯k < k, HTP method is able to recover the support of certain desired ¯k-sparse vector without assuming bounded restricted strong condition numbers. A proof of this theorem can be found in Appendix E (see the supplementary file). Theorem 3. Assume that f is M2k-smooth and m2k-strongly convex. Let ¯x be an arbitrary ¯k-sparse vector satisfying k ≥ ( 1 + 16M 2 2k m2 2k ) ¯k. Set the step-size to be η = 1 2M2k . (a) If ¯xmin > √ 2(f(¯x)−f(x⋆)) m2k , then HTP will terminate in finite iteration with output x(t) satisfying supp(¯x) ⊆supp(x(t)). (b) Furthermore, if ¯xmin > 1.62 √ 2(f(¯x)−f(x⋆)) m2k , then HTP will terminate in finite iteration with output x(t) satisfying supp(x(t), ¯k) = supp(¯x). Remark 3. The main message conveyed by the part (a) of Theorem 3 is: If the nonzero elements in ¯x are significantly larger than the rooted objective value gap √ f(¯x) −f(x⋆), then supp(¯x) ⊆ supp(x(t)) can be guaranteed by HTP with sufficiently large sparsity level k. Intuitively, the closer f(¯x) is to f(x⋆), the easier the conditions can be satisfied. Given that f(¯x) is close enough to the unconstrained global minimizer of f (i.e., the global minimizer of f is nearly sparse), we will have f(¯x) close enough to f(x⋆) since f(¯x) −f(x⋆) ≤f(¯x) −minx f(x). In the ideal case where the sparse vector ¯x is an unconstrained minimum of f, we will have f(¯x) = f(x⋆), and thus supp(¯x) ⊆supp(x(t)) holds under arbitrarily large restricted strong condition number. The part (b) of Theorem 3 shows that under almost identical conditions (up to a slightly increased numerical constant) to those in Part(a), HTP will output x(t) of which the top ¯k entries are exactly the supporting set of ¯x. The implication of this result is: in order to recover certain ¯k-sparse signals, one may run HTP with a properly relaxed sparsity level k until convergence and then preserve the top ¯k entries of the k-sparse output as the final ¯k-sparse solution. 2.3 Comparison against prior results It is interesting to compare our support recovery results with those implied by the parameter estimation error bounds obtained in prior work (Yuan et al., 2014; Jain et al., 2014). Actually, parameter estimation error bound naturally leads to the so called x-min condition which is key to the support recovery analysis. For example, it can be derived from the bounds in (Yuan et al., 2014) that under proper RIP condition ∥x(t) −¯x∥= O( √ k∥∇f(¯x)∥∞) when t is sufficiently large. This implies that as long as the ¯xmin is significantly larger than such an estimation error bound, exact recovery of ¯x can be guaranteed. In the meantime, the results in (Jain et al., 2014) show that for some ¯k-sparse minimizer of (1) with ¯k = O ( m2 2k M2 2k k ) , it holds for arbitrary restrictive strong condition number that ∥x(t) −¯x∥= O( √ k∥∇f(¯x)∥∞) when t is sufficiently large. Provided that ¯xmin is significantly larger than such an error bound, it will hold true that supp(¯x) ⊆supp(x(t)). Table 2 summarizes our support recovery results and those implied by the state-of-the-art results regarding target solution, dependency on RIP-type conditions and x-min condition. From this table, we can see that the x-min condition in Theorem 1 for recovering the global minimizer x⋆is weaker than those implied in (Yuan et al., 2014) in the sense that the former is not dependent on a factor √ k. Also our x-min condition in Theorem 3 is weaker than those implied in (Jain et al., 2014) because; 1) our bound O( √ f(¯x) −f(x⋆)) is not explicitly dependent on a multiplier √ k; and 2) it can be verified from the restricted strong-convexity of f that √ f(¯x) −f(x⋆) ≤ √ k∥∇f(¯x)∥∞/√2m2k. 5 Table 2: Comparison between our support recovery conditions and those implied by the existing estimation error bounds for HTP-style methods. Results Target Solution RIP Cond. X-min Condition (Yuan et al., 2014) Arbitrary k-sparse ¯x Required ¯xmin > O( √ k∥∇f(¯x)∥∞) (Jain et al., 2014) ∥¯x∥0 = O ( ( m2k M2k )2k ) Free ¯xmin > O( √ k∥∇f(¯x∥∞) Theorem 1 x⋆= arg min∥x∥0≤k f(x) Required x⋆ min > O(∥∇f(x⋆)∥∞) Theorem 2 Arbitrary k-sparse ¯x Required ¯xmin > O( √ k∥∇f(¯x)∥∞) or ¯xmin > O(∥∇f(¯x)∥∞) Theorem 3 ∥¯x∥0 = O ( ( m2k M2k )2k ) Free ¯xmin > O (√ f(¯x) −f(x⋆) ) It is also interesting to compare the support recovery result in Proposition 1 with those known for the following ℓ1-regularized estimator: min x∈Rp f(x) + λ∥x∥1, where λ is the regularization strength parameter. Recently, a unified sparsistency analysis for this type of convex-relaxed estimator was provided in (Li et al., 2015). We summarize in below a comparison between our Proposition 1 and the state-of-the-art results in (Li et al., 2015) with respect to several key conditions: • Local structured smoothness/convexity condition: Our analysis only requires first-order local structured smoothness/convexity conditions (i.e., RSC/RSS) while the analysis in (Li et al., 2015, Theorem 5.1, Condition 1) relies on certain second-order and third-order local structured smoothness conditions. • Irrepresentablility condition: Our analysis is free of the Irrepresentablility Condition which is usually required to guarantee the sparsistency of ℓ1-regularized estimators (Li et al., 2015, Theorem 5.1, Condition 3). • RIP-type condition: The analysis in (Li et al., 2015) is free of RIP-type condition, while ours is partially relying on such a condition (see Condition (2) of Proposition 1). • X-min condition: Comparing to the x-min condition required in (Li et al., 2015, Theorem 5.1, Condition 4), which is of order O( √ k∥∇f(¯x)∥∞), the x-min condition (1) in Proposition 1 is at the same order while the x-min condition (2) is weaker as it is not explicitly dependent on √ k. 3 Applications to Statistical Learning Models In this section, we apply our support recovery analysis to several sparse statistical learning models, deriving concrete sparsistency conditions in each case. Given a set of n independently drawn data samples {(u(i), v(i))}n i=1, we are interested in the following sparsity-constrained empirical loss minimization problem: min w f(w) := 1 n n ∑ i=1 ℓ(w⊤u(i), v(i)), subject to ∥w∥0 ≤k. where ℓ(·, ·) is a loss function measuring the discrepancy between prediction and response and w is a set of parameters to be estimated. In the subsequent subsections, we will investigate sparse linear regression and sparse logistic regression as two popular examples of the above formulation. 3.1 Sparsity-constrained linear regression Given a ¯k-sparse parameter vector ¯w, let us consider the samples are generated according to the linear model v(i) = ¯w⊤u(i) + ε(i) where ε(i) are n i.i.d. sub-Gaussian random variables with 6 parameter σ. The sparsity-constrained least squared linear regression model is then given by: min w f(w) = 1 2n n ∑ i=1 ∥v(i) −w⊤u(i)∥2, subject to ∥w∥0 ≤k. (3) Suppose u(i) are drawn from Gaussian distribution with covariance Σ. Then it holds with high probability that f(w) has RSC constant m2k ≥λmin(Σ) −O(k log p/n) and RSS constant M2k ≤ λmax(Σ) + O(k log p/n), and∥∇f( ¯w)∥∞= O ( σ √ log p/n ) . From Theorem 2 we know that for sufficiently large n, if the condition number λmax(Σ)/λmin(Σ) is well bounded and ¯wmin > O ( σ √¯k log p/n ) , then supp( ¯w) can be recovered by HTP after sufficient iteration. Since ε(i) are sub-Gaussian, we have f( ¯w) = 1 2n ∑n i=1 ∥ε(i)∥2 ≤σ2 holds with high probability. From Theorem 3 we can see that if ¯wmin > 1.62σ √ 2/m2k, then supp( ¯w) can be recovered, with high probability, by HTP with a sufficiently large sparsity level and a ¯k-sparse truncation postprocessing. 3.2 Sparsity-constrained logistic regression Logistic regression is one of the most popular models in statistical learning. In this model the relation between the random feature vector u ∈Rp and its associated random binary label v ∈{−1, +1} is determined by the conditional probability P(v|u; ¯w) = exp(2v ¯w⊤u)/(1 + exp(2v ¯w⊤u)). Given a set of n independently drawn data samples {(u(i), v(i))}n i=1, the sparse logistic regression model learns the parameters w so as to minimize the logistic log-likelihood over sparsity constraint: min w f(w) = 1 n n ∑ i=1 log(1 + exp(−2v(i)w⊤u(i))), subject to ∥w∥0 ≤k. (4) It has been shown in (Bahmani et al., 2013, Corollary 1) that under mild conditions, f(w) has RSC and RSS with overwhelming probability. Suppose u(i) are sub-Gaussian with parameter σ, then it is known from (Yuan et al., 2014) that ∥∇f( ¯w)∥∞= O ( σ √ log p/n ) . Then from Theorem 2 we know that if the restrictive strong condition number is well bounded and ¯wmin > O ( σ √¯k log p/n ) , then supp( ¯w) can be recovered by HTP after sufficient iteration. By using Theorem 3 and the fact √ f( ¯w) −f(w⋆) = O( √ k∥∇f(¯x)∥∞), we can show that if ¯wmin > O ( σ √¯k log p/n ) , then with high probability, supp( ¯w) can be recovered by HTP using a sufficiently large sparsity level k and proper postprocessing, without assuming bounded sparse condition number. 4 Numerical Results In this section, we conduct a group of Monte-Carlo simulation experiments on sparse linear regression and sparse logistic regression models to verify our theoretical predictions. Data generation: We consider a synthetic data model in which the sparse parameter ¯w is a p = 500 dimensional vector that has ¯k = 50 nonzero entries drawn independently from the standard Gaussian distribution. Each data sample u is a normally distributed dense vector. For the linear regression model, the responses are generated by v = u ¯w + ε where ε is a standard Gaussion noise. For the logistic regression model, the data labels, v ∈{−1, 1}, are then generated randomly according to the Bernoulli distribution P(v = 1|u; ¯w) = exp(2 ¯w⊤u)/(1 + exp(2 ¯w⊤u)). We allow the sample size n to be varying and for each n, we generate 100 random copies of data independently. Evaluation metric: In our experiment, we test HTP with varying sparsity level k ≥¯k. We use two metrics to measure the support recovery performance. We say a relaxed support recovery is successful if supp( ¯w) ⊆supp(w(t)) and an exact support recovery is successful if supp( ¯w) = supp(w(t), ¯k). We replicate the experiment over the 100 trials and record the percentage of successful relaxed support recovery and percentage of successful exact support recovery for each configuration of (n, k). Results: Figure 1 shows the percentage of relaxed/exact success curves as functions of sample size n under varying sparsity level k. From the curves in Figure 1(a) for the linear regression model we 7 200 400 600 800 0 20 40 60 80 100 n Perc. of relaxed success (%) k=50 k=70 k=90 k=110 k=130 k=150 200 400 600 800 0 20 40 60 80 100 n Perc. of exact success (%) k=50 k=70 k=90 k=110 k=130 k=150 (a) Linear Regression 200 400 600 800 0 20 40 60 80 100 n Perc. of relaxed success (%) k=50 k=70 k=90 k=110 k=130 k=150 200 400 600 800 0 20 40 60 80 100 n Perc. of exact success (%) k=50 k=70 k=90 k=110 k=130 k=150 (b) Logistic Regression Figure 1: Chance of relaxed success (left panel) and exact success (right panel) curves for linear regression and logistic regression models. 200 400 600 800 0 20 40 60 80 100 n Perc. of relaxed success (%) HTP: k=70 IHT: k=70 200 400 600 800 0 20 40 60 80 100 n Perc. of exact success (%) HTP: k=70 IHT: k=70 (a) Linear Regression 200 400 600 800 0 20 40 60 80 100 n Perc. of relaxed success (%) HTP: k=70 IHT: k=70 200 400 600 800 0 20 40 60 80 100 n Perc. of exact success (%) HTP: k=70 IHT: k=70 (b) Logistic Regression Figure 2: HTP versus IHT: Chance of relaxed and exact success of support recovery. can make two observations: 1) for each curve, the chance of success increases as n increases, which matches the results in Theorem 1 and Theorem 2; 2) HTP has the best performance when using sparsity level k = 70 > ¯k. Also it can be seen that the percentage of relaxed success is less sensitive to k than the percentage of exact success. These observations match the prediction in Theorem 3. Similar observations can be made from the curves in Figure 1(b) for the logistic regression model. We have also compared HTP with IHT (Blumensath & Davies, 2009) in support recovery performance. Note that IHT is a simplified variant of HTP without the debiasing operation (S3) in Algorithm 1. Our exact support recovery analysis for HTP builds heavily upon such a debiasing operation. Figure 2 shows the chance of success curves for these two methods with sparsity level k = 70. Figure 2(a) shows that in linear regression model, HTP is superior to IHT when the sample size n is relatively small and they become comparable as n increases. Figure 2(b) indicates that HTP slightly outperforms IHT when applied to the considered logistic regression task. From this group of results we can draw the conclusion that the debiasing step of HPT does have significant impact on improving the support recovery performance especially in small sample size settings. 5 Conclusions In this paper, we provided a deterministic support recovery analysis for HTP-style methods widely used in sparse learning. Theorem 1 establishes sufficient conditions for exactly recovering the global k-sparse minimizer x⋆of the NP-hard problem (1). Theorem 2 provides sufficient conditions to guarantee the support recovery of an arbitrary k-sparse target solution. Theorem 3 further shows that even when the restricted strong condition number can be arbitrarily large, HTP is still able to recover a target sparse solution by using certain relaxed sparsity level in the algorithm. We have applied our deterministic analysis to sparse linear regression and sparse logistic regression to establish the sparsistency of HTP in these statistical learning models. Based on our theoretical justification and numerical observation, we conclude that HTP-style methods are not only accurate in parameter estimation, but also powerful for exactly recovering sparse signals even in noisy settings. Acknowledgments Xiao-Tong Yuan and Ping Li were partially supported by NSF-Bigdata-1419210, NSF-III-1360971, ONR-N00014-13-1-0764, and AFOSR-FA9550-13-1-0137. Xiao-Tong Yuan is also partially supported by NSFC-61402232, NSFC-61522308, and NSFJP-BK20141003. Tong Zhang is supported by NSF-IIS-1407939 and NSF-IIS-1250985. 8 References Agarwal, A., Negahban, S., and Wainwright, M. Fast global convergence rates of gradient methods for highdimensional statistical recovery. In Proceedings of the 24th Annual Conference on Neural Information Processing Systems (NIPS’10), 2010. Bahmani, S., Raj, B., and Boufounos, P. Greedy sparsity-constrained optimization. Journal of Machine Learning Research, 14:807–841, 2013. Beck, A. and Teboulle, Marc. A fast iterative shrinkage-thresholding algorithm for linear inverse problems. SIAM Journal on Imaging Sciences, 2(1):183–202, 2009. Blumensath, T. Compressed sensing with nonlinear observations and related nonlinear optimization problems. IEEE Transactions on Information Theory, 59(6):3466–3474, 2013. Blumensath, T. and Davies, M. E. Iterative hard thresholding for compressed sensing. Applied and Computational Harmonic Analysis, 27(3):265–274, 2009. Donoho, D. L. Compressed sensing. IEEE Transactions on Information Theory, 52(4):1289–1306, 2006. Foucart, S. Hard thresholding pursuit: An algorithm for compressive sensing. SIAM Journal on Numerical Analysis, 49(6):2543–2563, 2011. Jain P. and Rao N. and Dhillon I. Structured sparse regression via greedy hard-thresholding. 2016 URL http://arxiv.org/pdf/1602.06042.pdf. Jain, P., Tewari, A., and Kar, P. On iterative hard thresholding methods for high-dimensional m-estimation. In Proceedings of the 28th Annual Conference on Neural Information Processing Systems (NIPS’14), 685–693, 2014. Jalali, A., Johnson, C. C., and Ravikumar, P. K. On learning discrete graphical models using greedy methods. In Proceedings of the 25th Annual Conference on Neural Information Processing Systems (NIPS’11), 2011. Li Xingguo, Zhao Tuo, Arora Raman, Liu Han and Haupt Jarvis. Stochastic variance reduced optimization for nonconvex sparse learning. In Proceedings of the 33rd International Conference on Machine Learning (ICML’16), 2016. Li Yen-Huan, Scarlett Jonathan, Ravikumar Pradeep and Cevher Volkan Sparsistency of ℓ1-regularized Mestimators. In Proceedings of the 18th International Conference on Artifficial Intelligence and Statistics (AISTATS’15), 2015. Natarajan, B. K. Sparse approximate solutions to linear systems. SIAM Journal on Computing, 24(2):227–234, 1995. Needell, D. and Tropp, J. A. Cosamp: iterative signal recovery from incomplete and inaccurate samples. IEEE Transactions on Information Theory, 26(3):301–321, 2009. Nesterov, Y. Introductory Lectures on Convex Optimization: A Basic Course. Kluwer, 2004. ISBN 9781402075537. Nutini, J., Schmidt, M.W., Laradji, I.H., Friedlander, M.P. and Koepke, H.A. Coordinate descent converges faster with the Gauss-Southwell rule than random selection. In Proceedings of the 32nd International Conference on Machine Learning (ICML’15), pp. 1632–1641, 2015. Pati, Y.C., Rezaiifar, R., and Krishnaprasad, P.S. Orthogonal matching pursuit: Recursive function approximation with applications to wavelet decomposition. In Proceedings of the 27th Annual Asilomar Conference on Signals, Systems, and Computers, pp. 40–44, 1993. Ravikumar, P., Wainwright, M. J., Raskutti, G., and Yu, B. High-dimensional covariance estimation by minimizing ℓ1-penalized log-determinant divergence. Electronic Journal of Statistics, 5:935–980, 2011. Shalev-Shwartz, Shai, Srebro, Nathan, and Zhang, Tong. Trading accuracy for sparsity in optimization problems with sparsity constraints. SIAM Journal on Optimization, 20:2807–2832, 2010. Jie, Shen and Ping, Li. A tight bound of hard thresholding. 2016. URL http://arxiv.org/pdf/1605.01656.pdf. Yuan, X.-T. and Yan, S. Forward basis selection for pursuing sparse representations over a dictionary. IEEE Transactions on Pattern Analysis And Machine Intelligence, 35(12):3025–3036, 2013. Yuan, X.-T., Li, P., and Zhang, T. Gradient hard thresholding pursuit for sparsity-constrained optimization. In Proceedings of the 31st International Conference on Machine Learning (ICML’14), 2014. 9 | 2016 | 519 |
6,460 | MetaGrad: Multiple Learning Rates in Online Learning Tim van Erven Leiden University tim@timvanerven.nl Wouter M. Koolen Centrum Wiskunde & Informatica wmkoolen@cwi.nl Abstract In online convex optimization it is well known that certain subclasses of objective functions are much easier than arbitrary convex functions. We are interested in designing adaptive methods that can automatically get fast rates in as many such subclasses as possible, without any manual tuning. Previous adaptive methods are able to interpolate between strongly convex and general convex functions. We present a new method, MetaGrad, that adapts to a much broader class of functions, including exp-concave and strongly convex functions, but also various types of stochastic and non-stochastic functions without any curvature. For instance, MetaGrad can achieve logarithmic regret on the unregularized hinge loss, even though it has no curvature, if the data come from a favourable probability distribution. MetaGrad’s main feature is that it simultaneously considers multiple learning rates. Unlike previous methods with provable regret guarantees, however, its learning rates are not monotonically decreasing over time and are not tuned based on a theoretically derived bound on the regret. Instead, they are weighted directly proportional to their empirical performance on the data using a tilted exponential weights master algorithm. 1 Introduction Methods for online convex optimization (OCO) [28, 12] make it possible to optimize parameters sequentially, by processing convex functions in a streaming fashion. This is important in time series prediction where the data are inherently online; but it may also be convenient to process offline data sets sequentially, for instance if the data do not all fit into memory at the same time or if parameters need to be updated quickly when extra data become available. The difficulty of an OCO task depends on the convex functions f1, f2, . . . , fT that need to be optimized. The argument of these functions is a d-dimensional parameter vector w from a convex domain U. Although this is abstracted away in the general framework, each function ft usually measures the loss of the parameters on an underlying example (xt, yt) in a machine learning task. For example, in classification ft might be the hinge loss ft(w) = max{0, 1 −ythw, xti} or the logistic loss ft(w) = ln ! 1 + e−ythw,xti" , with yt 2 {−1, +1}. Thus the difficulty depends both on the choice of loss and on the observed data. There are different methods for OCO, depending on assumptions that can be made about the functions. The simplest and most commonly used strategy is online gradient descent (GD), which does not require any assumptions beyond convexity. GD updates parameters wt+1 = wt −⌘trft(wt) by taking a step in the direction of the negative gradient, where the step size is determined by a parameter ⌘t called the learning rate. For learning rates ⌘t / 1/ p t, GD guarantees that the regret over T rounds, which measures the difference in cumulative loss between the online iterates wt and the best offline parameters u, is bounded by O( p T) [33]. Alternatively, if it is known beforehand that the functions are of an easier type, then better regret rates are sometimes possible. For instance, if the 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. functions are strongly convex, then logarithmic regret O(ln T) can be achieved by GD with much smaller learning rates ⌘t / 1/t [14], and, if they are exp-concave, then logarithmic regret O(d ln T) can be achieved by the Online Newton Step (ONS) algorithm [14]. This partitions OCO tasks into categories, leaving it to the user to choose the appropriate algorithm for their setting. Such a strict partition, apart from being a burden on the user, depends on an extensive cataloguing of all types of easier functions that might occur in practice. (See Section 3 for several ways in which the existing list of easy functions can be extended.) It also immediately raises the question of whether there are cases in between logarithmic and square-root regret (there are, see Theorem 3 in Section 3), and which algorithm to use then. And, third, it presents the problem that the appropriate algorithm might depend on (the distribution of) the data (again see Section 3), which makes it entirely impossible to select the right algorithm beforehand. These issues motivate the development of adaptive methods, which are no worse than O( p T) for general convex functions, but also automatically take advantage of easier functions whenever possible. An important step in this direction are the adaptive GD algorithm of Bartlett, Hazan, and Rakhlin [2] and its proximal improvement by Do, Le, and Foo [8], which are able to interpolate between strongly convex and general convex functions if they are provided with a data-dependent strong convexity parameter in each round, and significantly outperform the main non-adaptive method (i.e. Pegasos, [29]) in the experiments of Do et al. Here we consider a significantly richer class of functions, which includes exp-concave functions, strongly convex functions, general convex functions that do not change between rounds (even if they have no curvature), and stochastic functions whose gradients satisfy the so-called Bernstein condition, which is well-known to enable fast rates in offline statistical learning [1, 10, 19]. The latter group can again include functions without curvature, like the unregularized hinge loss. All these cases are covered simultaneously by a new adaptive method we call MetaGrad, for multiple eta gradient algorithm. MetaGrad maintains a covariance matrix of size d ⇥d where d is the parameter dimension. In the remainder of the paper we call this version full MetaGrad. A reference implementation is available from [17]. We also design and analyze a faster approximation that only maintains the d diagonal elements, called diagonal MetaGrad. Theorem 7 below implies the following: Theorem 1. Let gt = rft(wt) and V u T = PT t=1 ((u −wt)|gt)2. Then the regret of full MetaGrad is simultaneously bounded by O( p T ln ln T), and by T X t=1 f(wt) − T X t=1 ft(u) T X t=1 (wt −u)|gt O ⇣p V u T d ln T + d ln T ⌘ for any u 2 U. (1) Theorem 1 bounds the regret in terms of a measure of variance V u T that depends on the distance of the algorithm’s choices wt to the optimum u, and which, in favourable cases, may be significantly smaller than T. Intuitively, this happens, for instance, when there is stable optimum u that the algorithm’s choices wt converge to. Formal consequences are given in Section 3, which shows that this bound implies faster than O( p T) regret rates, often logarithmic in T, for all functions in the rich class mentioned above. In all cases the dependence on T in the rates matches what we would expect based on related work in the literature, and in most cases the dependence on the dimension d is also what we would expect. Only for strongly convex functions is there an extra factor d. It is an open question whether this is a fundamental obstacle for which an even more general adaptive method is needed, or whether it is an artefact of our analysis. The main difficulty in achieving the regret guarantee from Theorem 1 is tuning a learning rate parameter ⌘. In theory, ⌘should be roughly 1/pV u T , but this is not possible using any existing techniques, because the optimum u is unknown in advance, and tuning in terms of a uniform upper bound maxu V u T ruins all desired benefits. MetaGrad therefore runs multiple slave algorithms, each with a different learning rate, and combines them with a novel master algorithm that learns the empirically best learning rate for the OCO task in hand. The slaves are instances of exponential weights on the continuous parameters u with a suitable surrogate loss function, which in particular causes the exponential weights distributions to be multivariate Gaussians. For the full version of MetaGrad, the slaves are closely related to the ONS algorithm on the original losses, where each slave receives the master’s gradients instead of its own. It is shown that d 1 2 log2 Te + 1 slaves suffice, which is at most 16 as long as T 109, and therefore seems computationally acceptable. If not, then the number of slaves can be further reduced at the cost of slightly worse constants in the bound. 2 Protocol 1: Online Convex Optimization from First-order Information Input: Convex set U 1: for t = 1, 2, . . . do 2: Learner plays wt 2 U 3: Environment reveals convex loss function ft : U ! R 4: Learner incurs loss ft(wt) and observes (sub)gradient gt = rft(wt) 5: end for Related Work If we disregard computational efficiency, then the result of Theorem 1 can be achieved by finely discretizing the domain U and running the Squint algorithm for prediction with experts with each discretization point as an expert [16]. MetaGrad may therefore also be seen as a computationally efficient extension of Squint to the OCO setting. Our focus in this work is on adapting to sequences of functions ft that are easier than general convex functions. A different direction in which faster rates are possible is by adapting to the domain U. As we assume U to be fixed, we consider an upper bound D on the norm of the optimum u to be known. In contrast, Orabona and Pál [24, 25] design methods that can adapt to the norm of u. One may also look at the shape of U. As can be seen in the analysis of the slaves, MetaGrad is based a spherical Gaussian prior on Rd, which favours u with small `2-norm. This is appropriate for U that are similar to the Euclidean ball, but less so if U is more like a box (`1-ball). In this case, it would be better to run a copy of MetaGrad for each dimension separately, similarly to how the diagonal version of the AdaGrad algorithm [9, 21] may be interpreted as running a separate copy of GD with a separate learning rate for each dimension. AdaGrad further uses an adaptive tuning of the learning rates that is able to take advantage of sparse gradient vectors, as can happen on data with rarely observed features. We briefly compare to AdaGrad in some very simple simulations in Appendix A.1. Another notion of adaptivity is explored in a series of work [13, 6, 31] obtaining tighter bounds for linear functions ft that vary little between rounds (as measured either by their deviation from the mean function or by successive differences). Such bounds imply super fast rates for optimizing a fixed linear function, but reduce to slow O( p T) rates in the other cases of easy functions that we consider. Finally, the way MetaGrad’s slaves maintain a Gaussian distribution on parameters u is similar in spirit to AROW and related confidence weighted methods, as analyzed by Crammer, Kulesza, and Dredze [7] in the mistake bound model. Outline We start with the main definitions in the next section. Then Section 3 contains an extensive set of examples where Theorem 1 leads to fast rates, Section 4 presents the MetaGrad algorithm, and Section 5 provides the analysis leading to Theorem 7, which is a more detailed statement of Theorem 1 with an improved dependence on the dimension in some particular cases and with exact constants. The details of the proofs can be found in the appendix. 2 Setup Let U ✓Rd be a closed convex set, which we assume contains the origin 0 (if not, it can always be translated). We consider algorithms for Online Convex Optimization over U, which operate according to the protocol displayed in Protocol 1. Let wt 2 U be the iterate produced by the algorithm in round t, let ft : U ! R be the convex loss function produced by the environment and let gt = rft(wt) be the (sub)gradient, which is the feedback given to the algorithm.1 We abbreviate the regret with respect to u 2 U as Ru T = PT t=1 (ft(wt) −ft(u)), and define our measure of variance as V u T = PT t=1 ((u −wt)|gt)2 for the full version of MetaGrad and V u T = PT t=1 Pd i=1(ui−wt,i)2g2 t,i for the diagonal version. By convexity of ft, we always have ft(wt)−ft(u) (wt−u)|gt. Defining ˜Ru T = PT t=1(wt −u)|gt, this implies the first inequality in Theorem 1: Ru T ˜Ru T . A stronger requirement than convexity is that a function f is exp-concave, which (for exp-concavity parameter 1) means that e−f is concave. Finally, we impose the following standard boundedness assumptions, distinguishing between the full version of MetaGrad (left column) and the diagonal version (right 1If ft is not differentiable at wt, any choice of subgradient gt 2 @ft(wt) is allowed. 3 column): for all u, v 2 U, all dimensions i and all times t, full diag ku −vk Dfull |ui −vi| Ddiag (2) kgtk Gfull |gt,i| Gdiag. Here, and throughout the paper, the norm of a vector (e.g. kgtk) will always refer to the `2-norm. For the full version of MetaGrad, the Cauchy-Schwarz inequality further implies that (u −v)|gt ku −vk · kgtk DfullGfull. 3 Fast Rate Examples In this section, we motivate our interest in the adaptive bound (1) by giving a series of examples in which it provides fast rates. These fast rates are all derived from two general sufficient conditions: one based on the directional derivative of the functions ft and one for stochastic gradients that satisfy the Bernstein condition, which is the standard condition for fast rates in off-line statistical learning. Simple simulations that illustrate the conditions are provided in Appendix A.1 and proofs are also postponed to Appendix A. Directional Derivative Condition In order to control the regret with respect to some point u, the first condition requires a quadratic lower bound on the curvature of the functions ft in the direction of u: Theorem 2. Suppose, for a given u 2 U, there exist constants a, b > 0 such that the functions ft all satisfy ft(u) ≥ft(w) + a(u −w)|rft(w) + b ((u −w)|rft(w))2 for all w 2 U. (3) Then any method with regret bound (1) incurs logarithmic regret, Ru T = O(d ln T), with respect to u. The case a = 1 of this condition was introduced by Hazan, Agarwal, and Kale [14], who show that it is satisfied for all u 2 U by exp-concave and strongly convex functions. The rate O(d ln T) is also what we would expect by summing the asymptotic offline rate obtained by ridge regression on the squared loss [30, Section 5.2], which is exp-concave. Our extension to a > 1 is technically a minor step, but it makes the condition much more liberal, because it may then also be satisfied by functions that do not have any curvature. For example, suppose that ft = f is a fixed convex function that does not change with t. Then, when u⇤= arg minu f(u) is the offline minimizer, we have (u⇤−w)|rf(w) 2 [−GfullDfull, 0], so that f(u⇤) −f(w) ≥(u⇤−w)|rf(w) ≥2(u⇤−w)|rf(w) + 1 DfullGfull ((u⇤−w)|rf(w))2 , where the first inequality uses only convexity of f. Thus condition (3) is satisfied by any fixed convex function, even if it does not have any curvature at all, with a = 2 and b = 1/(GfullDfull). Bernstein Stochastic Gradients The possibility of getting fast rates even without any curvature is intriguing, because it goes beyond the usual strong convexity or exp-concavity conditions. In the online setting, the case of fixed functions ft = f seems rather restricted, however, and may in fact be handled by offline optimization methods. We therefore seek to loosen this requirement by replacing it by a stochastic condition on the distribution of the functions ft. The relation between variance bounds like Theorem 1 and fast rates in the stochastic setting is studied in depth by Koolen, Grünwald, and Van Erven [19], who obtain fast rate results both in expectation and in probability. Here we provide a direct proof only for the expected regret, which allows a simplified analysis. Suppose the functions ft are independent and identically distributed (i.i.d.), with common distribution P. Then we say that the gradients satisfy the (B, β)-Bernstein condition with respect to the stochastic optimum u⇤= arg minu2U Ef⇠P[f(u)] if (w −u⇤)| E f [rf(w)rf(w)|] (w −u⇤) B ! (w −u⇤)| E f [rf(w)] "β for all w 2 U. (4) This is an instance of the well-known Bernstein condition from offline statistical learning [1, 10], applied to the linearized excess loss (w −u⇤)|rf(w). As shown in Appendix H, imposing the condition for the linearized excess loss is a weaker requirement than imposing it for the original excess loss f(w) −f(u⇤). 4 Algorithm 1: MetaGrad Master Input: Grid of learning rates 1 5DG ≥⌘1 ≥⌘2 ≥. . . with prior weights ⇡⌘1 1 , ⇡⌘2 1 , . . . . As in (8) 1: for t = 1, 2, . . . do 2: Get prediction w⌘ t 2 U of slave (Algorithm 2) for each ⌘ 3: Play wt = P ⌘⇡⌘ t ⌘w⌘ t P ⌘⇡⌘ t ⌘ 2 U . Tilted Exponentially Weighted Average 4: Observe gradient gt = rft(wt) 5: Update ⇡⌘ t+1 = ⇡⌘ t e−↵`⌘ t (w⌘ t ) P ⌘⇡⌘ t e−↵`⌘ t (w⌘ t ) for all ⌘ . Exponential Weights with surrogate loss (6) 6: end for Theorem 3. If the gradients satisfy the (B, β)-Bernstein condition for B > 0 and β 2 (0, 1] with respect to u⇤= arg minu2U Ef⇠P[f(u)], then any method with regret bound (1) incurs expected regret E[Ru⇤ T ] = O ⇣ (Bd ln T)1/(2−β) T (1−β)/(2−β) + d ln T ⌘ . For β = 1, the rate becomes O(d ln T), just like for fixed functions, and for smaller β it is in between logarithmic and O( p dT). For instance, the hinge loss on the unit ball with i.i.d. data satisfies the Bernstein condition with β = 1, which implies an O(d ln T) rate. (See Appendix A.4.) It is common to add `2-regularization to the hinge loss to make it strongly convex, but this example shows that that is not necessary to get logarithmic regret. 4 MetaGrad Algorithm In this section we explain the two versions (full and diagonal) of the MetaGrad algorithm. We will make use of the following definitions: full diag M full t := gtg| t M diag t := diag(g2 t,1, . . . , g2 t,d) (5) ↵full := 1 ↵diag := 1/d. Depending on context, wt 2 U will refer to the full or diagonal MetaGrad prediction in round t. In the remainder we will drop the superscript from the letters above, which will always be clear from context. MetaGrad will be defined by means of the following surrogate loss `⌘ t (u), which depends on a parameter ⌘> 0 that trades off regret compared to u with the square of the scaled directional derivative towards u (full case) or its approximation (diag case): `⌘ t (u) := −⌘(wt −u)|gt + ⌘2(u −wt)|Mt(u −wt). (6) Our surrogate loss consists of a linear and a quadratic part. Using the language of Orabona, Crammer, and Cesa-Bianchi [26], the data-dependent quadratic part causes a “time-varying regularizer” and Duchi, Hazan, and Singer [9] would call it “temporal adaptation of the proximal function”. The sum of quadratic terms in our surrogate is what appears in the regret bound of Theorem 1. The MetaGrad algorithm is a two-level hierarchical construction, displayed as Algorithms 1 (master algorithm that learns the learning rate) and 2 (sub-module, a copy running for each learning rate ⌘ from a finite grid). Based on our analysis in the next section, we recommend using the grid in (8). Master The task of the Master Algorithm 1 is to learn the empirically best learning rate ⌘(parameter of the surrogate loss `⌘ t ), which is notoriously difficult to track online because the regret is nonmonotonic over rounds and may have multiple local minima as a function of ⌘(see [18] for a study in the expert setting). The standard technique is therefore to derive a monotonic upper bound on the regret and tune the learning rate optimally for the bound. In contrast, our approach, inspired by the approach for combinatorial games of Koolen and Van Erven [16, Section 4], is to have our master aggregate the predictions of a discrete grid of learning rates. Although we provide a formal analysis of the regret, the master algorithm does not depend on the outcome of this analysis, so any 5 Algorithm 2: MetaGrad Slave Input: Learning rate 0 < ⌘ 1 5DG, domain size D > 0 1: w⌘ 1 = 0 and ⌃⌘ 1 = D2I 2: for t = 1, 2, . . . do 3: Issue w⌘ t to master (Algorithm 1) 4: Observe gradient gt = rft(wt) . Gradient at master point wt 5: Update ⌃⌘ t+1 = ⇣ 1 D2 I + 2⌘2 Pt s=1 Ms ⌘−1 e w⌘ t+1 = w⌘ t −⌃⌘ t+1 ! ⌘gt + 2⌘2Mt(w⌘ t −wt) " w⌘ t+1 = ⇧ ⌃⌘ t+1 U ! e w⌘ t+1 " with projection ⇧⌃ U (w) = arg min u2U (u −w)|⌃−1(u −w) 6: end for Implementation: For Mt = M diag t only maintain diagonal of ⌃⌘ t . For Mt = M full t use rank-one update ⌃⌘ t+1 = ⌃⌘ t −2⌘2⌃⌘ t gtg| t ⌃⌘ t 1+2⌘2g| t ⌃⌘ t gt and simplify e w⌘ t+1 = w⌘ t −⌘⌃⌘ t+1gt (1 + 2⌘g| t (w⌘ t −wt)). slack in our bounds does not feed back into the algorithm. The master is in fact very similar to the well-known exponential weights method (line 5), run on the surrogate losses, except that in the predictions the weights of the slaves are tilted by their learning rates (line 3), having the effect of giving a larger weight to larger ⌘. The internal parameter ↵is set to ↵full from (5) for the full version of the algorithm, and to ↵diag for the diagonal version. Slaves The role of the Slave Algorithm 2 is to guarantee small surrogate regret for a fixed learning rate ⌘. We consider two versions, corresponding to whether we take rank-one or diagonal matrices Mt (see (5)) in the surrogate (6). The first version maintains a full d ⇥d covariance matrix and has the best regret bound. The second version uses only diagonal matrices (with d non-zero entries), thus trading off a weaker bound with a better run-time in high dimensions. Algorithm 2 presents the update equations in a computationally efficient form. Their intuitive motivation is given in the proof of Lemma 5, where we show that the standard exponential weights method with Gaussian prior and surrogate losses `⌘ t (u) yields Gaussian posterior with mean w⌘ t and covariance matrix ⌃⌘ t . The full version of MetaGrad is closely related to the Online Newton Step algorithm [14] running on the original losses ft: the differences are that each Slave receives the Master’s gradients gt = rft(wt) instead of its own rft(w⌘ t ), and that an additional term 2⌘2Mt(w⌘ t −wt) in line 5 adjusts for the difference between the Slave’s parameters w⌘ t and the Master’s parameters wt. MetaGrad is therefore a bona fide first-order algorithm that only accesses ft through gt. We also note that we have chosen the Mirror Descent version that iteratively updates and projects (see line 5). One might alternatively consider the Lazy Projection version (as in [34, 23, 32]) that forgets past projections when updating on new data. Since projections are typically computationally expensive, we have opted for the Mirror Descent version, which we expect to project less often, since a projected point seems less likely to update to a point outside of the domain than an unprojected point. Total run time As mentioned, the running time is dominated by the slaves. Ignoring the projection, a slave with full covariance matrix takes O(d2) time to update, while slaves with diagonal covariance matrix take O(d) time. If there are m slaves, this makes the overall computational effort respectively O(md2) and O(md), both in time per round and in memory. Our analysis below indicates that m = 1 + d 1 2 log2 Te slaves suffice, so m 16 as long as T 109. In addition, each slave may incur the cost of a projection, which depends on the shape of the domain U. To get a sense for the projection cost we consider a typical example. For the Euclidean ball a diagonal projection can be performed using a few iterations of Newton’s method to get the desired precision. Each such iteration costs O(d) time. This is generally considered affordable. For full projections the story is starkly different. We typically reduce to the diagonal case by a basis transformation, which takes O(d3) to compute using SVD. Hence here the projection dwarfs the other run time by an order of magnitude. We refer to [9] for examples of how to compute projections for various domains U. Finally, we remark that a potential speed-up is possible by running the slaves in parallel. 6 5 Analysis We conduct the analysis in three parts. We first discuss the master, then the slaves and finally their composition. The idea is the following. The master guarantees for all ⌘simultaneously that 0 = T X t=1 `⌘ t (wt) T X t=1 `⌘ t (w⌘ t ) + master regret compared to ⌘-slave. (7a) Then each ⌘-slave takes care of learning u, with regret O(d ln T): T X t=1 `⌘ t (w⌘ t ) T X t=1 `⌘ t (u) + ⌘-slave regret compared to u. (7b) These two statements combine to ⌘ T X t=1 (wt −u)|gt −⌘2V u T = − T X t=1 `⌘ t (u) sum of regrets above (7c) and the overall result follows by optimizing ⌘. 5.1 Master To show that we can aggregate the slave predictions, we consider the potential ΦT := P ⌘⇡⌘ 1e−↵PT t=1 `⌘ t (w⌘ t ). In Appendix B, we bound the last factor e−↵`⌘ T (w⌘ T ) above by its tangent at w⌘ T = wT and obtain an objective that can be shown to be equal to ΦT −1 regardless of the gradient gT if wT is chosen according to the Master algorithm. It follows that the potential is non-increasing: Lemma 4 (Master combines slaves). The Master Algorithm guarantees 1 = Φ0 ≥Φ1 ≥. . . ≥ΦT . As 0 −1 ↵ln ΦT PT t=1 `⌘ t (w⌘ t ) + −1 ↵ln ⇡⌘ 1, this implements step (7a) of our overall proof strategy, with master regret −1 ↵ln ⇡⌘ 1. We further remark that we may view our potential function ΦT as a game-theoretic supermartingale in the sense of Chernov, Kalnishkan, Zhdanov, and Vovk [5], and this lemma as establishing that the MetaGrad Master is the corresponding defensive forecasting strategy. 5.2 Slaves Next we implement step (7b), which requires proving an O(d ln T) regret bound in terms of the surrogate loss for each MetaGrad slave. In the full case, the surrogate loss is jointly exp-concave, and in light of the analysis of ONS by Hazan, Agarwal, and Kale [14] such a result is not surprising. For the diagonal case, the surrogate loss lacks joint exp-concavity, but we can use exp-concavity in each direction separately, and verify that the projections that tie the dimensions together do not cause any trouble. In Appendix C we analyze both cases simultaneously, and obtain the following bound on the regret: Lemma 5 (Surrogate regret bound). For 0 < ⌘ 1 5DG, let `⌘ t (u) be the surrogate losses as defined in (6) (either the full or the diagonal version). Then the regret of Slave Algorithm 2 is bounded by T X t=1 `⌘ t (w⌘ t ) T X t=1 `⌘ t (u) + 1 2D2 kuk2 + 1 2 ln det I + 2⌘2D2 T X t=1 Mt ! for all u 2 U. 5.3 Composition To complete the analysis of MetaGrad, we first put the regret bounds for the master and slaves together as in (7c). We then discuss how to choose the grid of ⌘s, and optimize ⌘over this grid to get our main result. Proofs are postponed to Appendix D. Theorem 6 (Grid point regret). The full and diagonal versions of MetaGrad, with corresponding definitions from (2) and (5), guarantee that, for any grid point ⌘with prior weight ⇡⌘ 1, ˜Ru T ⌘V u T + 1 2D2 kuk2 −1 ↵ln ⇡⌘ 1 + 1 2 ln det ⇣ I + 2⌘2D2 PT t=1 Mt ⌘ ⌘ for all u 2 U. 7 Grid We now specify the grid points and corresponding prior. Theorem 6 above implies that any two ⌘that are within a constant factor of each other will guarantee the same bound up to essentially the same constant factor. We therefore choose an exponentially spaced grid with a heavy tailed prior (see Appendix E): ⌘i := 2−i 5DG and ⇡⌘i 1 := C (i + 1)(i + 2) for i = 0, 1, 2, . . . , d 1 2 log2 Te, (8) with normalization C = 1 + 1 + (1 + d 1 2 log2 Te). At the cost of a worse constant factor in the bounds, the number of slaves can be reduced by using a larger spacing factor, or by omitting some of the smallest learning rates. The net effect of (8) is that, for any ⌘2 [ 1 5DG p T , 2 5DG] there is an ⌘i 2 [ 1 2⌘, ⌘], for which −ln ⇡⌘i 1 2 ln(i + 2) = O(ln ln(1/⌘i)) = O(ln ln(1/⌘)). As these costs are independent of T, our regret guarantees still hold if the grid (8) is instantiated with T replaced by any upper bound. The final step is to apply Theorem 6 to this grid, and to properly select the learning rate ⌘i in the bound. This leads to our main result: Theorem 7 (MetaGrad Regret Bound). Let ST = PT t=1 Mt and V u T,i = PT t=1(ui −wt,i)2g2 t,i. Then the regret of MetaGrad, with corresponding definitions from (2) and (5) and with grid and prior as in (8), is bounded by ˜Ru T s 8V u T ✓1 D2 kuk2 + ⌅T + 1 ↵CT ◆ + 5DG ✓1 D2 kuk2 + ⌅T + 1 ↵CT ◆ for all u 2 U, where ⌅T min ( ln det ✓ I + D2 rk(ST ) V u T ST ◆ , rk(ST ) ln D2 V u T T X t=1 kgtk2 !) = O(d ln(D2G2T)) for the full version of the algorithm, ⌅T = d X i=1 ln D2 PT t=1 g2 t,i V u T,i ! = O(d ln(D2G2T)) for the diagonal version, and CT = 4 ln ! 3 + 1 2 log2 T " = O(ln ln T) in both cases. Moreover, for both versions of the algorithm, the regret is simultaneously bounded by ˜Ru T v u u t8D2 T X t=1 kgtk2 ! ✓1 D2 kuk2 + 1 ↵CT ◆ +5DG ✓1 D2 kuk2 + 1 ↵CT ◆ for all u 2 U. These two bounds together show that the full version of MetaGrad achieves the new adaptive guarantee of Theorem 1. The diagonal version behaves like running the full version separately per dimension, but with a single shared learning rate. 6 Discussion and Future Work One may consider extending MetaGrad in various directions. In particular it would be interesting to speed up the method in high dimensions, for instance by sketching [20]. A broader question is to identify and be adaptive to more types of easy functions that are of practical interest. One may suspect there to be a price (in regret overhead and in computation) for broader adaptivity, but based on our results for MetaGrad it does not seem like we are already approaching the point where this price is no longer worth paying. Acknowledgments We would like to thank Haipeng Luo and the anonymous reviewers (in particular Reviewer 6) for valuable comments. Koolen acknowledges support by the Netherlands Organization for Scientific Research (NWO, Veni grant 639.021.439). 8 References [1] P. L. Bartlett and S. Mendelson. Empirical minimization. Probability Theory and Related Fields, 135(3): 311–334, 2006. [2] P. L. Bartlett, E. Hazan, and A. Rakhlin. Adaptive online gradient descent. In NIPS 20, pages 65–72, 2007. [3] N. Cesa-Bianchi, Y. Mansour, and G. Stoltz. Improved second-order bounds for prediction with expert advice. Machine Learning, 66(2/3):321–352, 2007. [4] A. V. Chernov and V. Vovk. Prediction with advice of unknown number of experts. In Proc. of the 26th Conf. on Uncertainty in Artificial Intelligence, pages 117–125, 2010. [5] A. V. Chernov, Y. Kalnishkan, F. Zhdanov, and V. Vovk. Supermartingales in prediction with expert advice. Theoretical Computer Science, 411(29-30):2647–2669, 2010. [6] C.-K. Chiang, T. Yang, C.-J. Le, M. Mahdavi, C.-J. Lu, R. Jin, and S. Zhu. Online optimization with gradual variations. In Proc. of the 25th Annual Conf. on Learning Theory (COLT), pages 6.1–6.20, 2012. [7] K. Crammer, A. Kulesza, and M. Dredze. Adaptive regularization of weight vectors. In NIPS 22, pages 414–422, 2009. [8] C. B. Do, Q. V. Le, and C.-S. Foo. Proximal regularization for online and batch learning. In Proc. of the 26th Annual International Conf. on Machine Learning (ICML), pages 257–264, 2009. [9] J. Duchi, E. Hazan, and Y. Singer. Adaptive subgradient methods for online learning and stochastic optimization. Journal of Machine Learning Research, 12:2121–2159, 2011. [10] T. van Erven, P. D. Grünwald, N. A. Mehta, M. D. Reid, and R. C. Williamson. Fast rates in statistical and online learning. Journal of Machine Learning Research, 16:1793–1861, 2015. [11] P. Gaillard, G. Stoltz, and T. van Erven. A second-order bound with excess losses. In Proc. of the 27th Annual Conf. on Learning Theory (COLT), pages 176–196, 2014. [12] E. Hazan. Introduction to online optimization. Draft, April 10, 2016, ocobook.cs.princeton.edu, 2016. [13] E. Hazan and S. Kale. Extracting certainty from uncertainty: Regret bounded by variation in costs. Machine learning, 80(2-3):165–188, 2010. [14] E. Hazan, A. Agarwal, and S. Kale. Logarithmic regret algorithms for online convex optimization. Machine Learning, 69(2-3):169–192, 2007. [15] S. Ihara. Information Theory for Continuous Systems. World Scientific, 1993. [16] W. M. Koolen and T. van Erven. Second-order quantile methods for experts and combinatorial games. In Proc. of the 28th Annual Conf. on Learning Theory (COLT), pages 1155–1175, 2015. [17] W. M. Koolen and T. van Erven. MetaGrad open source code. bitbucket.org/wmkoolen/metagrad, 2016. [18] W. M. Koolen, T. van Erven, and P. D. Grünwald. Learning the learning rate for prediction with expert advice. In NIPS 27, pages 2294–2302, 2014. [19] W. M. Koolen, P. D. Grünwald, and T. van Erven. Combining adversarial guarantees and stochastic fast rates in online learning. In NIPS 29, 2016. [20] H. Luo, A. Agarwal, N. Cesa-Bianchi, and J. Langford. Efficient second order online learning by sketching. In NIPS 29, 2016. [21] H. B. McMahan and M. J. Streeter. Adaptive bound optimization for online convex optimization. In Proc. of the 23rd Annual Conf. on Learning Theory (COLT), pages 244–256, 2010. [22] T. Mikolov, K. Chen, G. S. Corrado, and J. Dean. Efficient estimation of word representations in vector space. International Conf. on Learning Representations, 2013. Arxiv.org/abs/1301.3781. [23] Y. Nesterov. Primal-dual subgradient methods for convex problems. Mathematical programming, 120(1): 221–259, 2009. [24] F. Orabona. Simultaneous model selection and optimization through parameter-free stochastic learning. In NIPS 27, pages 1116–1124, 2014. [25] F. Orabona and D. Pál. Coin betting and parameter-free online learning. In NIPS 29, 2016. [26] F. Orabona, K. Crammer, and N. Cesa-Bianchi. A generalized online mirror descent with applications to classification and regression. Machine Learning, 99(3):411–435, 2015. [27] J. Schmidhuber. Deep learning in neural networks: An overview. Neural Networks, 61:85–117, 2015. [28] S. Shalev-Shwartz. Online learning and online convex optimization. Foundations and Trends in Machine Learning, 4(2):107–194, 2012. [29] S. Shalev-Shwartz, Y. Singer, N. Srebro, and A. Cotter. Pegasos: Primal estimated sub-gradient solver for SVM. Mathematical Programming, 127(1):3–30, 2011. [30] N. Srebro, K. Sridharan, and A. Tewari. Smoothness, low noise and fast rates. In NIPS 23, pages 2199–2207, 2010. [31] J. Steinhardt and P. Liang. Adaptivity and optimism: An improved exponentiated gradient algorithm. In Proc. of the 31th Annual International Conf. on Machine Learning (ICML), pages 1593–1601, 2014. [32] L. Xiao. Dual averaging methods for regularized stochastic learning and online optimization. Journal of Machine Learning Research, 11:2543–2596, 2010. [33] M. Zinkevich. Online convex programming and generalized infinitesimal gradient ascent. In Proc. of the 20th Annual International Conf. on Machine Learning (ICML), pages 928–936, 2003. [34] M. Zinkevich. Theoretical Guarantees for Algorithms in Multi-Agent Settings. PhD thesis, Carnegie Mellon University, 2004. 9 | 2016 | 52 |
6,461 | Parameter Learning for Log-supermodular Distributions Tatiana Shpakova INRIA - École Normale Supérieure Paris tatiana.shpakova@inria.fr Francis Bach INRIA - École Normale Supérieure Paris francis.bach@inria.fr Abstract We consider log-supermodular models on binary variables, which are probabilistic models with negative log-densities which are submodular. These models provide probabilistic interpretations of common combinatorial optimization tasks such as image segmentation. In this paper, we focus primarily on parameter estimation in the models from known upper-bounds on the intractable log-partition function. We show that the bound based on separable optimization on the base polytope of the submodular function is always inferior to a bound based on “perturb-and-MAP” ideas. Then, to learn parameters, given that our approximation of the log-partition function is an expectation (over our own randomization), we use a stochastic subgradient technique to maximize a lower-bound on the log-likelihood. This can also be extended to conditional maximum likelihood. We illustrate our new results in a set of experiments in binary image denoising, where we highlight the flexibility of a probabilistic model to learn with missing data. 1 Introduction Submodular functions provide efficient and flexible tools for learning on discrete data. Several common combinatorial optimization tasks, such as clustering, image segmentation, or document summarization, can be achieved by the minimization or the maximization of a submodular function [1, 8, 14]. The key benefit of submodularity is the ability to model notions of diminishing returns, and the availability of exact minimization algorithms and approximate maximization algorithms with precise approximation guarantees [12]. In practice, it is not always straightforward to define an appropriate submodular function for a problem at hand. Given fully-labeled data, e.g., images and their foreground/background segmentations in image segmentation, structured-output prediction methods such as the structured-SVM may be used [18]. However, it is common (a) to have missing data, and (b) to embed submodular function minimization within a larger model. These are two situations well tackled by probabilistic modelling. Log-supermodular models, with negative log-densities equal to a submodular function, are a first important step toward probabilistic modelling on discrete data with submodular functions [5]. However, it is well known that the log-partition function is intractable in such models. Several bounds have been proposed, that are accompanied with variational approximate inference [6]. These bounds are based on the submodularity of the negative log-densities. However, parameter learning (typically by maximum likelihood), which is a key feature of probabilistic modeling, has not been tackled yet. We make the following contributions: – In Section 3, we review existing variational bounds for the log-partition function and show that the bound of [9], based on “perturb-and-MAP” ideas, formally dominates the bounds proposed by [5, 6]. – In Section 4.1, we show that for parameter learning via maximum likelihood the existing bound of [5, 6] typically leads to a degenerate solution while the one based on “perturb-and-MAP” ideas and logistic samples [9] does not. 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. – In Section 4.2, given that the bound based on “perturb-and-MAP” ideas is an expectation (over our own randomization), we propose to use a stochastic subgradient technique to maximize the lower-bound on the log-likelihood, which can also be extended to conditional maximum likelihood. – In Section 5, we illustrate our new results on a set of experiments in binary image denoising, where we highlight the flexibility of a probabilistic model for learning with missing data. 2 Submodular functions and log-supermodular models In this section, we review the relevant theory of submodular functions and recall typical examples of log-supermodular distributions. 2.1 Submodular functions We consider submodular functions on the vertices of the hypercube {0, 1}D. This hypercube representation is equivalent to the power set of {1, . . . , D}. Indeed, we can go from a vertex of the hypercube to a set by looking at the indices of the components equal to one and from set to vertex by taking the indicator vector of the set. For any two vertices of the hypercube, x, y ∈{0, 1}D, a function f : {0, 1}D →R is submodular if f(x) + f(y) ⩾f(min{x, y}) + f(max{x, y}), where the min and max operations are taken component-wise and correspond to the intersection and union of the associated sets. Equivalently, the function x 7→f(x + ei) −f(x), where ei ∈RD is the i-th canonical basis vector, is non-increasing. Hence, the notion of diminishing returns is often associated with submodular functions. Most widely used submodular functions are cuts, concave functions of subset cardinality, mutual information, set covers, and certain functions of eigenvalues of submatrices [1, 7]. Supermodular functions are simply negatives of submodular functions. In this paper, we are going to use a few properties of such submodular functions (see [1, 7] and references therein). Any submodular function f can be extended from {0, 1}D to a convex function on RD, which is called the Lovász extension. This extension has the same value on {0, 1}D, hence we use the same notation f. Moreover, this function is convex and piecewise linear, which implies the existence of a polytope B(f) ⊂RD, called the base polytope, such that for all x ∈RD, f(x) = maxs∈B(f) x⊤s, that is, f is the support function of B(f). The Lovász extension f and the base polytope B(f) have explicit expressions that are, however, not relevant to this paper. We will only use the fact that f can be efficiently minimized on {0, 1}D, by a variety of generic algorithms, or by more efficient dedicated ones for subclasses such as graph-cuts. 2.2 Log-supermodular distributions Log-supermodular models are introduced in [5] to model probability distributions on a hypercube, x ∈{0, 1}D, and are defined as p(x) = 1 Z(f) exp(−f(x)), where f : {0, 1}D →R is a submodular function such that f(0) = 0 and the partition function is Z(f) = P x∈{0,1}D exp(−f(x)). It is more convenient to deal with the convex log-partition function A(f) = log Z(f) = log P x∈{0,1}D exp(−f(x)). In general, the calculation of the partition function Z(f) or the log-partition function A(f) is intractable, as it includes simple binary Markov random fields—the exact calculation is known to be #P-hard [10]. In Section 3, we review upperbounds for the log-partition function. 2.3 Examples Essentially, all submodular functions used in the minimization context can be used as negative log-densities [5, 6]. In computer vision, the most common examples are graph-cuts, which are essentially binary Markov random fields with attractive potentials, but higher-order potentials have been considered as well [11]. In our experiments, we use graph-cuts, where submodular function minimization may be performed with max-flow techniques and is thus efficient [4]. Note that there are extensions of submodular functions to continuous domains that could be considered as well [2]. 2 3 Upper-bounds on the log-partition function In this section, we review the main existing upper-bounds on the log-partition function for logsupermodular densities. These upper-bounds use several properties of submodular functions, in particular, the Lovász extension and the base polytope. Note that lower bounds based on submodular maximization aspects and superdifferentials [5] can be used to highlight the tightness of various bounds, which we present in Figure 1. 3.1 Base polytope relaxation with L-Field [5] This method exploits the fact that any submodular function f(x) can be lower bounded by a modular function s(x), i.e., a linear function of x ∈{0, 1}D in the hypercube representation. The submodular function and its lower bound are related by f(x) = maxs∈B(f) s⊤x, leading to: A(f) = log P x∈{0,1}D exp (−f(x)) = log P x∈{0,1}D mins∈B(f) exp (−s⊤x), which, by swapping the sum and min, is less than mins∈B(f) log P x∈{0,1}D exp (−s⊤x) = mins∈B(f) PD d=1 log (1 + e−sd) def = AL-field(f). (1) Since the polytope B(f) is tractable (through its membership oracle or by maximizing linear functions efficiently), the bound AL-field(f) is tractable, i.e., computable in polynomial time. Moreover, it has a nice interpretation through convex duality as the logistic function log(1+e−sd) may be represented as maxµd∈[0,1] −µdsd −µd log µd −(1 −µd) log(1 −µd), leading to: AL-field(f) = min s∈B(f) max µ∈[0,1]D −µ⊤s + H(µ) = max µ∈[0,1]D H(µ) −f(µ), where H(µ) = −PD d=1 µd log µd + (1 −µd) log(1 −µd) . This shows in particular the convexity of f 7→AL-field(f). Finally, [6] shows the remarkable result that the minimizer s ∈B(f) may be obtained by minimizing a simpler function on B(f), namely the squared Euclidean norm, thus leading to algorithms such as the minimum-norm-point algorithm [7]. 3.2 “Pertub-and-MAP” with logistic distributions Estimating the log-partition function can be done through optimization using “pertub-and-MAP” ideas. The main idea is to perturb the log-density, find the maximum a-posteriori configuration (i.e., perform optimization), and then average over several random perturbations [9, 17, 19]. The Gumbel distribution on R, whose cumulative distribution function is F(z) = exp(−exp(−(z + c))), where c is the Euler constant, is particularly useful. Indeed, if {g(y)}y∈{0,1}D is a collection of independent random variables g(y) indexed by y ∈{0, 1}D, each following the Gumbel distribution, then the random variable maxy∈{0,1}D g(y) −f(y) is such that we have log Z(f) = Eg maxy∈{0,1}D {g(y) −f(y)} [9, Lemma 1]. The main problem is that we need 2D such variables, and a key contribution of [9] is to show that if we consider a factored collection {gd(yd)}yd∈{0,1},d=1,...,D of i.i.d. Gumbel variables, then we get an upper-bound on the log partition-function, that is, log Z(f) ≤Egmaxy∈{0,1}D {PD d=1 gd(yd) −f(y)}. Writing gd(yd) = [gd(1) −gd(0)]yd + gd(0) and using the fact that (a) gd(0) has zero expectation and (b) the difference between two independent Gumbel distributions has a logistic distribution (with cumulative distribution function z 7→(1 + e−z)−1) [15], we get the following upper-bound: ALogistic(f) = Ez1,...,zD∼logistic max y∈{0,1}D {z⊤y −f(y)} , (2) where the random vector z ∈RD consists of independent elements taken from the logistic distribution. This is always an upper-bound on A(f) and it uses only the fact that submodular functions are efficient to optimize. It is convex in f as an expectation of a maximum of affine functions of f. 3.3 Comparison of bounds In this section, we show that AL-field(f) is always dominated by ALogistic(f). This is complemented by another result within the maximum likelihood framework in Section 4. 3 Proposition 1. For any submodular function f : {0, 1}D →R, we have: A(f) ⩽ALogistic(f) ⩽AL-field(f). (3) Proof. The first inequality was shown by [9]. For the second inequality, we have: ALogistic(f) = Ez max y∈{0,1}D z⊤y −f(y) = Ez max y∈{0,1}D z⊤y −max s∈B(f) s⊤y from properties of the base polytope B(f), = Ez maxy∈{0,1}D mins∈B(f) z⊤y −s⊤y , = Ez mins∈B(f) max y∈{0,1}D z⊤y −s⊤y by convex duality, ⩽ mins∈B(f) Ez maxy∈{0,1}D (z −s)⊤y by swapping expectation and minimization, = mins∈B(f) Ez PD d=1(zd −sd)+ by explicit maximization, = mins∈B(f) PD d=1 Ezd(zd −sd)+ by using linearity of expectation, = mins∈B(f) PD d=1 R +∞ −∞(zd −sd)+P(zd)dzd by definition of expectation, = min s∈B(f) PD d=1 R +∞ sd (zd −sd) e−zd (1+e−zd)2 dzd by substituting the density function, = mins∈B(f) PD d=1 log(1 + e−sd), which leads to the desired result. In the inequality above, since the logistic distribution has full support, there cannot be equality. However, if the base polytope is such that, with high probability ∀d, |sd| ≥|zd|, then the two bounds are close. Since the logistic distribution is concentrated around zero, we have equality when |sd| is large for all d and s ∈B(f). Running-time complexity of AL-field and Alogistic. The logistic bound Alogistic can be computed if there is efficient MAP-solver for submodular functions (plus a modular term). In this case, the divide-and-conquer algorithm can be applied for L-Field [5]. Thus, the complexity is dedicated to the minimization of O(|V |) problems. Meanwhile, for the method based on logistic samples, it is necessary to solve M optimization problems. In our empirical bound comparison (next paragraph), the running time was the same for both methods. Note however that for parameter learning, we need a single SFM problem per gradient iteration (and not M). Empirical comparison of AL-field and Alogistic. We compare the upper-bounds on the log-partition function AL-field and Alogistic, with the setup used by [5]. We thus consider data from a Gaussian mixture model with 2 clusters in R2. The centers are sampled from N([3, 3], I) and N([−3, −3], I), respectively. Then we sampled n = 50 points for each cluster. Further, these 2n points are used as nodes in a complete weighted graph, where the weight between points x and y is equal to e−c||x−y||. We consider the graph cut function associated to this weighted graph, which defines a logsupermodular distribution. We then consider conditional distributions, one for each k = 1, . . . , n, on the events that at least k points from the first cluster lie on the one side of the cut and at least k points from the second cluster lie on the other side of the cut. For each conditional distribution, we evaluate and compare the two upper bounds. We also add the tree-reweighted belief propagation upper bound [23] and the superdifferential-based lower bound [5]. In Figure 1, we show various bounds on A(f) as functions of the number on conditioned pairs. The logistic upper bound is obtained using 100 logistic samples: the logistic upper-bound Alogistic is close to the superdifferential lower bound from [5] and is indeed significantly lower than the bound AL-field. However, the tree-reweighted belief propagation bound behaves a bit better in the second case, but its calculation takes more time, and it cannot be applied for general submodular functions. 3.4 From bounds to approximate inference Since linear functions are submodular functions, given any convex upper-bound on the log-partition function, we may derive an approximate marginal probability for each xd ∈{0, 1}. Indeed, following [9], we consider an exponential family model p(x|t) = exp(−f(x) + t⊤x −A(f −t)), where 4 0 20 40 60 0 50 100 150 200 250 Number of Conditioned Pairs Log−Partition Function Superdifferential lower bound L−field upper bound Tree−reweighted BP Logistic upper bound (a) Mean bounds with confidence intervals, c = 1. 0 10 20 30 40 50 0 20 40 60 80 100 Number of Conditioned Pairs Log−Partition Function Superdifferential lower bound L−field upper bound Tree−reweighted BP Logistic upper bound (b) Mean bounds with confidence intervals, c = 3. Figure 1: Comparison of log-partition function bounds for different values of c. See text for details. f −t is the function x 7→f(x) −t⊤x. When f is assumed to be fixed, this can be seen as an exponential family with the base measure exp(−f(x)), sufficient statistics x, and A(f −t) is the log-partition function. It is known that the expectation of the sufficient statistics under the exponential family model Ep(x|t)x is the gradient of the log-partition function [23]. Hence, any approximation of this log-partition gives an approximation of this expectation, which in our situation is the vector of marginal probabilities that an element is equal to 1. For the L-field bound, at t = 0, we have ∂tdAL-field(f −t) = σ(s∗ d), where s∗is the minimizer of PD d=1 log(1 + e−sd), thus recovering the interpretation of [6] from another point of view. For the logistic bound, this is the inference mechanism from [9], with ∂tdAlogistic(f −t) = Ezy∗(z), where y∗(z) is the maximizer of maxy∈{0,1}D z⊤y −f(y). In practice, in order to perform approximate inference, we only sample M logistic variables. We could do the same for parameter learning, but a much more efficient alternative, based on mixing sampling and convex optimization, is presented in the next section. 4 Parameter learning through maximum likelihood An advantage of log-supermodular probabilistic models is the opportunity to learn the model parameters from data using the maximum-likelihood principle. In this section, we consider that we are given N observations x1, . . . , xN ∈{0, 1}D, e.g., binary images such as shown in Figure 2. We consider a submodular function f(x) represented as f(x) = PK k=1 αkfk(x) −t⊤x. The modular term t⊤x is explicitly taken into account with t ∈RD, and K base submodular functions are assumed to be given with α ∈RK + so that the function f remains submodular. Assuming the data x1, . . . , xN are independent and identically (i.i.d.) distributed, then maximum likelihood is equivalent to minimizing: min α∈RK + , t∈RD −1 N N X n=1 log p(xn|α, t) = min α∈RK + , t∈RD 1 N N X n=1 K X k=1 αkfk(xn) −t⊤xn + A(f) , which takes the particularly simple form minα∈RK + , t∈RD PK k=1 αk 1 N PN n=1 fk(xn) −t⊤ 1 N PN n=1 xn + A(α, t), (4) where we use the notation A(α, t) = A(f). We now consider replacing the intractable log-partition function by its approximations defined in Section 3. 4.1 Learning with the L-field approximation In this section, we show that if we replace A(f) by AL-field(f), we obtain a degenerate solution. Indeed, we have AL-field(α, t) = min s∈B(f) D X d=1 log (1 + e−sd) = min s∈B(PK k=1 αKfK) D X d=1 log (1 + e−sd+td). 5 This implies that Eq. (4) becomes min α∈RK + , t∈RD min s∈B(PK k=1 αKfK) K X k=1 αk 1 N N X n=1 fk(xn) −t⊤ 1 N N X n=1 xn + D X d=1 log (1 + e−sd+td). The minimum with respect to td may be performed in closed form with td −sd = log ⟨x⟩d 1−⟨x⟩d , where ⟨x⟩= 1 N PN n=1 xn. Putting this back into the equation above, we get the equivalent problem: min α∈RK + min s∈B(PK k=1 αKfK) K X k=1 αk 1 N N X n=1 fk(xn) −s⊤ 1 N N X n=1 xn + const , which is equivalent to, using the representation of f as the support function of B(f): minα∈RK + PK k=1 αk 1 N PN n=1 fk(xn) −fk 1 N PN n=1 xn . Since fk is convex, by Jensen’s inequality, the linear term in αk is non-negative; thus maximum likelihood through L-field will lead to a degenerate solution where all α’s are equal to zero. 4.2 Learning with the logistic approximation with stochastic gradients In this section we consider the problem (4) and replace A(f) by ALogistic(f): min α∈RK + , t∈RD K X k=1 αk⟨fk(x)⟩emp.−t⊤⟨x⟩emp.+Ez∼logistic max y∈{0,1}D z⊤y + t⊤y − K X k=1 αkf(y) , (5) where ⟨M(x)⟩emp. denotes the empirical average of M(x) (over the data). Denoting by y∗(z, t, α) ∈{0, 1}D the maximizers of z⊤y + t⊤y −PK k=1 αkf(y), the objective function may be written: K X k=1 αk ⟨fk(x)⟩emp.−⟨fk(y∗(z, t, α))⟩logistic −t⊤ ⟨x⟩emp.−⟨y∗(z, t, α)⟩logistic]+⟨z⊤y∗(z, t, α)⟩logistic. This implies that at optimum, for αk > 0, then ⟨fk(x)⟩emp. = ⟨fk(y∗(z, t, α))⟩logistic, while, ⟨x⟩emp. = ⟨y∗(z, t, α)⟩logistic, the expected values of the sufficient statistics match between the data and the optimizers used for the logistic approximation [9]. In order to minimize the expectation in Eq. (5), we propose to use the projected stochastic gradient method, not on the data as usually done, but on our own internal randomization. The algorithm then becomes, once we add a weighted ℓ2-regularization Ω(t, α): • Input: functions fk, k = 1, . . . , K, and expected sufficient statistics ⟨fk(x)⟩emp. ∈R and ⟨x⟩emp. ∈[0, 1]D, regularizer Ω(t, α). • Initialization: α = 0, t = 0 • Iterations: for h from 1 to H – Sample z ∈RD as independent logistics – Compute y∗= y∗(z, t, α) ∈arg max y∈{0,1}D z⊤y + t⊤y −PK k=1 αkf(y) – Replace t by t − C √ h y∗−⟨x⟩emp. + ∂tΩ(t, α) – Replace αk by αk − C √ h ⟨fk(x)⟩emp. −fk(y∗) + ∂αkΩ(t, α) +. • Output: (α, t). Since our cost function is convex and Lipschitz-continuous, the averaged iterates are converging to the global optimum [16] at rate 1/ √ H (for function values). 4.3 Extension to conditional maximum likelihood In experiments in Section 5, we consider a joint model over two binary vectors x, z ∈RD, as follows p(x, z|α, t, π) = p(x|α, t)p(z|x, π) = exp(−f(x) −A(f)) D Y d=1 πδ(zd̸=xd) d (1 −πd)δ(zd=xd), (6) 6 (a) original image (b) noisy image (c) denoised image Figure 2: Denoising of a horse image from the Weizmann horse database [3]. which corresponds to sampling x from a log-supermodular model and considering z that switches the values of x with probability πd for each d, that is, a noisy observation of x. We have: log p(x, z|α, t, π) = −f(x) −A(f) + PD d=1 −log(1 + eud) + xdud + zdud −2xdzdud , with ud = log πd 1−πd which is equivalent to πd = (1 + e−ud)−1. Using Bayes rule, we have p(x|z, α, t, π) ∝exp(−f(x) −A(f) + x⊤u −2x⊤(u ◦z)), which leads to the log-supermodular model p(x|z, α, t, π) = exp(−f(x) +x⊤(u−2u◦z)−A(f −u+ 2u◦z)). Thus, if we observe both z and x, we can consider a conditional maximization of the log-likelihood (still a convex optimization problem), which we do in our experiments for supervised image denoising, where we assume we know both noisy and original images at training time. Stochastic gradient on the logistic samples can then be used. Note that our conditional ML estimation can be seen as a form of approximate conditional random fields [13]. While supervised learning can be achieved by other techniques such as structured-output-SVMs [18, 20, 22], our approach also applies when we do not observe the original image, which we now consider. 4.4 Missing data through maximum likelihood In the model in Eq. (6), we now assume we only observed the noisy output z, and we perform parameter learning for α, t, π. This is a latent variable model for which maximum likelihood can be readily applied. We have: log p(z|α, t, π) = log P x∈{0,1} p(z, x|α, t, π) = log P x∈{0,1}D exp(−f(x) −A(f)) QD d=1 πδ(zd̸=xd) d (1 −πd)δ(zd=xd) = A(f −u + 2u ◦z) −A(f) + z⊤u −PD d=1 log(1 + eud). In practice, we will assume that the noise probability π (and hence u) is uniform across all elements. While we could use majorization-minization approaches such as the expectation-minimization algorithm (EM), we consider instead stochastic subgradient descent to learn the model parameters α, t and u (now a non-convex optimization problem, for which we still observed good convergence). 5 Experiments The aim of our experiments is to demonstrate the ability of our approach to remove noise in binary images, following the experimental set-up of [9]. We consider the training sample of Ntrain = 100 images of size D = 50 × 50, and the test sample of Ntest = 100 binary images, containing a horse silhouette from the Weizmann horse database [3]. At first we add some noise by flipping pixels values independently with probability π. In Figure 2, we provide an example from the test sample: the original, the noisy and the denoised image (by our algorithm). We consider the model from Section 4.3, with the two functions f1(x), f2(x) which are horizontal and vertical cut functions with binary weights respectively, together with a modular term of dimension D. To perform minimization we use graph-cuts [4] as we deal with positive or attractive potentials. Supervised image denoising. We assume that we observe N = 100 pairs (xi, zi) of original-noisy images, i = 1, . . . , N. We perform parameter inference by maximum likelihood using stochastic subgradient descent (over the logistic samples), with regularization by the squared ℓ2-norm, one 7 noise π max-marg. std mean-marginals std SVM-Struct std 1% 0.4% <0.1% 0.4% <0.1% 0.6% <0.1% 5% 1.1% <0.1% 1.1% <0.1% 1.5% <0.1% 10% 2.1% <0.1% 2.0% <0.1% 2.8% 0.3% 20% 4.2% <0.1% 4.1% <0.1% 6.0% 0.6% Table 1: Supervised denoising results. π is fixed π is not fixed π max-marg. std mean-marg. std max-marg. std mean-marg. std 1% 0.5% <0.1% 0.5% <0.1% 1.0% 1.0% 5% 0.9% 0.1% 1.0% 0.1% 3.5% 0.9% 3.6% 0.8% 10% 1.9% 0.4% 2.1% 0.4% 6.8% 2.2% 7.0% 2.0% 20% 5.3% 2.0% 6.0% 2.0% 20.0% 20.0% Table 2: Unsupervised denoising results. parameter for t, one for α, both learned by cross-validation. Given our estimates, we may denoise a new image by computing the “max-marginal”, e.g., the maximum a posteriori maxx p(x|z, α, t) through a single graph-cut, or computing “mean-marginals” with 100 logistic samples. To calculate the error we use the normalized Hamming distance and 100 test images. Results are presented in Table 1, where we compare the two types of decoding, as well as a structured output SVM (SVM-Struct [22]) applied to the same problem. Results are reported in proportion of correct pixels. We see that the probabilistic models here slightly outperform the max-margin formulation1 and that using mean-marginals (which is optimal given our loss measure) lead to slightly better performance. Unsupervised image denoising. We now only consider N = 100 noisy images z1, . . . , zN to learn the model, without the original images, and we use the latent model from Section 4.4. We apply stochastic subgradient descent for the difference of the two convex functions Alogistic to learn the model parameters and use fixed regularization parameters equal to 10−2. We consider two situations, with a known noise-level π or with learning it together with α and t. The error was calculated using either max-marginals and mean-marginals. Note that here, structuredoutput SVMs cannot be used because there is no supervision. Results are reported in Table 2. One explanation for a better performance for max-marginals in this case is that the unsupervised approach tends to oversmooth the outcome and max-marginals correct this a bit. When the noise level is known, the performance compared to supervised learning is not degraded much, showing the ability of the probabilistic models to perform parameter estimation with missing data. When the noise level is unknown and learned as well, results are worse, still better than a trivial answer for moderate levels of noise (5% and 10%) but not better than outputting the noisy image for extreme levels (1% and 20%). In challenging fully unsupervised case the standard deviation is up to 2.2% (which shows that our results are statistically significant). 6 Conclusion In this paper, we have presented how approximate inference based on stochastic gradient and “perturband-MAP” ideas could be used to learn parameters of log-supermodular models, allowing to benefit from the versatility of probabilistic modelling, in particular in terms of parameter estimation with missing data. While our experiments have focused on simple binary image denoising, exploring larger-scale applications in computer vision (such as done by [24, 21]) should also show the benefits of mixing probabilistic modelling and submodular functions. Acknowledgements. We acknowledge support the European Union’s H2020 Framework Programme (H2020-MSCA-ITN-2014) under grant agreement no642685 MacSeNet, and thank Sesh Kumar, Anastasia Podosinnikova and Anton Osokin for interesting discussions related to this work. 1[9] shows a stronger difference, which we believe (after consulting with authors) is due to lack of convergence for the iterative algorithm solving the max-margin formulation. 8 References [1] F. Bach. Learning with submodular functions: a convex optimization perspective. Foundations and Trends in Machine Learning, 6(2-3):145 – 373, 2013. [2] F. Bach. Submodular functions: from discrete to continuous domains. Technical Report 1511.00394, arXiv, 2015. [3] E. Borenstein, E. Sharon, and S. Ullman. Combining Top-down and Bottom-up Segmentation. In Proc. ECCV, 2004. [4] Y. Boykov, O. Veksler, and R. Zabih. Fast approximate energy minimization via graph cuts. IEEE Transactions on Pattern Analysis and Machine Intelligence, 23(11):1222–1239, 2001. [5] J. Djolonga and A. Krause. From MAP to Marginals: Variational Inference in Bayesian Submodular Models. In Adv. NIPS, 2014. [6] J. Djolonga and A. Krause. Scalable Variational Inference in Log-supermodular Models. In Proc. ICML, 2015. [7] S. Fujishige. Submodular Functions and Optimization. Annals of discrete mathematics. Elsevier, 2005. [8] D. Golovin and A. Krause. Adaptive Submodularity: Theory and Applications in Active Learning and Stochastic Optimization. Journal of Artificial Intelligence Research, 42:427–486, 2011. [9] T. Hazan and T. Jaakkola. On the Partition Function and Random Maximum A-Posteriori Perturbations. In Proc. ICML, 2012. [10] M. Jerrum and A. Sinclair. Polynomial-time approximation algorithms for the Ising model. SIAM Journal on Computing, 22(5):1087–1116, 1993. [11] P. Kohli, L. Ladicky, and P. H. S. Torr. Robust higher order potentials for enforcing label consistency. International Journal of Computer Vision, 82(3):302–324, 2009. [12] Andreas Krause and Daniel Golovin. Submodular function maximization. In Tractability: Practical Approaches to Hard Problems. Cambridge University Press, February 2014. [13] J. Lafferty, A. McCallum, and F. Pereira. Conditional random fields: Probabilistic models for segmenting and labeling sequence data. In Proc. ICML, 2001. [14] H. Lin and J. Bilmes. A class of submodular functions for document summarization. In Proc. NAACL/HLT, 2011. [15] S. Nadarajah and S. Kotz. A generalized logistic distribution. International Journal of Mathematics and Mathematical Sciences, 19:3169 – 3174, 2005. [16] A. Nemirovski, A. Juditsky, G. Lan, and A. Shapiro. Robust stochastic approximation approach to stochastic programming. SIAM Journal on Optimization, 19(4):1574–1609, 2009. [17] G. Papandreou and A. Yuille. Perturb-and-map random fields: Using discrete optimization to learn and sample from energy models. In Proc. ICCV, 2011. [18] M. Szummer, P. Kohli, and D. Hoiem. Learning CRFs using graph cuts. In Proc. ECCV, 2008. [19] D. Tarlow, R.P. Adams, and R.S. Zemel. Randomized optimum models for structured prediction. In Proc. AISTATS, 2012. [20] B. Taskar, C. Guestrin, and D. Koller. Max-margin Markov networks. 2003. [21] S. Tschiatschek, J. Djolonga, and A. Krause. Learning probabilistic submodular diversity models via noise contrastive estimation. In Proc. AISTATS, 2016. [22] I. Tsochantaridis, Thomas Joachims, T., Y. Altun, and Y. Singer. Large margin methods for structured and interdependent output variables. Journal of Machine Learning Research, 6:1453–1484, 2005. [23] M. J. Wainwright and M. I. Jordan. Graphical models, exponential families, and variational inference. Foundations and Trends in Machine Learning, 1(1-2):1–305, 2008. [24] J. Zhang, J. Djolonga, and A. Krause. Higher-order inference for multi-class log-supermodular models. In Proc. ICCV, 2015. 9 | 2016 | 520 |
6,462 | A Multi-step Inertial Forward–Backward Splitting Method for Non-convex Optimization Jingwei Liang and Jalal M. Fadili Normandie Univ, ENSICAEN, CNRS, GREYC {Jingwei.Liang,Jalal.Fadili}@greyc.ensicaen.fr Gabriel Peyré CNRS, DMA, ENS Paris Gabriel.Peyre@ens.fr Abstract We propose a multi-step inertial Forward–Backward splitting algorithm for minimizing the sum of two non-necessarily convex functions, one of which is proper lower semi-continuous while the other is differentiable with a Lipschitz continuous gradient. We first prove global convergence of the algorithm with the help of the Kurdyka-Łojasiewicz property. Then, when the non-smooth part is also partly smooth relative to a smooth submanifold, we establish finite identification of the latter and provide sharp local linear convergence analysis. The proposed method is illustrated on several problems arising from statistics and machine learning. 1 Introduction 1.1 Non-convex non-smooth optimization Non-smooth optimization has proved extremely useful to all quantitative disciplines of science including statistics and machine learning. A common trend in modern science is the increase in size of datasets, which drives the need for more efficient optimization schemes. For large-scale problems with non-smooth and possibly non-convex terms, it is possible to generalize gradient descent with the Forward–Backward (FB) splitting scheme [3] (a.k.a proximal gradient descent), which includes projected gradient descent as a sub-case. Formally, we equip Rn the n-dimensional Euclidean space with the standard inner product ⟨·, ·⟩and associated norm || · || respectively. Our goal is the generic minimization of composite objectives of the form min x∈Rn Φ(x) def= R(x) + F(x) , (P) where we have (A.1) R : Rn →R ∪{+∞} is the penalty function which is proper lower semi-continuous (lsc), and bounded from below; (A.2) F : Rn →R is the loss function which is finite-valued, differentiable and its gradient ∇F is L-Lipschitz continuous. Throughout, no convexity is imposed neither on R nor on F. The class of problems we consider is that of non-smooth and non-convex optimization problems. Here are some examples that are of particular relevance to problems in regression, machine learning and classification. Example 1.1 (Sparse regression). Let A ∈Rm×n, y ∈Rm, µ > 0, and ||x||0 is the ℓ0 pseudo-norm (see Example 4.1). Consider (see e.g. [11]) min x∈Rn 1 2||y −Ax||2 + µ||x||0. (1.1) 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. Example 1.2 (Principal component pursuit (PCP)). The PCP problem [9] aims at decomposing a given matrix into sparse and low-rank components min (xs,xl)∈(Rn1×n2)2 1 2||y −xs −xl||2 F + µ1||xs||0 + µ2rank(xl), (1.2) where || · ||F is the Frobenius norm and µ1 and µ2 > 0. Example 1.3 (Sparse Support Vector Machines). One would like to find a linear decision function which minimizes the objective min (b,x)∈R×Rn 1 m Pm i=1 G(⟨x, zi⟩+ b, yi) + µ||x||0, (1.3) where for i = 1, · · · , m, (zi, yi) ∈Rn × {±1} is the training set, and G is a smooth loss function with Lipschitz-continuous gradient such as the squared hinge loss G(ˆyi, yi) = max(0, 1 −ˆyiyi)2 or the logistic loss G(ˆyi, yi) = log(1 + e−ˆyiyi). (Inertial) Forward–Backward The Forward–Backward splitting method for solving (P) reads xk+1 ∈proxγkR xk −γk∇F(xk) , (1.4) where γk > 0 is a descent step-size, and proxγR(·) def= Argminx∈Rn 1 2||x −·||2 + γR(x), (1.5) denotes the proximity operator of R. proxγR(x) is non-empty under (A.1) and is set-valued in general. Lower-boundedness of R can be relaxed by requiring e.g. coercivity of the objective in (1.5). Since the pioneering work of Polyak [24] on the heavy-ball method approach to gradient descent, several works have adapted this methodology to various optimization schemes. For instance, the inertial proximal point algorithm [1, 2], or the inertial FB methods [22, 21, 4, 20]. The FISTA scheme [5, 10] also belongs to this class. See [20] for a detailed account. The non-convex case In the context of non-convex optimization, [3] was the first to establish convergence of the FB iterates when the objective Φ satisfies the Kurdyka-Łojasiewicz property1. Following their footprints, [8, 23] established convergence of the special inertial schemes in [22] in the non-convex setting. 1.2 Contributions In this paper, we introduce a novel inertial scheme (Algorithm 1) and study its global and local properties to solve the non-smooth and non-convex optimization problem (P). More precisely, our main contributions can be summarized as follows. A globally convergent general inertial scheme We propose a general multi-step inertial FB (MiFB) algorithm to solve (P). This algorithm is very flexible as it allows higher memory and even negative inertial parameters (unlike previous work [20]). Global convergence of any bounded sequence of iterates to a critical point is proved when the objective Φ is lower-bounded and satisfies the Kurdyka-Łojasiewicz property. Local convergence properties under partial smoothness Under the additional assumptions that the smooth part is locally C2 around a critical point x⋆(where xk →x⋆), and that the non-smooth component R is partly smooth (see Definition 3.1) relative to an active submanifold Mx⋆, we show that Mx⋆can be identified in finite time, i.e. xk ∈Mx⋆for all k large enough. Building on this finite identification result, we provide a sharp local linear convergence analysis and we characterize precisely the corresponding convergence rate which, in particular, reveals the role of Mx⋆. Moreover, this local convergence analysis naturally opens the door to higher-order acceleration, since under some circumstances, the original problem (P) is eventually equivalent to locally minimizing Φ on Mx⋆, and partial smoothness implies that Φ is actually C2 on Mx⋆. 1We are aware of the works existing on convergence of the objective sequence Φ(xk) of FB, including rates, in the non-smooth and non-convex setting. But given that, in general, this does not say anything about convergence of the sequence of iterates xk, they are irrelevant to our discussion. 2 Algorithm 1: A Multi-step Inertial Forward–Backward (MiFB) Initial: s ≥1 is an integer, I = {0, 1, . . . , s −1}, x0 ∈Rn and x−s = . . . = x−1 = x0. repeat Let 0 < γ ≤γk ≤γ < 1 L, {a0,k, a1,k, . . .} ∈] −1, 2]s, {b0,k, b1,k, . . .} ∈] −1, 2]s: ya,k = xk + P i∈Iai,k(xk−i −xk−i−1), yb,k = xk + P i∈Ibi,k(xk−i −xk−i−1), (1.6) xk+1 ∈proxγkR ya,k −γk∇F(yb,k) . (1.7) k = k + 1; until convergence; 1.3 Notations Throughout the paper, N is the set of non-negative integers. For a nonempty closed convex set Ω⊂Rn, ri(Ω) is its relative interior, and par(Ω) = R(Ω−Ω) is the subspace parallel to it. Let R : Rn →R ∪{+∞} be a lsc function, its domain is defined as dom(R) def= {x ∈Rn : R(x) < +∞}, and it is said to be proper if dom(R) ̸= ∅. We need the following notions from variational analysis, see e.g. [25] for details. Given x ∈dom(R), the Fréchet subdifferential ∂F R(x) of R at x, is the set of vectors v ∈Rn that satisfies lim infz→x, z̸=x 1 ||x−z||(R(z) −R(x) −⟨v, z −x⟩) ≥0. If x /∈dom(R), then ∂F R(x) = ∅. The limiting-subdifferential (or simply subdifferential) of R at x, written as ∂R(x), is defined as ∂R(x) def= {v ∈Rn : ∃xk →x, R(xk) →R(x), vk ∈∂F R(xk) → v}. Denote dom(∂R) def= {x ∈Rn : ∂R(x) ̸= ∅}. Both ∂F R(x) and ∂R(x) are closed, with ∂F R(x) convex and ∂F R(x) ⊂∂R(x) [25, Proposition 8.5]. Since R is lsc, it is (subdifferentially) regular at x if and only if ∂F R(x) = ∂R(x) [25, Corollary 8.11]. An lsc function R is r-prox-regular at ¯x ∈dom(R) for ¯v ∈∂R(¯x) if ∃r > 0 such that R(x′) > R(x) + ⟨v, x′ −x⟩−1 2r||x −x′||2 ∀x, x′ near ¯x, R(x) near R(¯x) and v ∈∂R(x) near ¯v. A necessary condition for x to be a minimizer of R is 0 ∈∂R(x). The set of critical points of R is crit(R) = {x ∈Rn : 0 ∈∂R(x)}. 2 Global convergence of MiFB 2.1 Kurdyka-Łojasiewicz property Let R : Rn →R ∪{+∞} be a proper lsc function. For η1, η2 such that −∞< η1 < η2 < +∞, define the set [η1 < R < η2] def= {x ∈Rn : η1 < R(x) < η2}. Definition 2.1. R is said to have the Kurdyka-Łojasiewicz property at ¯x ∈dom(R) if there exists η ∈]0, +∞], a neighbourhood U of ¯x and a continuous concave function ϕ : [0, η[→R+ such that (i) ϕ(0) = 0, ϕ is C1 on ]0, η[, and for all s ∈]0, η[, ϕ′(s) > 0; (ii) for all x ∈U ∩[R(¯x) < R < R(¯x) + η], the Kurdyka-Łojasiewicz inequality holds ϕ′ R(x) −R(¯x) dist 0, ∂R(x) ≥1. (2.1) Proper lsc functions which satisfy the Kurdyka-Łojasiewicz property at each point of dom(∂R) are called KL functions. Roughly speaking, KL functions become sharp up to reparameterization via ϕ, called a desingularizing function for R. Typical KL functions are the class of semi-algebraic functions, see [6, 7]. For instance, the ℓ0 pseudo-norm and the rank function (see Example 1.1-1.3 and Section 4.1) are indeed KL. 2.2 Global convergence Let µ, ν > 0 be two constants. For i ∈I and k ∈N, define the following quantities, βk def= 1 −γkL −µ −νγk 2γk , β def= lim inf k∈N βk and αi,k def= sa2 i,k 2γkµ + sb2 i,kL2 2ν , αi def= lim sup k∈N αi,k. (2.2) 3 Theorem 2.2 (Convergence of MiFB (Algorithm 1)). For problem (P), suppose that (A.1)-(A.2) hold, and moreover Φ is a proper lsc KL function. For Algorithm 1, choose µ, ν, γk, ai,k, bi,k such that δ def= β −P i∈Iαi > 0. (2.3) Then each bounded sequence {xk}k∈N generated by MiFB satisfies (i) {xk}k∈N has finite length, i.e. P k∈N ||xk −xk−1|| < +∞; (ii) There exists a critical point x⋆∈crit(Φ) such that limk→∞xk = x⋆. (iii) If Φ has the KL property at a global minimizer x⋆, then starting sufficiently close from x⋆, any sequence {xk}k∈N converges to a global minimum of Φ and satisfies (i). The proof is detailed in the supplementary material. Remark 2.3. (i) The convergence result holds true for any real Hilbert space. The boundedness of {xk}k∈N is automatically ensured under standard assumptions such as coercivity of Φ. (ii) It is known from [13] that if the desingularizing function ϕ = C θ tθ, C > 0 and θ ∈[ 1 2, 1[, then global linear convergence of the objective and the iterates can be derived. However, we will not pursue this further since our main interest is local linear convergence. (iii) Unlike existing work, negative inertial parameters are allowed by Theorem 2.2. (iv) When ai,k ≡0 and bi,k ≡0, i.e. the case of FB splitting, condition (2.3) holds naturally as long as γ < 1 L which recovers the case of [3]; (v) From (2.2) and (2.3), we conclude the following: (a) s = 1: if b0,k ≡b, a0,k ≡a (i.e. constant inertial parameters), then (2.3) implies that a, b belong to an ellipsoid: a2 2γµ + b2 2ν/L2 < β = 1−γL−µ−νγ 2γ . (b) When s ≥2, for each i ∈I, let bi,k = ai,k ≡ai (i.e. constant symmetric inertial parameters), then (2.3) means that the ai’s live in a ball: ( 1 2γµ + 1 2ν/L2 ) P i∈I a2 i < β. An empirical approach for inertial parameters Besides Theorem 2.2, we also provide an empirical bound for the choice of the inertial parameters. Consider the setting: γk ≡γ ∈]0, 1/L[ and bi,k = ai,k ≡ai ∈] −1, 2[, i ∈I. We have the following empirical bound for the summand P i∈I ai: P iai ∈ 0, min 1, 1/L−γ |2γ−1/L| . (2.4) To ensure the convergence {xk}k∈N, an online updating rule should be applied together with the empirical bound. More precisely, choose ai according to (2.4). Then for each k ∈N, let bi,k = ai,k and choose ai,k such that P i ai,k = min{P i ai, ck} where ck > 0 is such that {ck P i∈I ||xk−i − xk−i−1||}k∈N is summable. For instance, ck = c k1+q P i∈I ||xk−i−xk−i−1||, c > 0, q > 0. Note that the allowed choices of the summand P i ai by (2.4) is larger than those of Theorem 2.2. For instance, (2.4) allows P i ai = 1 for γ ∈]0, 2 3L]. While for Theorem 2.2, P i ai = 1 can be reached only when γ →0. 3 Local convergence properties of MiFB 3.1 Partial smoothness Let M ⊂Rn be a C2-smooth submanifold, let TM(x) the tangent space of M at any point x ∈M. Definition 3.1. The function R : Rn →R ∪{+∞} is C2-partly smooth at ¯x ∈M relative to M for ¯v ∈∂R(¯x) ̸= ∅if M is a C2-submanifold around ¯x, and (i) (Smoothness): R restricted to M is C2 around ¯x; (ii) (Regularity): R is regular at all x ∈M near ¯x and R is r-prox-regular at ¯x for ¯v; (iii) (Sharpness): TM(¯x) = par(∂R(x))⊥; (iv) (Continuity): The set-valued mapping ∂R is continuous at ¯x relative to M. We denote the class of partly smooth functions at x relative to M for v as PSFx,v(M). Partial smoothness was first introduced in [15] and its directional version stated here is due to [18, 12]. Prox-regularity is sufficient to ensure that the partly smooth submanifolds are locally unique [18, Corollary 4.12], [12, Lemma 2.3 and Proposition 10.12]. 4 3.2 Finite activity identification One of the key consequences of partial smoothness is finite identification of the partial smoothness submanifold associated to R for problem (P). This is formalized in the following statement. Theorem 3.2 (Finite activity identification). Suppose that Algorithm 1 is run under the conditions of Theorem 2.2, such that the generated sequence {xk}k∈N converges to a critical point x⋆∈crit(Φ). Assume that R ∈PSFx⋆,−∇F (x⋆)(Mx⋆) and the non-degeneracy condition −∇F(x⋆) ∈ri ∂R(x⋆) , (ND) holds. Then, xk ∈Mx⋆for all k large enough. See the supplementary material for the proof. This result generalizes that of [20] to the non-convex case and multiple inertial steps. 3.3 Local linear convergence Given γ ∈]0, 1 L[ and a critical point x⋆∈crit(Φ), let Mx⋆be a C2-smooth submanifold and R ∈PSFx⋆,−∇F (x⋆)(Mx⋆). Denote Tx⋆ def= TMx⋆(x⋆) and the following matrices which are all symmetric, H def= γPTx⋆∇2F(x⋆)PTx⋆, G def= Id −H, Q def= γ∇2 Mx⋆Φ(x⋆)PTx⋆−H, (3.1) where ∇2 Mx⋆Φ is the Riemannian Hessian of Φ along the submanifold Mx⋆(readers may refer to the supplementary material from more details on differential calculus on Riemannian manifolds). To state our local linear convergence result, the following assumptions will play a key role. Restricted injectivity Besides the local C2-smoothness assumption on F, following the idea of [19, 20], we assume the restricted injectivity condition, ker ∇2F(x⋆) ∩Tx⋆= {0}. (RI) Positive semi-definiteness of Q Assume that Q is positive semi-definite, i.e. ∀h ∈Tx⋆, ⟨h, Qh⟩≥0. (3.2) Under (3.2), Id + Q is symmetric positive definite, hence invertible, we denote P def= (Id + Q)−1. Convergent parameters The parameters of MiFB (Algorithm 1), are convergent, i.e. ai,k →ai, bi,k →bi, ∀i ∈I and γk →γ ∈[γ, min{γ, ¯r}], (3.3) where ¯r < r, and r is the prox-regularity modulus of R (see Definition 3.1). Remark 3.3. (i) Condition (3.2) can be met by various non-convex functions, such as polyhedral functions, including the ℓ0 pseudo-norm. For the rank function, it is also observed that this condition holds in our numerical experiments of Section 4. (ii) Condition (3.3) asserts that both the inertial parameters (ai,k, bi,k) and the step-size γk should converge to some limit points, and this condition cannot be relaxed in general. (iii) It can be shown that conditions (3.2) and (RI) together imply that x⋆is a local minimizer of Φ in (P), and Φ grows at least quadratically near x⋆. The arguments to prove this are essentially adapted from those used to show [20, Proposition 4.1(ii)]. We need the following notations: M0 def= (a0 −b0)P + (1 + b0)PG, Ms def= −(as−1 −bs−1)P −bs−1PG, Mi def= − (ai−1 −ai) −(bi−1 −bi) P −(bi−1 −bi)PG, i = 1, ..., s −1, M def= M0 · · · Ms−1 Ms Id · · · 0 0 ... ... ... ... 0 · · · Id 0 , dk def= xk −x⋆ ... xk−s −x⋆ . (3.4) 5 Theorem 3.4 (Local linear convergence). Suppose that Algorithm 1is run under the setting of Theorem 3.2. Moreover, assume that (RI), (3.2) and (3.3) hold. Then for all k large enough, dk+1 = Mdk + o(||dk||). (3.5) If ρ(M) < 1, then given any ρ ∈]ρ(M), 1[, there exists K ∈N such that ∀k ≥K, ||xk −x⋆|| = O(ρk−K). (3.6) In particular, if s = 1, then ρ(M) < 1 if R is locally polyhedral around x⋆or if a0 = b0. See the supplementary material for the proof. Remark 3.5. (i) When s = 1, ρ(M) can be given explicitly in terms of the parameters of the algorithm (i.e. a0, b0 and γ), see [20, Section 4.2] for details. However, the spectral analysis of M becomes much more complicated to get for s ≥2, where the analysis of at least cubic equations are involved. Therefore, for the sake of brevity, we shall skip the detailed discussion here. (ii) When s = 1, it was shown in [20] that the optimal convergence rate that can be obtained by 1-step inertial scheme with fixed γ is ρ⋆ s=1 = 1 −√1 −τγ, where from condition (RI), continuity of ∇2F at x⋆implies that there exists τ > 0 and a neighbourhood of x⋆such that ⟨h, ∇2F(x⋆)h⟩≥τ||h||2, for all h ∈Tx⋆. As we will see in the numerical experiments of Section 4, such a rate can be improved by our multi-step inertial scheme. Taking s = 2 for example, we will show that for a certain class of functions, the optimal local linear rate is close to or even is ρ⋆ s=2 = 1 − 3√1 −τγ, which is obviously faster than ρ⋆ s=1. (iii) Though it can be satisfied for many problems in practice, the restricted injectivity (RI) can be removed for some penalties R, for instance, when R is locally polyhedral near x⋆. 4 Numerical experiments In this section, we illustrate our results with some numerical experiments carried out on the problems in Example 1.1, 1.2 and 1.3. 4.1 Examples of KL and partly smooth functions All the objectives Φ in the above mentioned examples are continuous KL functions. Indeed, in Example 1.1 and 1.2, Φ is the sum of semi-algebraic functions which is also semi-algebraic. In Example 1.3, Φ is also algebraic when G is the squared hinge loss, and definable in an o-minimal structure for the logistic loss (see e.g. [26] for material on o-minimal structures). Moreover, R is partly smooth in all these examples as we show now. Example 4.1 (ℓ0 pseudo-norm). The ℓ0 pseudo-norm is locally constant. Moreover, it is regular on Rn ([14, Remark 2]) and its subdifferential is given by (see [14, Theorem 1]) ∂||x||0 = span (ei)i∈supp(x)c , where (ei)i=1,...,n is the standard basis, and supp(x) = i : xi ̸= 0 . The proximity operator of ℓ0-norm is given by hard-thresholding, proxγ||x||0(z) = z if |z| > √2γ, sign(z)[0, z] if |z| = √2γ, 0 if |z| < √2γ. It can then be easily verified that the ℓ0 pseudo-norm is partly smooth at any x relative to the subspace Mx = Tx = z ∈Rn : supp(z) ⊂supp(x) . It is also prox-regular at x for any bounded v ∈∂||x||0. Note also condition (ND) is automatically verified and that the Riemannian gradient and Hessian along Tx of || · ||0 vanish. Example 4.2 (Rank). The rank function is the spectral extension of ℓ0 pseudo-norm to matrixvalued data x ∈Rn1×n2 [17]. Consider a singular value decomposition (SVD) of x, i.e. x = Udiag(σ(x))V ∗, where U = {u1, . . . , un}, V = {v1, . . . , vn} are orthonormal matrices, and 6 σ(x) = (σi(x))i=1,...,n is the vector of singular values. By definition, rank(x) def= ||σ(x)||0. Thus the rank function is partly smooth relative at x to the set of fixed rank matrices Mx = z ∈Rn1×n2 : rank(z) = rank(x) , which is a C2-smooth submanifold [16]. The tangent space of Mx at x is TMx(x) = Tx = z ∈Rn1×n2 : u∗ i zvj = 0, for all r < i ≤n1, r < j ≤n2 , The rank function is also regular its subdifferential reads ∂rank(x) = U∂ ||σ(x)||0 V ∗= Uspan (ei)i∈supp(σ(x))c V ∗, which is a vector space (see [14, Theorem 4 and Proposition 1]). The proximity operator of rank function amounts to applying hard-thresholding to the singular values. Observe that by definition of Mx, the Riemannian gradient and Hessian of the rank function along Mx also vanish. For Example 1.2, it is worth noting from the above examples and separability of the regularizer that the latter is also partly smooth relative to the cartesian product of the partial smoothness submanifolds of ℓ0 and the rank function. 4.2 Experimental results For the problem in Example 1.1, we generated y = Axob + ω with m = 48, n = 128, the entries of A are i.i.d. zero-mean and unit variance Gaussian, xob is 8-sparse, and ω ∈Rm is an additive noise with small variance. For the problem in Example 1.2, we generated y = xs +xl +ω, with n1 = n2 = 50, xs is 250-sparse, and the rank of xl is 5, and ω is an additive noise with small variance. For Example 1.3, we generated m = 64 training samples with n = 96-dimensional feature space. For all presented numerical results, 3 different settings were tested: • the FB method, with γk ≡0.3/L, noted as “FB”; • MiFB with s = 1, bk = ak ≡a and γk ≡0.3/L, noted as “1-iFB”; • MiFB with s = 2, bi,k = ai,k ≡ai, i = 0, 1 and γk ≡0.3/L, noted as “2-iFB”. Tightness of theoretical prediction The convergence profiles of ||xk −x⋆|| are shown in Figure 1. As it can be seen from all the plots, finite identification and local linear convergence indeed occur. The positions of the green dots indicate the iteration from which xk numerically identifies the submanifold Mx⋆. The solid lines (“P”) represents practical observations, while the dashed lines (“T”) denotes theoretical predictions. As the Riemannian Hessians of ℓ0 and the rank both vanish in all examples, our predicted rates coincide exactly with the observed ones (same slopes for the dashed and solid lines). 100 200 300 400 500 600 700 800 900 1000 k 10-10 10-6 10-2 102 kxk ! x?k FB, P FB, T 1 - iFB P 1 - iFB, T 2 - iFB, P 2 - iFB, T 2 - iFB optimal 1 ! p 1 ! =. 1 ! 3p 1 ! =. (a) Sparse regression 50 100 150 200 250 300 350 k 10-10 10-6 10-2 102 kxk ! x?k FB, P FB, T 1 - iFB P 1 - iFB, T 2 - iFB, P 2 - iFB, T 2 - iFB optimal 1 ! p 1 ! =. 1 ! (1 ! =.)1=3 (b) PCP 200 400 600 800 1000 1200 1400 1600 1800 2000 k 10-10 10-6 10-2 102 kxk ! x?k FB, P FB, T 1 - iFB P 1 - iFB, T 2 - iFB, P 2 - iFB, T 2 - iFB optimal 1 ! p 1 ! =. 1 ! (1 ! =.)1=3 (c) Sparse SVM Figure 1: Finite identification and local linear convergence of MiFB under different inertial settings in terms of ||xk −x⋆||. “P” stands for practical observation and “T” indicates the theoretical estimate. We fix γk ≡0.3/L for all tests. For the 2 inertial schemes, inertial parameters are first chosen such that (2.3) holds. The position of the green dot in each plot indicates the iteration beyond which identification of Mx⋆occurs. Comparison of the methods Under the tested settings, we draw the following remarks on the comparison of the inertial schemes: 7 • The MiFB scheme is much faster than FB both globally and locally. Finite activity identification also occurs earlier for MiFB than for FB; • Comparing the two MIFB inertial schemes, “2-iFB” outperforms “1-iFB”, showing the advantages of a 2-step inertial scheme over the 1-step one. Optimal first-order method To highlight the potential of multiple steps in MiFB, for the “2-iFB” scheme, we also added an example where we locally optimized the rate for the inertial parmeters. See the magenta lines all the examples, where the solid line corresponds to the observed profile for the optimal inertial parameters, the dashed line stands for the rate 1 −√1 −τγ, and the dotted line is that of 1 − 3√1 −τγ, which shows indeed that a faster linear rate can be obtained owing to multiple inertial parameters. We refer to [20, Section 4.5] for the optimal choice of inertial parameters for the case s = 1. The empirical bound (2.4) and inertial steps s We now present a short comparison of the empirical bound (2.4) of inertial parameters and different choices of s under bigger choice of γ = 0.8/L. MiFB with 3 inertial steps, i.e. s = 3, is added which is noted as “3-iFB”, see the magenta line in Figure 2. Similar to the above experiments, we choose bi,k = ai,k ≡ai, i ∈I, and “Thm 2.2” means that ai’s are chosen according to Theorem 2.2, while “Bnd (2.4)” means that ai’s are chosen based on the empirical bound (2.4). We can infer from Figure 2 the following. Compared to the results in Figure 1, a bigger choice of γ leads to faster convergence. Yet still, under the same choice of γ, MiFB is faster than FB both locally and globally; For either “Thm 2.2” or “Bnd (2.4)”, the performance of the three MiFB schemes are close, this is mainly due to the fact that values of the sum P i∈Iai for each scheme are close. Then between “Thm 2.2” and “Bnd (2.4)”, “Bnd (2.4)” shows faster convergence result, since the allowed value of P i∈Iai of (2.4) is bigger than that of Theorem 2.2. It should be noted that, when γ ∈]0, 2 3L], the largest value of P i∈Iai allowed by (2.4) is 1. If we choose P i∈Iai equal or very close to 1, then it can be observed in practice that MiFB locally oscillates, which is a well-known property of the FISTA scheme [5, 10]. We refer to [20, Section 4.4] for discussions of the properties of such oscillation behaviour. 100 200 300 400 500 600 700 k 10-10 10-6 10-2 102 kxk ! x?k FB 1 - iFB, Thm 2.2 2 - iFB, Thm 2.2 3 - iFB, Thm 2.2 1 - iFB, Bnd (2.4) 2 - iFB, Bnd (2.4) 3 - iFB, Bnd (2.4) (a) Sparse regression 20 40 60 80 100 120 k 10-10 10-6 10-2 102 kxk ! x?k FB 1 - iFB, Thm 2.2 2 - iFB, Thm 2.2 3 - iFB, Thm 2.2 1 - iFB, Bnd (2.4) 2 - iFB, Bnd (2.4) 3 - iFB, Bnd (2.4) (b) PCP 100 200 300 400 500 600 700 k 10-10 10-6 10-2 102 kxk ! x?k FB 1 - iFB, Thm 2.2 2 - iFB, Thm 2.2 3 - iFB, Thm 2.2 1 - iFB, Bnd (2.4) 2 - iFB, Bnd (2.4) 3 - iFB, Bnd (2.4) (c) Sparse SVM Figure 2: Comparison of MiFB under different inertial settings. We fix γk ≡0.8/L for all tests. For the three inertial schemes, the inertial parameters were chosen such that (2.3) holds. Acknowledgments This work was partly supported by the European Research Council (ERC project SIGMA-Vision). References [1] F. Alvarez. On the minimizing property of a second order dissipative system in Hilbert spaces. SIAM Journal on Control and Optimization, 38(4):1102–1119, 2000. [2] F. Alvarez and H. Attouch. An inertial proximal method for maximal monotone operators via discretization of a nonlinear oscillator with damping. Set-Valued Analysis, 9(1-2):3–11, 2001. [3] H. Attouch, J. Bolte, and B. F. Svaiter. Convergence of descent methods for semi-algebraic and tame problems: proximal algorithms, Forward–Backward splitting, and regularized Gauss–Seidel methods. Mathematical Programming, 137(1-2):91–129, 2013. [4] H. Attouch, J. Peypouquet, and P. Redont. A dynamical approach to an inertial Forward–Backward algorithm for convex minimization. SIAM J. Optim., 24(1):232–256, 2014. 8 [5] A. Beck and M. Teboulle. A fast iterative shrinkage-thresholding algorithm for linear inverse problems. SIAM Journal on Imaging Sciences, 2(1):183–202, 2009. [6] J. Bolte, A. Daniilidis, and A. Lewis. The Łojasiewicz inequality for nonsmooth subanalytic functions with applications to subgradient dynamical systems. SIAM Journal on Optimization, 17(4):1205–1223, 2007. [7] J. Bolte, A. Daniilidis, O. Ley, and L. Mazet. Characterizations of Lojasiewicz inequalities: subgradient flows, talweg, convexity. Transactions of the American Mathematical Society, 362(6):3319–3363, 2010. [8] R. I. Bo¸t, E. R. Csetnek, and S. C. László. An inertial Forward–Backward algorithm for the minimization of the sum of two nonconvex functions. EURO Journal on Computational Optimization, pages 1–23, 2014. [9] E. J. Candès, X. Li, Y. Ma, and J. Wright. Robust principal component analysis? Journal of the ACM (JACM), 58(3):11, 2011. [10] A. Chambolle and C. Dossal. On the convergence of the iterates of the “Fast Iterative Shrinkage/Thresholding Algorithm”. Journal of Optimization Theory and Applications, pages 1–15, 2015. [11] D. L. Donoho, M. Elad, and V. N. Temlyakov. Stable recovery of sparse overcomplete representations in the presence of noise. IEEE Trans. Inform. Theory, 52(1):6–18, 2006. [12] D. Drusvyatskiy and A. S. Lewis. Optimality, identifiability, and sensitivity. Mathematical Programming, pages 1–32, 2013. [13] P. Frankel, G. Garrigos, and J. Peypouquet. Splitting methods with variable metric for kurdyka–łojasiewicz functions and general convergence rates. Journal of Optimization Theory and Applications, 165(3):874–900, 2015. [14] H. Y. Le. Generalized subdifferentials of the rank function. Optimization Letters, 7(4):731–743, 2013. [15] A. S. Lewis. Active sets, nonsmoothness, and sensitivity. SIAM J. on Optimization, 13(3):702–725, 2003. [16] A. S. Lewis and J. Malick. Alternating projections on manifolds. Mathematics of Operations Research, 33(1):216–234, 2008. [17] A. S. Lewis and H. S. Sendov. Twice differentiable spectral functions. SIAM Journal on Matrix Analysis and Applications, 23(2):368–386, 2001. [18] A. S. Lewis and S. Zhang. Partial smoothness, tilt stability, and generalized Hessians. SIAM Journal on Optimization, 23(1):74–94, 2013. [19] J. Liang, J. Fadili, and G. Peyré. Local linear convergence of Forward–Backward under partial smoothness. In Advances in Neural Information Processing Systems, pages 1970–1978, 2014. [20] J. Liang, J. Fadili, and G. Peyré. Activity identification and local linear convergence of Forward–Backwardtype methods. arXiv:1503.03703, 2015. [21] D. A. Lorenz and T. Pock. An inertial Forward–Backward algorithm for monotone inclusions. Journal of Mathematical Imaging and Vision, 51(2):311–325, 2014. [22] A. Moudafiand M. Oliny. Convergence of a splitting inertial proximal method for monotone operators. Journal of Computational and Applied Mathematics, 155(2):447–454, 2003. [23] P. Ochs, Y. Chen, T. Brox, and T. Pock. iPiano: inertial proximal algorithm for nonconvex optimization. SIAM Journal on Imaging Sciences, 7(2):1388–1419, 2014. [24] B. T. Polyak. Some methods of speeding up the convergence of iteration methods. USSR Computational Mathematics and Mathematical Physics, 4(5):1–17, 1964. [25] R. T. Rockafellar and R. Wets. Variational analysis, volume 317. Springer Verlag, 1998. [26] L. van den Dries. Tame topology and o-minimal structures, volume 248 of Mathematrical Society Lecture Notes. Cambridge Univiversity Press, New York, 1998. 9 | 2016 | 521 |
6,463 | Optimal Binary Classifier Aggregation for General Losses Akshay Balsubramani University of California, San Diego abalsubr@ucsd.edu Yoav Freund University of California, San Diego yfreund@ucsd.edu Abstract We address the problem of aggregating an ensemble of predictors with known loss bounds in a semi-supervised binary classification setting, to minimize prediction loss incurred on the unlabeled data. We find the minimax optimal predictions for a very general class of loss functions including all convex and many non-convex losses, extending a recent analysis of the problem for misclassification error. The result is a family of semi-supervised ensemble aggregation algorithms which are as efficient as linear learning by convex optimization, but are minimax optimal without any relaxations. Their decision rules take a form familiar in decision theory – applying sigmoid functions to a notion of ensemble margin – without the assumptions typically made in margin-based learning. 1 Introduction Consider a binary classification problem, in which we are given an ensemble of individual classifiers to aggregate into the most accurate predictor possible for data falling into two classes. Our predictions are measured on a large test set of unlabeled data, on which we know the ensemble classifiers’ predictions but not the true test labels. Without using the unlabeled data, the prototypical supervised solution is empirical risk minimization (ERM): measure the errors of the ensemble classifiers with labeled data, and then simply predict according to the best classifier. But can we learn a better predictor by using unlabeled data as well? This problem is central to semi-supervised learning. The authors of this paper recently derived the worst-case-optimal solution for it when performance is measured with classification error ([1]). However, this zero-one loss is inappropriate for other common binary classification tasks, such as estimating label probabilities, and handling false positives and false negatives differently. Such goals motivate the use of different evaluation losses like log loss and cost-weighted misclassification loss. In this paper, we generalize the setup of [1] to these loss functions and a large class of others. Like the earlier work, the choice of loss function completely specifies the minimax optimal ensemble aggregation algorithm in our setting, which is efficient and scalable. The algorithm learns weights over the ensemble classifiers by minimizing a convex function. The optimal prediction on each example in the test set is a sigmoid-like function of a linear combination of the ensemble predictions, using the learned weighting. Due to the minimax structure, this decision rule depends solely upon the loss function and upon the structure of the ensemble predictions on data, with no parameter or model choices. 1.1 Preliminaries Our setting generalizes that of [1], in which we are given an ensemble H = {h1, . . . , hp} and unlabeled (test) examples x1, . . . , xn on which to predict. The ensemble’s predictions on the unlabeled 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. data are written as a matrix F: F = h1(x1) h1(x2) · · · h1(xn) ... ... ... ... hp(x1) hp(x2) · · · hp(xn) (1) We use vector notation for the rows and columns of F: hi = (hi(x1), · · · , hi(xn))⊤and xj = (h1(xj), · · · , hp(xj))⊤. Each example j ∈[n] has a binary label yj ∈{−1, 1}, but the test labels are allowed to be randomized, represented by values in [−1, 1] instead of just the two values {−1, 1}; e.g. zi = 1 2 indicates yi = +1 w.p. 3 4 and −1 w.p. 1 4. So the labels on the test data can be represented by z = (z1; . . . ; zn) ∈[−1, 1]n, and are unknown to the predictor, which predicts g = (g1; . . . ; gn) ∈[−1, 1]n. 1.2 Loss Functions We incur loss on test example j according to its true label yj. If yj = 1, then the loss of predicting gj ∈[−1, 1] on it is some function ℓ+(gj); and if yj = −1, then the loss is ℓ−(gj). To illustrate, if the loss is the expected classification error, then gj ∈[−1, 1] can be interpreted as a randomized binary prediction in the same way as zj, so that ℓ+(gj) = 1 2 (1 −gj) and ℓ−(gj) = 1 2 (1 + gj). We call ℓ± the partial losses here, following earlier work (e.g. [16]). Since the true label can only be ±1, the partial losses fully specify the decision-theoretic problem we face, and changing them is tantamount to altering the prediction task. What could such partial losses conceivably look like in general? Observe that they intuitively measure discrepancy to the true label ±1. Consequently, it is natural for e.g. ℓ+(g) to be decreasing, as g increases toward the notional true label +1. This suggests that both partial losses ℓ+(·) and ℓ−(·) would be monotonic, which we assume hereafter in this paper (throughout we use increasing to mean “monotonically nondecreasing” and vice versa). Assumption 1. Over the interval (−1, 1), ℓ+(·) is decreasing and ℓ−(·) is increasing, and both are twice differentiable. We view Assumption 1 as very mild, as motivated above. Notably, convexity or symmetry of the partial losses are not required. In this paper, “general losses” refer to loss functions whose partial losses satisfy Assumption 1, to contrast them with convex losses or other subclasses. The expected loss incurred w.r.t. the randomized true labels zj is a linear combination of the partial losses: ℓ(zj, gj) := 1 + zj 2 ℓ+(gj) + 1 −zj 2 ℓ−(gj) (2) Decision theory and learning theory have thoroughly investigated the nature of the loss ℓand its partial losses, particularly how to estimate the “conditional label probability” zj using ℓ(zj, gj). A natural operation to do this is to minimize the loss over gj, and a loss ℓsuch that arg min g∈[−1,1] ℓ(zj, g) = zj (for all zj ∈[−1, 1]) is called a proper loss ([17, 16]). 1.3 Minimax Formulation As in [1], we formulate the ensemble aggregation problem as a two-player zero-sum game between a predictor and an adversary. In this game, the first player is the predictor, playing predictions over the test set g ∈[−1, 1]n. The adversary then sets the true labels z ∈[−1, 1]n. The key idea is that any ensemble constituent i ∈[p] known to have low loss on the test data gives us information about the unknown z, as z is constrained to be “close” to the test predictions hi. Each hypothesis in the ensemble represents such a constraint, and z is in the intersection of all these constraint sets, which interact in ways that depend on the ensemble predictions F. Accordingly, for now assume the predictor knows a vector of label correlations b such that ∀i ∈[p] : 1 n n X j=1 hi(xj)zj ≥bi (3) 2 i.e. 1 nFz ≥b. When the ensemble is composed of binary classifiers which predict in [−1, 1], these p inequalities represent upper bounds on individual classifier error rates. These can be estimated from the training set w.h.p. when the training and test data are i.i.d. using uniform convergence, exactly as in the prototypical supervised ERM procedure discussed in the introduction ([5]). So in our game-theoretic formulation, the adversary plays under ensemble constraints defined by b. The predictor’s goal is to minimize the worst-case expected loss of g on the test data (w.r.t. the randomized labeling z), using the loss function as defined earlier in Equation (2): ℓ(z, g) := 1 n n X j=1 ℓ(zj, gj) This goal can be written as the following optimization problem, a two-player zero-sum game: V := min g∈[−1,1]n max z∈[−1,1]n, 1 n Fz≥b ℓ(z, g) (4) = min g∈[−1,1]n max z∈[−1,1]n, 1 n Fz≥b 1 n n X j=1 1 + zj 2 ℓ+(gj) + 1 −zj 2 ℓ−(gj) (5) In this paper, we solve the learning problem faced by the predictor, finding an optimal strategy g∗realizing the minimum in (4) for any given “general loss” ℓ. This strategy guarantees the best possible worst-case performance on the unlabeled dataset, with an upper bound of V on the loss. Indeed, for all z0 and g0 obeying the constraints, Equation (4) implies the tight inequalities min g∈[−1,1]n ℓ(z0, g) (a) ≤V ≤ max z∈[−1,1]n, 1 n Fz≥b ℓ(z, g0) (6) and g∗attains the equality in (a), with a worst-case loss as good as any aggregated predictor. In our formulation of the problem, the constraints on the adversary take a central role. As discussed in previous work with this formulation ([1, 2]), these constraints encode the information we have about the true labels. Without them, the adversary would find it optimal to trivially guarantee error (arbitrarily close to) 1 2 by simply setting all labels uniformly at random (z = 0n). It is clear that adding information through more constraints will never raise the error bound V . 1 Nothing has yet been assumed about ℓ(z, g) other than Assumption 1. Our main results will require only this, holding for general losses. This brings us to this paper’s contributions: 1. We give the exact minimax g∗∈[−1, 1]n for general losses (Section 2.1). The optimal prediction on each example j is a sigmoid function of a fixed linear combination of the ensemble’s p predictions on it, so g∗is a non-convex function of the ensemble predictions. By (6), this incurs the lowest worst-case loss of any predictor constructed with the ensemble information F and b. 2. We derive an efficient algorithm for learning g∗, by solving a p-dimensional convex optimization problem. This applies to a broad class of losses (cf. Lem. 2), including any with convex partial losses. Sec. 2 develops and discusses the results. 3. We extend the optimal g∗and efficient learning algorithm for it, as above, to a large variety of more general ensembles and prediction scenarios (Sec. 3), including constraints arising from general loss bounds, and ensembles of “specialists” and heterogeneous features. 2 Results for Binary Classification Based on the loss, define the function Γ : [−1, 1] 7→R as Γ(g) := ℓ−(g) −ℓ+(g). (We also write the vector Γ(g) componentwise with [Γ(g)]j = Γ(gj) for convenience, so that Γ(hi) ∈Rn and Γ(xj) ∈Rp.) Observe that by Assumption 1, Γ(g) is increasing on its domain; so we can discuss its inverse Γ−1(m), which is typically sigmoid-shaped, as will be illustrated. With these we will set up the solution to the game (4), which relies on a convex function. 1However, it may pose difficulties in estimating b by applying uniform convergence over a larger H ([2]). 3 Figure 1: At left are plots of potential wells. At right are optimal prediction functions g, as a function of score. Both are shown for various losses, as listed in Section 2.3. Definition 1 (Potential Well). Define the potential well Ψ(m) := −m + 2ℓ−(−1) if m ≤Γ(−1) ℓ+(Γ−1(m)) + ℓ−(Γ−1(m)) if m ∈(Γ(−1), Γ(1)) m + 2ℓ+(1) if m ≥Γ(1) Lemma 2. The potential well Ψ(m) is continuous and 1-Lipschitz. It is also convex under any of the following conditions: (A) The partial losses ℓ±(·) are convex over (−1, 1). (B) The loss function ℓ(·, ·) is a proper loss. (C) ℓ′ −(x)ℓ′′ +(x) ≥ℓ′′ −(x)ℓ′ +(x) for all x ∈(−1, 1). Condition (C) is also necessary for convexity of Ψ, under Assumption 1. So the potential wells for different losses are shaped similarly, as seen in Figure 1. Lemma 2 tells us that the potential well is easy to optimize under any of the given conditions. Note that these conditions encompass convex surrogate losses commonly used in ERM, including all such “marginbased” losses (convex univariate functions of zjgj), introduced primarily for their favorable computational properties. An easily optimized potential well benefits us, because the learning problem basically consists of optimizing it over the unlabeled data, as we will soon make explicit. The function that will actually be optimized is in terms of the dual parameters, so we call it the slack function. Definition 3 (Slack Function). Let σ ≥0p be a weight vector over H (not necessarily a distribution). The vector of scores is F⊤σ = (x⊤ 1 σ, . . . , x⊤ n σ), whose elements’ magnitudes are the margins. The prediction slack function is γ(σ, b) := γ(σ) := −b⊤σ + 1 n n X j=1 Ψ(x⊤ j σ) (7) An optimal weight vector σ∗is any minimizer of the slack function: σ∗∈arg min σ≥0p [γ(σ)]. 2.1 Solution of the Game These are used to describe the minimax equilibrium of the game (4), in our main result. Theorem 4. The minimax value of the game (4) is min g∈[−1,1]n max z∈[−1,1]n, 1 n Fz≥b ℓ(z, g) = V = 1 2γ(σ∗) = 1 2 min σ≥0p −b⊤σ + 1 n n X j=1 Ψ(x⊤ j σ) 4 The minimax optimal predictions are defined as follows: for all j ∈[n], g∗ j := gj(σ∗) = −1 if x⊤ j σ∗≤Γ(−1) Γ−1(x⊤ j σ∗) if x⊤ j σ∗∈(Γ(−1), Γ(1)) 1 if x⊤ j σ∗≥Γ(1) (8) g∗ j is always an increasing sigmoid, as shown in Figure 1. We can also redo the proof of Theorem 4 when g ∈[−1, 1]n is not left as a free variable set in the game, but instead is preset to g(σ) as in (8) for some (possibly suboptimal) weight vector σ. Observation 5. For any weight vector σ0 ≥0p, the worst-case loss after playing g(σ0) is max z∈[−1,1]n, 1 n Fz≥b ℓ(z, g(σ0)) ≤1 2γ(σ0) The proof is a simplified version of that of Theorem 4; there is no minimum over g to deal with, and the minimum over σ ≥0p in Equation (13) is upper-bounded by using σ0. This result is an expression of weak duality in our setting, and generalizes Observation 4 of [1]. 2.2 Ensemble Aggregation Algorithm Theorem 4 defines a prescription for aggregating the given ensemble predictions on the test set. Learning: Minimize the slack function γ(σ), finding the minimizer σ∗that achieves V . This is a convex optimization under broad conditions (Lemma 2), and when the test examples are i.i.d. the Ψ term is a sum of n i.i.d. functions. Therefore, it is readily amenable to standard first-order optimization methods which require only O(1) test examples at once. In practice, learning employs such methods to approximately minimize γ, finding some σA such that γ(σA) ≤γ(σ∗) + ϵ for some small ϵ. Standard convex optimization methods are guaranteed to do this for binary classifier ensembles, because the slack function is Lipschitz (Lemma 2) and ∥b∥∞≤1. Prediction: Predict g(σ∗) on any test example, as indicated in (8). This decouples the prediction task over each test example separately, which requires O(p) time and memory like p-dimensional linear prediction. After finding an ϵ-approximate minimizer σA in the learning step as above, Observation 5 tells us that the prediction g(σA) has loss ≤V + ϵ 2. In particular, note that there is no algorithmic dependence on n in either step in a statistical learning setting. So though our formulation is transductive, it is no less tractable than a stochastic optimization setting in which i.i.d. data arrive one at a time, and applies to this common situation. 2.3 Examples of Different Losses To further illuminate Theorem 4, we detail a few special cases in which ℓ± are explicitly defined. These losses may be found throughout the literature (see e.g. [16]). The key functions Ψ and g∗are listed for these losses in Appendix A, and in many cases in Figure 1. The nonlinearities used for g∗ are sigmoids, arising solely from the intrinsic minimax structure of the classification game. • 0-1 Loss: Here gj is taken to be a randomized binary prediction; this case was developed in [1], the work we generalize in this paper. • Log Loss, Square Loss • Cost-Weighted Misclassification (Quantile) Loss: This is defined with a parameter c ∈ [0, 1] representing the relative cost of false positives vs. false negatives, making the Bayesoptimal classifier the c-quantile of the conditional probability distribution ([19]). • Exponential Loss, Logistic Loss • Hellinger Loss: This is typically given for p, y ∈ [0, 1] as 1 2 √p −√y 2 + √1 −p −√1 −y 2 . Our formulation is equivalent when the prediction and label are rescaled to [−1, 1]. 5 • “AdaBoost Loss”: If the goal of AdaBoost ([18]) is interpreted as class probability estimation, the implied loss is proper and given in [6, 16]. • Absolute Loss and Hinge Loss: The absolute loss can be defined by ℓabs ∓(gj) = 1 ± gj, and the hinge loss also has ℓabs ∓(gj) = 1 ± gj since the kink in the hinge loss only lies at gj = ∓1. These partial losses are the same as for 0-1 loss up to scaling, and therefore all our results for Ψ and g∗are as well. So these losses are not shown in Appendix A. • Sigmoid Loss: This is an example of a sigmoid-shaped margin loss, a nonconvex smooth surrogate for 0-1 loss. Similar losses have arisen in a variety of binary classification contexts, from robustness (e.g. [9]) to active learning ([10]) and structured prediction ([14]). 2.4 Related Work and Technical Discussion There are two notable ways in which the result of Theorem 4 is particularly advantageous and general. First, the fact that ℓ(z, g) can be non-convex in g, yet solvable by convex optimization, is a major departure from previous work. Second, the solution has a convenient dependence on n (as in [1]), simply averaging a function over the unlabeled data, which is not only mathematically convenient but also makes stochastic O(1)-space optimization practical. This is surprisingly powerful, because the original minimax problem is jointly over the entire dataset, avoiding further independence or decoupling assumptions. Both these favorable properties stem from the structure of the binary classification problem, as we can describe by examining the optimization problem constructed within the proof of Thm. 4 (Appendix C.1). In it, the constraints which do not explicitly appear with Lagrange parameters are all box, or L∞norm, constraints. These decouple over the n test examples, so the problem can be reduced to the one-dimensional optimization at the heart of Eq. (14), which is solved ad hoc. So we are able to obtain minimax results for these non-convex problems – the gi are “clipped” sigmoid functions because of the bounding effect of the [−1, 1] box constraints intrinsic to binary classification. We introduce Lagrange parameters σ only for the p remaining constraints in the problem, which do not decouple as above, applying globally over the n test examples. However, these constraints only depend on n as an average over examples (which is how they arise in dual form in Equation (16) of the proof), and the loss function itself is also an average (Equation (12)). This makes the box constraint decoupling possible, and leads to the favorable dependence on n, making an efficient solution possible to a potentially flagrantly non-convex problem. To summarize, the technique of optimizing only “halfway into” the dual allows us to readily manipulate the minimax problem exactly without using an approximation like weak duality, despite the lack of convexity in g. This technique was used implicitly for a different purpose in the “drifting game” analysis of boosting ([18], Sec. 13.4.1). Existing boosting work is loosely related to our approach in being a transductive game invoked to analyze ensemble aggregation, but it does not consider unlabeled data and draws its power instead from being a repeated game ([18]). The predecessor to this work ([1]) addresses a problem, 0-1 loss minimization, that is known to be NP-hard when solved directly ([11]). Using the unlabeled data is essential to surmounting this. It gives the dual problem an independently interesting interpretation, so the learning problem is on the always-convex Lagrange dual function and is therefore tractable. This paper’s transductive formulation involves no surrogates or relaxations of the loss, in sharp contrast to most previous work. This allows us to bypass the consistency and agnostic-learning discussions ([22, 3]) common to ERM methods that use convex risk minimization. Convergence analyses of those methods make heavy use of convexity of the losses and are generally done presupposing a linear weighting over H ([21]), whereas here such structure emerges directly from Lagrange duality and involves no convexity to derive the worst-case-optimal predictions. The conditions in Assumption 1 are notably general. Differentiability of the partial losses is convenient, but not necessary, and only used because first-order conditions are a convenient way to establish convexity of the potential well in Lemma 2. It is never used elsewhere, including in the minimax arguments used to prove Theorem 4. These manipulations are structured to be valid even if ℓ± are non-monotonic; but in this case, g∗ j could turn out to be multi-valued and hence not a genuine function of the example’s score. We emphasize that our result on the minimax equilibrium (Theorem 4) holds for general losses – the slack function may not be convex unless the further conditions of Lemma 2 are met, but 6 the interpretation of the optimum in terms of margins and sigmoid functions remains. All this emerges from the inherent decision-theoretic structure of the problem (the proof of Appendix C.1). It manifests in the fact that the function g(x⊤ j σ) is always increasing in x⊤ j σ for general losses, because the function Γ is increasing. This monotonicity typically needs to be assumed in a generalized linear model (GLM; [15]) and related settings. Γ appears loosely analogous to the link function used by GLMs, with its inverse being used for prediction. The optimal decision rules emerging from our framework are artificial neurons of the ensemble inputs. Helmbold et al. introduce the notion of a “matching loss” ([13]) for learning the parameters of a (fully supervised) artificial neuron with an arbitrary increasing transfer function, effectively taking the opposite tack of this paper in using a neuron’s transfer function to derive a loss to minimize in order to learn the neuron’s weights by convex optimization. Our assumptions on the loss, particularly condition (C) of Lemma 2, have arisen independently in earlier online learning work by some of the same authors ([12]); this may suggest connections between our techniques. We also note that our family of general losses was defined independently by [19] in the ERM setting (dubbed “F-losses”) – in which condition (C) of Lemma 2 also has significance ([19], Prop. 2) – but has seemingly not been revisited thereafter. Further fleshing out the above connections would be interesting future work. 3 Extensions We detail a number of generalizations to the basic prediction scenario of Sec. 2. These extensions are not mutually exclusive, and apply in conjunction with each other, but we list them separately for clarity. They illustrate the versatility of our minimax framework, particularly Sec. 3.4. 3.1 Weighted Test Sets and Covariate Shift Though our results here deal with binary classification of an unweighted test set, the formulation deals with a weighted set with only a slight modification of the slack function: Theorem 6. For any vector r ≥0n, min g∈[−1,1]n max z∈[−1,1]n, 1 n Fz≥b 1 n n X j=1 rjℓ(zj, gj) = 1 2 min σ≥0p −b⊤σ + 1 n n X j=1 rjΨ x⊤ j σ rj ! Writing σ∗ r as the minimizer of the RHS above, the optimal predictions g∗= g(σ∗ r), as in Theorem 4. Such weighted classification can be parlayed into algorithms for general supervised learning problems via learning reductions ([4]). Allowing weights on the test set for the evaluation is tantamount to accounting for known covariate shift in our setting; it would be interesting, though outside our scope, to investigate scenarios with more uncertainty. 3.2 General Loss Constraints on the Ensemble So far in the paper, we have considered the constraints on ensemble classifiers as derived from their label correlations (i.e. 0-1 losses), as in (3). However, this view can be extended significantly with the same analysis, because any general loss ℓ(z, g) is linear in z (Eq. (2)), which allows our development to go through essentially intact. In summary, a classifier can be incorporated into our framework for aggregation if we have a generalization loss bound on it, for any “general loss.” This permits an enormous variety of constraint sets, as each classifier considered can have constraints corresponding to any number of loss bounds on it, even multiple loss bounds using different losses. For instance, h1 can yield a constraint corresponding to a zero-one loss bound, h2 can yield one constraint corresponding to a square loss bound and another corresponding to a zero-one loss bound, and so on. Appendix B details this idea, extending Theorem 4 to general loss constraints. 3.3 Uniform Convergence Bounds for b In our basic setup, b has been taken as a lower bound on ensemble classifier label correlations. But as mentioned earlier, the error in estimating b is in fact often quantified by two-sided uniform 7 convergence (L∞) bounds on b. Constraining z in this fashion amounts to L1 regularization of the dual vector σ. Proposition 7. For any ϵ ≥0, min g∈[−1,1]n max z∈[−1,1]n, ∥1 n Fz−b∥∞≤ϵ ℓ(z, g) = min σ∈Rp −b⊤σ + 1 n n X j=1 Ψ(x⊤ j σ) + ϵ ∥σ∥1 As in Thm. 4, the optimal g∗= g(σ∗ ∞), where σ∗ ∞is the minimizer of the right-hand side above. Here we optimize over all vectors σ (not just nonnegative ones) in an L1-regularized problem, convenient in practice because we can cross-validate over the parameter ϵ. To our knowledge, this particular analysis has been addressed in prior work only for the special case of the entropy loss on the probability simplex, discussed further in [8]. Prop. 7 is a corollary of a more general result using differently scaled label correlation deviations within the ensemble, i.e. 1 nFz −b ≤c for a general c ≥0n. This turns out to be equivalent to regularizing the minimization over σ by its c-weighted L1 norm c⊤|σ| (Thm. 11), used to penalize the ensemble nonuniformly ([7]). This situation is motivated by uniform convergence of heterogeneous ensembles comprised of e.g. “specialist” predictors, for which a union bound ([5]) results in 1 nFz −b with varying coordinates. Such ensembles are discussed next. 3.4 Heterogenous Ensembles of Specialist Classifiers and Features All the results and algorithms in this paper apply in full generality to ensembles of “specialist” classifiers that only predict on some subset of the test examples. This is done by merely calculating the constraints over only these examples, and changing F and b accordingly ([2]). To summarize this from [2], suppose a classifier i ∈[p] decides to abstain on an example xj (j ∈[n]) with probability 1 −vi(x), and otherwise predict hi(x). Our only assumption on {vi(x1), . . . , vi(xn)} is the reasonable one that Pn j=1 vi(xj) > 0, so classifier i is not a useless specialist that abstains everywhere. The information about z contributed by classifier i is now not its overall correlation with z on the entire test set, but rather the correlation with z restricted to the test examples on which it predicts. On the test set, this is written as 1 nSz, where the matrix S is formed by reweighting each row of F: S := n ρ1(x1)h1(x1) ρ1(x2)h1(x2) · · · ρ1(xn)h1(xn) ρ2(x1)h2(x1) ρ2(x2)h2(x2) · · · ρ2(xn)h2(xn) ... ... ... ... ρp(x1)hp(x1) ρp(x2)hp(x2) · · · ρp(xn)hp(xn) , ρi(xj) := vi(xj) Pn k=1 vi(xk) (S = F when the entire ensemble consists of non-specialists, recovering our initial setup.) Therefore, the ensemble constraints (3) become 1 nSz ≥bS, where bS gives the label correlations of each classifier restricted to the examples on which it predicts. Though this rescaling results in entries of S having different ranges and magnitudes ≥1, our results and proofs remain entirely intact. Indeed, despite the title, this paper applies far more generally than to an ensemble of binary classifiers, because our proofs make no assumptions at all about the structure of F. Each predictor in the ensemble can be thought of as a feature; it has so far been convenient to think of it as binary, following the perspective of binary classifier aggregation, but it could as well be e.g. real-valued, and the features can have very different scales (as in S above). An unlabeled example x is simply a vector of features, so arbitrarily abstaining specialists are equivalent to “missing features,” which this framework handles seamlessly due to the given unlabeled data. Our development applies generally to semi-supervised binary classification. Acknowledgements AB is grateful to Chris “Ceej” Tosh for feedback that made the manuscript clearer. This work was supported by the NSF (grant IIS-1162581). 8 | 2016 | 522 |
6,464 | Dense Associative Memory for Pattern Recognition Dmitry Krotov Simons Center for Systems Biology Institute for Advanced Study Princeton, USA krotov@ias.edu John J. Hopfield Princeton Neuroscience Institute Princeton University Princeton, USA hopfield@princeton.edu Abstract A model of associative memory is studied, which stores and reliably retrieves many more patterns than the number of neurons in the network. We propose a simple duality between this dense associative memory and neural networks commonly used in deep learning. On the associative memory side of this duality, a family of models that smoothly interpolates between two limiting cases can be constructed. One limit is referred to as the feature-matching mode of pattern recognition, and the other one as the prototype regime. On the deep learning side of the duality, this family corresponds to feedforward neural networks with one hidden layer and various activation functions, which transmit the activities of the visible neurons to the hidden layer. This family of activation functions includes logistics, rectified linear units, and rectified polynomials of higher degrees. The proposed duality makes it possible to apply energy-based intuition from associative memory to analyze computational properties of neural networks with unusual activation functions – the higher rectified polynomials which until now have not been used in deep learning. The utility of the dense memories is illustrated for two test cases: the logical gate XOR and the recognition of handwritten digits from the MNIST data set. 1 Introduction Pattern recognition and models of associative memory [1] are closely related. Consider image classification as an example of pattern recognition. In this problem, the network is presented with an image and the task is to label the image. In the case of associative memory the network stores a set of memory vectors. In a typical query the network is presented with an incomplete pattern resembling, but not identical to, one of the stored memories and the task is to recover the full memory. Pixel intensities of the image can be combined together with the label of that image into one vector [2], which will serve as a memory for the associative memory. Then the image itself can be thought of as a partial memory cue. The task of identifying an appropriate label is a subpart of the associative memory reconstruction. There is a limitation in using this idea to do pattern recognition. The standard model of associative memory works well in the limit when the number of stored patterns is much smaller than the number of neurons [1], or equivalently the number of pixels in an image. In order to do pattern recognition with small error rate one would need to store many more memories than the typical number of pixels in the presented images. This is a serious problem. It can be solved by modifying the standard energy function of associative memory, quadratic in interactions between the neurons, by including in it higher order interactions. By properly designing the energy function (or Hamiltonian) for these models with higher order interactions one can store and reliably retrieve many more memories than the number of neurons in the network. Deep neural networks have proven to be useful for a broad range of problems in machine learning including image classification, speech recognition, object detection, etc. These models are composed of several layers of neurons, so that the output of one layer serves as the input to the next layer. Each 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. neuron calculates a weighted sum of the inputs and passes the result through a non-linear activation function. Traditionally, deep neural networks used activation functions such as hyperbolic tangents or logistics. Learning the weights in such networks, using a backpropagation algorithm, faced serious problems in the 1980s and 1990s. These issues were largely resolved by introducing unsupervised pre-training, which made it possible to initialize the weights in such a way that the subsequent backpropagation could only gently move boundaries between the classes without destroying the feature detectors [3, 4]. More recently, it was realized that the use of rectified linear units (ReLU) instead of the logistic functions speeds up learning and improves generalization [5, 6, 7]. Rectified linear functions are usually interpreted as firing rates of biological neurons. These rates are equal to zero if the input is below a certain threshold and linearly grow with the input if it is above the threshold. To mimic biology the output should be small or zero if the input is below the threshold, but it is much less clear what the behavior of the activation function should be for inputs exceeding the threshold. Should it grow linearly, sub-linearly, or faster than linearly? How does this choice affect the computational properties of the neural network? Are there other functions that would work even better than the rectified linear units? These questions to the best of our knowledge remain open. This paper examines these questions through the lens of associative memory. We start by discussing a family of models of associative memory with large capacity. These models use higher order (higher than quadratic) interactions between the neurons in the energy function. The associative memory description is then mapped onto a neural network with one hidden layer and an unusual activation function, related to the Hamiltonian. We show that by varying the power of interaction vertex in the energy function (or equivalently by changing the activation function of the neural network) one can force the model to learn representations of the data either in terms of features or in terms of prototypes. 2 Associative memory with large capacity The standard model of associative memory [1] uses a system of N binary neurons, with values ±1. A configuration of all the neurons is denoted by a vector σi. The model stores K memories, denoted by ⇠µ i , which for the moment are also assumed to be binary. The model is defined by an energy function, which is given by E = −1 2 N X i,j=1 σiTijσj, Tij = K X µ=1 ⇠µ i ⇠µ j , (1) and a dynamical update rule that decreases the energy at every update. The basic problem is the following: when presented with a new pattern the network should respond with a stored memory which most closely resembles the input. There has been a large amount of work in the community of statistical physicists investigating the capacity of this model, which is the maximal number of memories that the network can store and reliably retrieve. It has been demonstrated [1, 8, 9] that in case of random memories this maximal value is of the order of Kmax ⇡0.14N. If one tries to store more patterns, several neighboring memories in the configuration space will merge together producing a ground state of the Hamiltonian (1), which has nothing to do with any of the stored memories. By modifying the Hamiltonian (1) in a way that removes second order correlations between the stored memories, it is possible [10] to improve the capacity to Kmax = N. The mathematical reason why the model (1) gets confused when many memories are stored is that several memories produce contributions to the energy which are of the same order. In other words the energy decreases too slowly as the pattern approaches a memory in the configuration space. In order to take care of this problem, consider a modification of the standard energy E = − K X µ=1 F " ⇠µ i σi # (2) In this formula F(x) is some smooth function (summation over index i is assumed). The computational capabilities of the model will be illustrated for two cases. First, when F(x) = xn (n is an integer number), which is referred to as a polynomial energy function. Second, when F(x) is a 2 rectified polynomial energy function F(x) = ⇢xn, x ≥0 0, x < 0 (3) In the case of the polynomial function with n = 2 the network reduces to the standard model of associative memory [1]. If n > 2 each term in (2) becomes sharper compared to the n = 2 case, thus more memories can be packed into the same configuration space before cross-talk intervenes. Having defined the energy function one can derive an iterative update rule that leads to decrease of the energy. We use asynchronous updates flipping one unit at a time. The update rule is: σ(t+1) i = Sign K X µ=1 ✓ F ⇣ ⇠µ i + X j6=i ⇠µ j σ(t) j ⌘ −F ⇣ −⇠µ i + X j6=i ⇠µ j σ(t) j ⌘◆* , (4) The argument of the sign function is the difference of two energies. One, for the configuration with all but the i-th units clumped to their current states and the i-th unit in the “off” state. The other one for a similar configuration, but with the i-th unit in the “on” state. This rule means that the system updates a unit, given the states of the rest of the network, in such a way that the energy of the entire configuration decreases. For the case of polynomial energy function a very similar family of models was considered in [11, 12, 13, 14, 15, 16]. The update rule in those models was based on the induced magnetic fields, however, and not on the difference of energies. The two are slightly different due to the presence of self-coupling terms. Throughout this paper we use energy-based update rules. How many memories can model (4) store and reliably retrieve? Consider the case of random patterns, so that each element of the memories is equal to ±1 with equal probability. Imagine that the system is initialized in a state equal to one of the memories (pattern number µ). One can derive a stability criterion, i.e. the upper bound on the number of memories such that the network stays in that initial state. Define the energy difference between the initial state and the state with spin i flipped ∆E = K X ⌫=1 ⇣ ⇠⌫ i ⇠µ i + X j6=i ⇠⌫ j ⇠µ j ⌘n − K X ⌫=1 ⇣ −⇠⌫ i ⇠µ i + X j6=i ⇠⌫ j ⇠µ j ⌘n , where the polynomial energy function is used. This quantity has a mean h∆Ei = N n −(N −2)n ⇡ 2nN n−1, which comes from the term with ⌫= µ, and a variance (in the limit of large N) ⌃2 = ⌦n(K −1)N n−1, where ⌦n = 4n2(2n −3)!! The i-th bit becomes unstable when the magnitude of the fluctuation exceeds the energy gap h∆Ei and the sign of the fluctuation is opposite to the sign of the energy gap. Thus the probability that the state of a single neuron is unstable (in the limit when both N and K are large, so that the noise is effectively gaussian) is equal to Perror = 1 Z h∆Ei dx p 2⇡⌃2 e−x2 2⌃2 ⇡ r (2n −3)!! 2⇡ K N n−1 e− Nn−1 2K(2n−3)!! Requiring that this probability is less than a small value, say 0.5%, one can find the upper limit on the number of patterns that the network can store Kmax = ↵nN n−1, (5) where ↵n is a numerical constant, which depends on the (arbitrary) threshold 0.5%. The case n = 2 corresponds to the standard model of associative memory and gives the well known result K = 0.14N. For the perfect recovery of a memory (Perror < 1/N) one obtains Kmax no errors ⇡ 1 2(2n −3)!! N n−1 ln(N) (6) For higher powers n the capacity rapidly grows with N in a non-linear way, allowing the network to store and reliably retrieve many more patterns than the number of neurons that it has, in accord1 with [13, 14, 15, 16]. This non-linear scaling relationship between the capacity and the size of the network is the phenomenon that we exploit. 1The n-dependent coefficient in (6) depends on the exact form of the Hamiltonian and the update rule. References [13, 14, 15] do not allow repeated indices in the products over neurons in the energy function, therefore obtain a different coefficient. In [16] the Hamiltonian coincides with ours, but the update rule is different, which, however, results in exactly the same coefficient as in (6). 3 We study a family of models of this kind as a function of n. At small n many terms contribute to the sum over µ in (2) approximately equally. In the limit n ! 1 the dominant contribution to the sum comes from a single memory, which has the largest overlap with the input. It turns out that optimal computation occurs in the intermediate range. 3 The case of XOR The case of XOR is elementary, yet instructive. It is presented here for three reasons. First, it illustrates the construction (2) in this simplest case. Second, it shows that as n increases, the computational capabilities of the network also increase. Third, it provides the simplest example of a situation in which the number of memories is larger than the number of neurons, yet the network works reliably. The problem is the following: given two inputs x and y produce an output z such that the truth table x y z -1 -1 -1 -1 1 1 1 -1 1 1 1 -1 is satisfied. We will treat this task as an associative memory problem and will simply embed the four examples of the input-output triplets x, y, z in the memory. Therefore the network has N = 3 identical units: two of which will be used for the inputs and one for the output, and K = 4 memories ⇠µ i , which are the four lines of the truth table. Thus, the energy (2) is equal to En(x, y, z) = − " −x −y −z #n − " −x + y + z #n − " x −y + z #n − " x + y −z #n, (7) where the energy function is chosen to be a polynomial of degree n. For odd n, energy (7) is an odd function of each of its arguments, En(x, y, −z) = −En(x, y, z). For even n, it is an even function. For n = 1 it is equal to zero. Thus, if evaluated on the corners of the cube x, y, z = ±1, it reduces to En(x, y, z) = 8 < : 0, n = 1 Cn, n = 2, 4, 6, ... Cnxyz, n = 3, 5, 7, ..., (8) where coefficients Cn denote numerical constants. In order to solve the XOR problem one can present to the network an “incomplete pattern” of inputs (x, y) and let the output z adjust to minimize the energy of the three-spin configuration, while holding the inputs fixed. The network clearly cannot solve this problem for n = 1 and n = 2, since the energy does not depend on the spin configuration. The case n = 2 is the standard model of associative memory. It can also be thought of as a linear perceptron, and the inability to solve this problem represents the well known statement [17] that linear perceptrons cannot compute XOR without hidden neurons. The case of odd n ≥3 provides an interesting solution. Given two inputs, x and y, one can choose the output z that minimizes the energy. This leads to the update rule z = Sign ⇥ En(x, y, −1) −En(x, y, +1) ⇤ = Sign ⇥ −xy ⇤ Thus, in this simple case the network is capable of solving the problem for higher odd values of n, while it cannot do so for n = 1 and n = 2. In case of rectified polynomials, a similar construction solves the problem for any n ≥2. The network works well in spite of the fact that K > N. 4 An example of a pattern recognition problem, the case of MNIST The MNIST data set is a collection of handwritten digits, which has 60000 training examples and 10000 test images. The goal is to classify the digits into 10 classes. The visible neurons, one for each pixel, are combined together with 10 classification neurons in one vector that defines the state of the network. The visible part of this vector is treated as an “incomplete” pattern and the associative memory is allowed to calculate a completion of that pattern, which is the label of the image. Dense associative memory (2) is a recurrent network in which every neuron can be updated multiple times. For the purposes of digit classification, however, this model will be used in a very limited 4 capacity, allowing it to perform only one update of the classification neurons. The network is initialized in the state when the visible units vi are clamped to the intensities of a given image and the classification neurons are in the off state x↵= −1 (see Fig.1A). The network is allowed to make one update of the classification neurons, while keeping the visible units clamped, to produce the output c↵. The update rule is similar to (4) except that the sign is replaced by the continuous function g(x) = tanh(x) c↵= g β K X µ=1 ✓ F ⇣ −⇠µ ↵x↵+ X γ6=↵ ⇠µ γ xγ + N X i=1 ⇠µ i vi ⌘ −F ⇣ ⇠µ ↵x↵+ X γ6=↵ ⇠µ γ xγ + N X i=1 ⇠µ i vi ⌘◆* , (9) where parameter β regulates the slope of g(x). The proposed digit class is given by the number of a classification neuron producing the maximal output. Throughout this section the rectified polynomials (3) are used as functions F. To learn effective memories for use in pattern classification, an objective function is defined (see Appendix A in Supplemental), which penalizes the discrepancy A B vi c↵ vi x↵ 0 500 1000 1500 2000 2500 3000 1.4 1.5 1.6 1.7 1.8 1.9 2 error, test set Epochs number of epochs number of epochs test error, % test error, % 0 500 1000 1500 2000 2500 3000 1.4 1.5 1.6 1.7 1.8 1.9 2 error, test set Epochs 158-262 epochs n = 3 n = 2 179-312 epochs Figure 1: (A) The network has N = 28 ⇥28 = 784 visible neurons and Nc = 10 classification neurons. The visible units are clamped to intensities of pixels (which is mapped on the segment [−1, 1]), while the classification neurons are initialized in the state x↵and then updated once to the state c↵. (B) Behavior of the error on the test set as training progresses. Each curve corresponds to a different combination of hyperparameters from the optimal window, which was determined on the validation set. The arrows show the first time when the error falls below a 2% threshold. All models have K = 2000 memories (hidden units). between the output c↵and the target output. This objective function is then minimized using a backpropagation algorithm. The learning starts with random memories drawn from a Gaussian distribution. The backpropagation algorithm then finds a collection of K memories ⇠µ i,↵, which minimize the classification error on the training set. The memories are normalized to stay within the −1 ⇠µ i,↵1 range, absorbing their overall scale into the definition of the parameter β. The performance of the proposed classification framework is studied as a function of the power n. The next section shows that a rectified polynomial of power n in the energy function is equivalent to the rectified polynomial of power n −1 used as an activation function in a feedforward neural network with one hidden layer of neurons. Currently, the most common choice of activation functions for training deep neural networks is the ReLU, which in our language corresponds to n = 2 for the energy function. Although not currently used to train deep networks, the case n = 3 would correspond to a rectified parabola as an activation function. We start by comparing the performances of the dense memories in these two cases. The performance of the network depends on n and on the remaining hyperparameters, thus the hyperparameters should be optimized for each value of n. In order to test the variability of performances for various choices of hyperparameters at a given n, a window of hyperparameters for which the network works well on the validation set (see the Appendix A in Supplemental) was determined. Then many networks were trained for various choices of the hyperparameters from this window to evaluate the performance on the test set. The test errors as training progresses are shown in Fig.1B. While there is substantial variability among these samples, on average the cluster of trajectories for n = 3 achieves better results on the test set than that for n = 2. These error rates should be compared with error rates for backpropagation alone without the use of generative pretraining, various kinds of regularizations (for example dropout) or adversarial training, all of which could be added to our construction if necessary. In this class of models the best published results are all2 in the 1.6% range [18], see also controls in [19, 20]. This agrees with our results for n = 2. The n = 3 case does slightly better than that as is clear from Fig.1B, with all the samples performing better than 1.6%. 2Although there are better results on pixel permutation invariant task, see for example [19, 20, 21, 22]. 5 Higher rectified polynomials are also faster in training compared to ReLU. For the n = 2 case, the error crosses the 2% threshold for the first time during training in the range of 179-312 epochs. For the n = 3 case, this happens earlier on average, between 158-262 epochs. For higher powers n this speed-up is larger. This is not a huge effect for a small dataset such as MNIST. However, this speed-up might be very helpful for training large networks on large datasets, such as ImageNet. A similar effect was reported earlier for the transition between saturating units, such as logistics or hyperbolic tangents, to ReLU [7]. In our family of models that result corresponds to moving from n = 1 to n = 2. Feature to prototype transition How does the computation performed by the neural network change as n varies? There are two extreme classes of theories of pattern recognition: feature-matching and formation of a prototype. According to the former, an input is decomposed into a set of features, which are compared with those stored in the memory. The subset of the stored features activated by the presented input is then interpreted as an object. One object has many features; features can also appear in more than one object. The prototype theory provides an alternative approach, in which objects are recognized as a whole. The prototypes do not necessarily match the object exactly, but rather are blurred abstract 64 128 192 256 64 128 192 256 64 128 192 256 64 128 192 256 0 1 2 3 4 5 6 7 8 9 10 0 10 20 30 40 50 percent of active memories number of strongly positively driven RU n=2 n=3 n=20 n=30 1 2 3 4 5 6 7 8 9 10 11 12 0 2000 4000 6000 8000 10000 number of test images number of memories strongly contributing to the correct RU n=2 n=3 n=20 n=30 64 128 192 256 number of RU with ⇠µ ↵> 0.99 number of memories making the decision percent of memories, % number of test images −1 −0.5 0.5 0 1 n = 2 n = 3 n = 20 n = 30 errortest = 1.51% errortest = 1.44% errortest = 1.61% errortest = 1.80% Figure 2: We show 25 randomly selected memories (feature detectors) for four networks, which use rectified polynomials of degrees n = 2, 3, 20, 30 as the energy function. The magnitude of a memory element corresponding to each pixel is plotted in the location of that pixel, the color bar explains the color code. The histograms at the bottom are explained in the text. The error rates refer to the particular four samples used in this figure. RU stands for recognition unit. representations which include all the features that an object has. We argue that the computational models proposed here describe feature-matching mode of pattern recognition for small n and the prototype regime for large n. This can be anticipated from the sharpness of contributions that each memory makes to the total energy (2). For large n the function F(x) peaks much more sharply around each memory compared to the case of small n. Thus, at large n all the information about a digit must be written in only one memory, while at small n this information can be distributed among several memories. In the case of intermediate n some learned memories behave like features while others behave like prototypes. These two classes of memories work together to model the data in an efficient way. The feature to prototype transition is clearly seen in memories shown in Fig.2. For n = 2 or 3 each memory does not look like a digit, but resembles a pattern of activity that might be useful for recognizing several different digits. For n = 20 many of the memories can be recognized as digits, which are surrounded by white margins representing elements of memories having approximately zero values. These margins describe the variability of thicknesses of lines of different training examples and mathematically mean that the energy (2) does not depend on whether the corresponding pixel is on or off. For n = 30 most of the memories represent prototypes of whole digits or large portions of digits, with a small admixture of feature memories that do not resemble any digit. 6 The feature to prototype transition can be visualized by showing the feature detectors in situations when there is a natural ordering of pixels. Such ordering exists in images, for example. In general situations, however, there is no preferred permutation of visible neurons that would reveal this structure (e.g. in the case of genomic data). It is therefore useful to develop a measure that permits a distinction to be made between features and prototypes in the absence of such visual space. Towards the end of training most of the recognition connections ⇠µ ↵are approximately equal to ±1. One can choose an arbitrary cutoff, and count the number of recognition connections that are in the “on” state (⇠µ ↵= +1) for each memory. The distribution function of this number is shown on the left histogram in Fig.2. Intuitively, this quantity corresponds to the number of different digit classes that a particular memory votes for. At small n, most of the memories vote for three to five different digit classes, a behavior characteristic of features. As n increases, each memory specializes and votes for only a single class. In the case n = 30, for example, more than 40% of memories vote for only one class, a behavior characteristic of prototypes. A second way to see the feature to prototype transition is to look at the number of memories which make large contributions to the classification decision (right histogram in Fig.2). For each test image one can find the memory that makes the largest contribution to the energy gap, which is the sum over µ in (9). Then one can count the number of memories that contribute to the gap by more than 0.9 of this largest contribution. For small n, there are many memories that satisfy this criterion and the distribution function has a long tail. In this regime several memories are cooperating with each other to make a classification decision. For n = 30, however, more than 8000 of 10000 test images do not have a single other memory that would make a contribution comparable with the largest one. This result is not sensitive to the arbitrary choice (0.9) of the cutoff. Interestingly, the performance remains competitive even for very large n ⇡20 (see Fig.2) in spite of the fact that these networks are doing a very different kind of computation compared with that at small n. 5 Relationship to a neural network with one hidden layer In this section we derive a simple duality between the dense associative memory and a feedforward neural network with one layer of hidden neurons. In other words, we show that the same computational model has two very different descriptions: one in terms of associative memory, the other one in terms vi c↵ vi vi c↵ f g hµ x↵= −" Figure 3: On the left a feedforward neural network with one layer of hidden neurons. The states of the visible units are transformed to the hidden neurons using a non-linear function f, the states of the hidden units are transformed to the output layer using a non-linear function g. On the right the model of dense associative memory with one step update (9). The two models are equivalent. of a network with one layer of hidden units. Using this correspondence one can transform the family of dense memories, constructed for different values of power n, to the language of models used in deep learning. The resulting neural networks are guaranteed to inherit computational properties of the dense memories such as the feature to prototype transition. The construction is very similar to (9), except that the classification neurons are initialized in the state when all of them are equal to −", see Fig.3. In the limit " ! 0 one can expand the function F in (9) so that the dominant contribution comes from the term linear in ". Then c↵⇡g h β K X µ=1 F 0⇣N X i=1 ⇠µ i vi ⌘ (−2⇠µ ↵x↵) i = g h K X µ=1 ⇠µ ↵F 0" ⇠µ i vi #i = g h K X µ=1 ⇠µ ↵f " ⇠µ i vi #i , (10) where the parameter β is set to β = 1/(2") (summation over the visible index i is assumed). Thus, the model of associative memory with one step update is equivalent to a conventional feedforward neural network with one hidden layer provided that the activation function from the visible layer to the hidden layer is equal to the derivative of the energy function f(x) = F 0(x) (11) 7 The visible part of each memory serves as an incoming weight to the hidden layer, and the recognition part of the memory serves as an outgoing weight from the hidden layer. The expansion used in (10) is justified by a condition N P i=1 ⇠µ i vi ≫ Nc P ↵=1 ⇠µ ↵x↵, which is satisfied for most common problems, and is simply a statement that labels contain far less information than the data itself3. From the point of view of associative memory, the dominant contribution shaping the basins of attraction comes from the low energy states. Therefore mathematically it is determined by the asymptotics of the activation function f(x), or the energy function F(x), at x ! 1. Thus different activation functions having similar asymptotics at x ! 1 should fall into the same universality class and should have similar computational properties. In the table below we list some common activation activation function energy function n f(x) = tanh(x) F(x) = ln " cosh(x) # ⇡x, at x ! 1 1 f(x) = logistic function F(x) = ln " 1 + ex# ⇡x, at x ! 1 1 f(x) =ReLU F(x) ⇠x2, at x ! 1 2 f(x) = RePn−1 F(x) = RePn n functions used in models of deep learning, their associative memory counterparts and the power n which determines the asymptotic behavior of the energy function at x ! 1.The results of section 4 suggest that for not too large n the speed of learning should improve as n increases. This is consistent with the previous observation that ReLU are faster in training than hyperbolic tangents and logistics [5, 6, 7]. The last row of the table corresponds to rectified polynomials of higher degrees. To the best of our knowledge these activation functions have not been used in neural networks. Our results suggest that for some problems these higher power activation functions should have even better computational properties than the rectified liner units. 6 Discussion and conclusions What is the relationship between the capacity of the dense associative memory, calculated in section 2, and the neural network with one step update that is used for digit classification? Consider the limit of very large β in (9), so that the hyperbolic tangent is approximately equal to the sign function, as in (4). In the limit of sufficiently large n the network is operating in the prototype regime. The presented image places the initial state of the network close to a local minimum of energy, which corresponds to one of the prototypes. In most cases the one step update of the classification neurons is sufficient to bring this initial state to the nearest local minimum, thus completing the memory recovery. This is true, however, only if the stored patterns are stable and have basins of attraction around them of at least the size of one neuron flip, which is exactly (in the case of random patterns) the condition given by (6). For correlated patterns the maximal number of stored memories might be different from (6), however it still rapidly increases with increase of n. The associative memory with one step update (or the feedforward neural network) is exactly equivalent to the full associative memory with multiple updates in this limit. The calculation with random patterns thus theoretically justifies the expectation of a good performance in the prototype regime. To summarize, this paper contains three main results. First, it is shown how to use the general framework of associative memory for pattern recognition. Second, a family of models is constructed that can learn representations of the data in terms of features or in terms of prototypes, and that smoothly interpolates between these two extreme regimes by varying the power of interaction vertex. Third, there exists a simple duality between a one step update version of the associative memory model and a feedforward neural network with one layer of hidden units and an unusual activation function. This duality makes it possible to propose a class of activation functions that encourages the network to learn representations of the data with various proportions of features and prototypes. These activation functions can be used in models of deep learning and should be more effective than the standard choices. They allow the networks to train faster. We have also observed an improvement of generalization ability in networks trained with the rectified parabola activation function compared to the ReLU for the case of MNIST. While these ideas were illustrated using the simplest architecture of the neural network with one layer of hidden units, the proposed activation functions can also be used in multilayer architectures. We did not study various regularizations (weight decay, dropout, etc), which can be added to our construction. The performance of the model supplemented with these regularizations, as well as performance on other common benchmarks, will be reported elsewhere. 3A relationshp similar to (11) was discussed in [23, 24] in the context of autoencoders. 8 References [1] Hopfield, J.J., 1982. Neural networks and physical systems with emergent collective computational abilities. Proceedings of the national academy of sciences, 79(8), pp.2554-2558. [2] LeCun, Y., Chopra, S., Hadsell, R., Ranzato, M. and Huang, F., 2006. A tutorial on energy-based learning. Predicting structured data, 1, p.0. [3] Hinton, G.E., Osindero, S. and Teh, Y.W., 2006. A fast learning algorithm for deep belief nets. Neural computation, 18(7), pp.1527-1554. [4] Hinton, G.E. and Salakhutdinov, R.R., 2006. Reducing the dimensionality of data with neural networks. Science, 313(5786), pp.504-507. [5] Nair, V. and Hinton, G.E., 2010. Rectified linear units improve restricted boltzmann machines. In Proceedings of the 27th International Conference on Machine Learning (ICML-10) (pp. 807-814). [6] Glorot, X., Bordes, A. and Bengio, Y., 2011. Deep sparse rectifier neural networks. In International Conference on Artificial Intelligence and Statistics (pp. 315-323). [7] Krizhevsky, A., Sutskever, I. and Hinton, G.E., 2012. ImageNet classification with deep convolutional neural networks. In Advances in neural information processing systems (pp. 1097-1105). [8] Amit, D.J., Gutfreund, H. and Sompolinsky, H., 1985. Storing infinite numbers of patterns in a spin-glass model of neural networks. Physical Review Letters, 55(14), p.1530. [9] McEliece, R.J., Posner, E.C., Rodemich, E.R. and Venkatesh, S.S., 1987. The capacity of the Hopfield associative memory. Information Theory, IEEE Transactions on, 33(4), pp.461-482. [10] Kanter, I. and Sompolinsky, H., 1987. Associative recall of memory without errors. Physical Review A, 35(1), p.380. [11] Chen, H.H., Lee, Y.C., Sun, G.Z., Lee, H.Y., Maxwell, T. and Giles, C.L., 1986. High order correlation model for associative memory. In Neural Networks for Computing (Vol. 151, No. 1, pp. 86-99). AIP Publishing. [12] Psaltis, D. and Park, C.H., 1986. Nonlinear discriminant functions and associative memories. In Neural networks for computing (Vol. 151, No. 1, pp. 370-375). AIP Publishing. [13] Baldi, P. and Venkatesh, S.S., 1987. Number of stable points for spin-glasses and neural networks of higher orders. Physical Review Letters, 58(9), p.913. [14] Gardner, E., 1987. Multiconnected neural network models. Journal of Physics A: Mathematical and General, 20(11), p.3453. [15] Abbott, L.F. and Arian, Y., 1987. Storage capacity of generalized networks. Physical Review A, 36(10), p.5091. [16] Horn, D. and Usher, M., 1988. Capacities of multiconnected memory models. Journal de Physique, 49(3), pp.389-395. [17] Minsky, M. and Papert, S., 1969. Perceptron: an introduction to computational geometry. The MIT Press, Cambridge, expanded edition, 19(88), p.2. [18] Simard, P.Y., Steinkraus, D. and Platt, J.C., 2003, August. Best practices for convolutional neural networks applied to visual document analysis. In null (p. 958). IEEE. [19] Srivastava, N., Hinton, G., Krizhevsky, A., Sutskever, I. and Salakhutdinov, R., 2014. Dropout: A simple way to prevent neural networks from overfitting. The Journal of Machine Learning Research, 15(1), pp.1929-1958. [20] Wan, L., Zeiler, M., Zhang, S., LeCun, Y. and Fergus, R., 2013. Regularization of neural networks using dropconnect. In Proceedings of the 30th International Conference on Machine Learning (ICML-13) (pp. 1058-1066). [21] Goodfellow, I.J., Shlens, J. and Szegedy, C., 2014. Explaining and harnessing adversarial examples. arXiv preprint arXiv:1412.6572. [22] Rasmus, A., Berglund, M., Honkala, M., Valpola, H. and Raiko, T., 2015. Semi-supervised learning with ladder networks. In Advances in Neural Information Processing Systems (pp. 3546-3554). [23] Kamyshanska, H. and Memisevic, R., 2013, April. On autoencoder scoring. In ICML (3) (pp. 720-728). [24] Kamyshanska, H. and Memisevic, R., 2015. The potential energy of an autoencoder. IEEE transactions on pattern analysis and machine intelligence, 37(6), pp.1261-1273. 9 | 2016 | 523 |
6,465 | Fairness in Learning: Classic and Contextual Bandits ∗ Matthew Joseph Michael Kearns Jamie Morgenstern Aaron Roth University of Pennsylvania, Department of Computer and Information Science majos, mkearns, jamiemor, aaroth@cis.upenn.edu Abstract We introduce the study of fairness in multi-armed bandit problems. Our fairness definition demands that, given a pool of applicants, a worse applicant is never favored over a better one, despite a learning algorithm’s uncertainty over the true payoffs. In the classic stochastic bandits problem we provide a provably fair algorithm based on “chained” confidence intervals, and prove a cumulative regret bound with a cubic dependence on the number of arms. We further show that any fair algorithm must have such a dependence, providing a strong separation between fair and unfair learning that extends to the general contextual case. In the general contextual case, we prove a tight connection between fairness and the KWIK (Knows What It Knows) learning model: a KWIK algorithm for a class of functions can be transformed into a provably fair contextual bandit algorithm and vice versa. This tight connection allows us to provide a provably fair algorithm for the linear contextual bandit problem with a polynomial dependence on the dimension, and to show (for a different class of functions) a worst-case exponential gap in regret between fair and non-fair learning algorithms. 1 Introduction Automated techniques from statistics and machine learning are increasingly being used to make decisions that have important consequences on people’s lives, including hiring [24], lending [10], policing [25], and even criminal sentencing [7]. These high stakes uses of machine learning have led to increasing concern in law and policy circles about the potential for (often opaque) machine learning techniques to be discriminatory or unfair [13, 6]. At the same time, despite the recognized importance of this problem, very little is known about technical solutions to the problem of “unfairness”, or the extent to which “fairness” is in conflict with the goals of learning. In this paper, we consider the extent to which a natural fairness notion is compatible with learning in a bandit setting, which models many of the applications of machine learning mentioned above. In this setting, the learner is a sequential decision maker, which must choose at each time step t which decision to make from a finite set of k “arms". The learner then observes a stochastic reward from (only) the arm chosen, and is tasked with maximizing total earned reward (equivalently, minimizing total regret) by learning the relationships between arms and rewards over time. This models, for example, the problem of learning the association between loan applicants and repayment rates over time by repeatedly granting loans and observing repayment. We analyze two variants of the setting: in the classic case, the learner’s only source of information comes from choices made in previous rounds. In the contextual case, before each round the learner additionally observes some potentially informative context for each arm (for example representing the content of an individual’s loan application), and the expected reward is some unknown function of ∗A full technical version of this paper is available on arXiv [17]. 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. the context. The difficulty in this task stems from the unknown relationships between arms, rewards, and (in the contextual case) contexts: these relationships must be learned. We introduce fairness into the bandit learning framework by saying that it is unfair to preferentially choose one arm over another if the chosen arm has lower expected quality than the unchosen arm. In the loan application example, this means that it is unfair to preferentially choose a less-qualified applicant (in terms of repayment probability) over a more-qualified applicant. It is worth noting that this definition of fairness (formalized in the preliminaries) is entirely consistent with the optimal policy, which can simply choose at each round to play uniformly at random from the arms maximizing the expected reward. This is because – it seems – this definition of fairness is entirely consistent with the goal of maximizing expected reward. Indeed, the fairness constraint exactly states that the algorithm cannot favor low reward arms! Our main conceptual result is that this intuition is incorrect in the face of unknown reward functions. Although fairness is consistent with implementing the optimal policy, it may not be consistent with learning the optimal policy. We show that fairness always has a cost, in terms of the achievable learning rate of the algorithm. For some problems, the cost is mild, but for others, the cost is large. 1.1 Our Results We divide our results into two parts. First, in Section 3 we study the classic stochastic multi-armed bandit problem [20, 19]. In this case, there are no contexts, and each arm i has a fixed but unknown average reward µi. In Section 3.1 we give a fair algorithm, FAIRBANDITS, and show that it guarantees nontrivial regret after T = O(k3) rounds. We then show in Section 3.2 that it is not possible to do better – any fair learning algorithm can be forced to endure constant per-round regret for T = Ω(k3) rounds, thus tightly characterizing the optimal regret attainable by fair algorithms in this setting, and formally separating it from the regret attainable by algorithms absent a fairness constraint. We then move on to the general contextual bandit setting in Section 4 and prove a broad characterization result, relating fair contextual bandit learning to KWIK (“Knows What It Knows") learning [22]. Informally, a KWIK leaarning algorithm receives a series of unlabeled examples and must either predict a label or announce “I Don’t Know". The KWIK requirement then stipulates that any predicted must be label close to its true label. The quality of a KWIK learning algorithm is characterized by its “KWIK bound”, which provides an upper bound on the maximum number of times the algorithm can be forced to announce “I Don’t Know”. For any contextual bandit problem (defined by the set of functions C from which the payoff functions may be selected), we show that the optimal learning rate of any fair algorithm is determined by the best KWIK bound for the class C. We prove this constructively via a reduction showing how to convert a KWIK learning algorithm into a fair contextual bandit algorithm in Section 4.1, and vice versa in Section 4.2. This general connection immediately allows us to import known results for KWIK learning [22]. It implies that some fair contextual bandit problems are easy and achieve non-trivial regret guarantees in only polynomial many rounds. Conversely, it also implies that some contextual bandit problems which are easy without the fairness constraint become hard once we impose the fairness constraint, in that any fair algorithm must suffer constant per-round regret for exponentially many rounds. By way of example, we will show in Section 4.1 that real contexts with linear reward functions are easy, and we will show in Section 4.3 that boolean context vectors and conjunction reward functions are hard. 1.2 Other Related Work Many papers study the problem of fairness in machine learning. One line of work studies algorithms for batch classification which achieve group fairness otherwise known as equality of outcomes, statistical parity – or algorithms that avoid disparate impact (see e.g. [11, 23, 18, 15, 16] and [2] for a study of auditing existing algorithms for disparate impact). While statistical parity is sometimes a desirable or legally required goal, as observed by Dwork et al. [14] and others, it suffers from a number of drawbacks. First, if different populations indeed have different statistical properties, then it can be at odds with accurate classification. Second, even in cases when statistical parity is attainable with an optimal classifier, it does not prevent discrimination at an individual level. This led Dwork et al. [14] to encourage the study of individual fairness, which we focus on here. 2 Dwork et al. [14] also proposed and explored a technical definition of individual fairness formalizing the idea that “similar individuals should be treated similarly” by presupposing a task-specific quality metric on individuals and proposing that fair algorithms should satisfy a Lipschitz condition on this metric. Our definition of fairness is similar, in that the expected reward of each arm is a natural metric through which we define fairness. However, where Dwork et al. [14] presupposes the existence of a “fair" metric on individuals – thus encoding much of the relevant challenge, as studied Zemel et al. [27] – our notion of fairness is entirely aligned with the goal of the algorithm designer and is satisfied by the optimal policy. Nevertheless, it affects the space of feasible learning algorithms, because it interferes with learning an optimal policy, which depends on the unknown reward functions. At a technical level, our work is related to Amin et al. [4] and Abernethy et al. [1], which also relate KWIK learning to bandit learning in a different context unrelated to fairness. 2 Preliminaries We study the contextual bandit setting, defined by a domain X, a set of “arms” [k] := {1, . . . , k} and a class C of functions of the form f : X →[0, 1]. For each arm j there is some function fj ∈C, unknown to the learner. In rounds t = 1, . . . , T, an adversary reveals to the algorithm a context xt j for each arm2. An algorithm A then chooses an arm it, and observes stochastic reward rt it for the arm it chose. We assume rt j ∼Dt j, E[rt j] = fj(xt j), for some distribution Dt j over [0, 1]. Let Π be the set of policies mapping contexts to distributions over arms Xk →∆k, and π∗the optimal policy which selects a distribution over arms as a function of contexts to maximize the expected reward of those arms. The pseudo-regret of an algorithm A on contexts x1, . . . , xT is defined as follows, where πt represents A’s distribution on arms at round t: X t Eit∗∼π∗(xt)[fit∗(xt it∗)] −Eit∼πt[ X t fit(xt it)] = Regret(x1, . . . , xT ), shorthanded as A’s regret. Optimal policy π∗pulls arms with highest expectation at each round, so: Regret(x1, . . . , xT ) = X t max j fj(xt j) −Eit∼πt[ X t fit(xt it)]. We say that A satisfies regret bound R(T) if maxx1,...,xT Regret(x1, . . . , xt) ≤R(T). Let the history ht ∈ X k × [k] × [0, 1] t−1 be a record of t −1 rounds experienced by A, t −1 3-tuples encoding the realization of the contexts, arm chosen, and reward observed. πt j|ht denotes the probability that A chooses arm j after observing contexts xt, given ht. For simplicity, we will often drop the superscript t on the history when referring to the distribution over arms: πt j|h := πt j|ht. We now define what it means for a contextual bandit algorithm to be δ-fair with respect to its arms. Informally, this will mean that A will play arm i with higher probability than arm j in round t only if i has higher mean than j in round t, for all i, j ∈[k], and in all rounds t. Definition 1 (δ-fair). A is δ-fair if, for all sequences of contexts x1, . . . , xt and all payoff distributions Dt 1, . . . , Dt k, with probability at least 1 −δ over the realization of the history h, for all rounds t ∈[T] and all pairs of arms j, j′ ∈[k], πt j|h > πt j′|h only if fj(xt j) > fj′(xt j′). KWIK learning Let B be an algorithm which takes as input a sequence of examples x1, . . . , xT , and when given some xt ∈X, outputs either a prediction ˆyt ∈[0, 1] or else outputs ˆyt = ⊥, representing “I don’t know”. When ˆyt = ⊥, B receives feedback yt such that E[yt] = f(xt). B is an (ϵ, δ)-KWIK learning algorithm for C : X →[0, 1], with KWIK bound m(ϵ, δ) if for any sequence of examples x1, x2, . . . and any target f ∈C, with probability at least 1 −δ, both: 1. Its numerical predictions are accurate: for all t, ˆyt ∈{⊥} ∪[f(xt) −ϵ, f(xt) + ϵ], and 2. B rarely outputs “I Don’t Know”: P∞ t=1 I [ˆyt = ⊥] ≤m(ϵ, δ). 2Often, the contextual bandit problem is defined such that there is a single context xt every day. Our model is equivalent – we could take xt j := xt for each j. 3 2.1 Specializing to Classic Stochastic Bandits In Sections 3.1 and 3.2, we study the classic stochastic bandit problem, an important special case of the contextual bandit setting described above. Here we specialize our notation to this setting, in which there are no contexts. For each arm j ∈[k], there is an unknown distribution Dj over [0, 1] with unknown mean µj. A learning algorithm A chooses an arm it in round t, and observes the reward rt it ∼Dit for the arm that it chose. Let i∗∈[k] be the arm with highest expected reward: i∗∈arg maxi∈[k] µi. The pseudo-regret of an algorithm A on D1, . . . , Dk is now just: T · µi∗−Eit∼πt[ X 0≤t≤T µit] = Regret(T, D1, . . . , Dk) Let ht ∈([k] × [0, 1])t−1 denote a record of the t −1 rounds experienced by the algorithm so far, represented by t −1 2-tuples encoding the previous arms chosen and rewards observed. We write πt j|ht to denote the probability that A chooses arm j given history ht. Again, we will often drop the superscript t on the history when referring to the distribution over arms: πt j|h := πt j|ht. δ-fairness in the classic bandit setting then specializes as follows: Definition 2 (δ-fairness in the classic bandits setting). A is δ-fair if, for all distributions D1, . . . , Dk, with probability at least 1 −δ over the history h, for all t ∈[T] and all j, j′ ∈[k]: πt j|h > πt j′|h only if µj > µj′. 3 Classic Bandits Setting 3.1 Fair Classic Stochastic Bandits: An Algorithm In this section, we describe a simple and intuitive modification of the standard UCB algorithm [5], called FAIRBANDITS, prove that it is fair, and analyze its regret bound. The algorithm and its analysis highlight a key idea that is important to the design of fair algorithms in this setting: that of chaining confidence intervals. Intuitively, as a δ-fair algorithm explores different arms it must play two arms j1 and j2 with equal probability until it has sufficient data to deduce, with confidence 1 −δ, either that µj1 > µj2 or vice versa. FAIRBANDITS does this by maintaining empirical estimates of the means of both arms, together with confidence intervals around those means. To be safe, the algorithm must play the arms with equal probability while their confidence intervals overlap. The same reasoning applies simultaneously to every pair of arms. Thus, if the confidence intervals of each pair of arms ji and ji+1 overlap for each i ∈[k], the algorithm is forced to play all arms j with equal probability. This is the case even if the confidence intervals around arm jk and arm j1 are far from overlapping – i.e. when the algorithm can be confident that µj1 > µjk. This chaining approach initially seems overly conservative when ruling out arms, as reflected in its regret bound, which is only non-trivial after T ≫k3. In contrast, the UCB algorithm [5] achieves non-trivial regret after T = O(k) rounds. However, our lower bound in Section 3.2 shows that any fair algorithm must suffer constant per-round regret for T ≫k3 rounds on some instances. We now give an overview of the behavior of FAIRBANDITS. At every round t, FAIRBANDITS identifies the arm it ∗= arg maxi ut i that has the largest upper confidence interval amongst the active arms. At each round t, we say i is linked to j if [ℓt i, ut i] ∩[ℓt j, ut j] ̸= ∅, and i is chained to j if i and j are in the same component of the transitive closure of the linked relation. FAIRBANDITS plays uniformly at random among all active arms chained to arm it ∗. Initially, the active set contains all arms. The active set of arms at each subsequent round is defined to be the set of arms that are chained to the arm with highest upper confidence bound at the previous round. The algorithm can be confident that arms that have become unchained to the arm with the highest upper confidence bound at any round have means that are lower than the means of any chained arms, and hence such arms can be safely removed from the active set, never to be played again. This has the useful property that the active set of arms can only shrink: at any round t, St ⊆St−1. We first observe that with probability 1 −δ, all of the confidence intervals maintained by FAIRBANDITS (δ) contain the true means of their respective arms over all rounds. We prove this claim, along with all other claims in this paper, in the full technical version of this paper [17]. 4 1: procedure FAIRBANDITS(δ) 2: S0 ←{1, . . . , k} ▷Initialize the active set 3: for i = 1, . . . k do 4: ˆµ0 i ←1 2, u0 i ←1, ℓ0 i ←0, n0 i ←0 ▷Initialize each arm 5: for t = 1 to T do 6: it ∗←arg maxi∈St−1 ut i ▷Find arm with highest ucb 7: St ←{j | j chains to it ∗, j ∈St−1} ▷Update active set 8: j∗←(x ∈R St) ▷Select active arm at random 9: nt+1 j∗ ←nt j∗+ 1 10: ˆµt+1 j∗ ← 1 nt+1 j∗(ˆµt j∗· nt j∗+ rt j∗) ▷Pull arm j∗, update its mean estimate 11: B ← r ln((π·(t+1))2/3δ) 2nt+1 j∗ 12: ℓt+1 j∗, ut+1 j∗ ← ˆµt+1 j∗ −B, ˆµt+1 j∗ + B ▷Update interval for pulled arm 13: for j ∈St, j ̸= j∗do 14: ˆµt+1 j ←ˆµt j, nt+1 j ←nt j, ut+1 j ←ut j, ℓt+1 j ←ℓt j Lemma 1. With probability at least 1 −δ, for every arm i and round t ℓt i ≤µi ≤ut i. The fairness of FAIRBANDITS follows: with high probability the algorithm constructs good confidence intervals, so it can confidently choose between arms without violating fairness. Theorem 1. FAIRBANDITS (δ) is δ-fair. Having proven that FAIRBANDITS is indeed fair, it remains to upper-bound its regret. We proceed by a series of lemmas, first lower bounding the probability that any arm active in round t has been pulled substantially fewer times than its expectation. Lemma 2. With probability at least 1 − δ 2t2 , nt i ≥t k − q t 2 ln 2k·t2 δ for all i ∈St (for all active arms in round t). We now use this lower bound on the number of pulls of active arm i in round t to upper-bound η(t), an upper bound on the confidence interval width FAIRBANDITS uses for any active arm i in round t. Lemma 3. Consider any round t and any arm i ∈St. Condition on nt i ≥t k − q t ln( 2kt2 δ ) 2 . Then, ut i −ℓt i ≤2 v u u u t ln (π · t)2 /3δ 2 · t k − q t ln( 2kt2 δ ) 2 = η(t). We stitch together these lemmas as follows: Lemma 2 upper bounds the probability that any arm i active in round t has been pulled substantially fewer times than its expectation, and Lemma 3 upper bounds the width of any confidence interval used by FAIRBANDITS in round t by η(t). Together, these enable us to determine how both the number of arms in the active set, as well as the spread of their confidence intervals, evolve over time. This translates into the following regret bound. Theorem 2. If δ < 1/ √ T, then FAIRBANDITS has regret R(T) = O q k3T ln T k δ . Two points are worth highlighting in Theorem 2. First, this bound becomes non-trivial (i.e. the average per-round regret is ≪1) for T = Ω(k3). As we show in the next section, it is not possible to improve on this. Second, the bound may appear to have suboptimal dependence on T when compared to unconstrained regret bounds (where the dependence on T is often described as logarithmic). However, it is known that Ω √ kT regret is necessary even in the unrestricted setting (without fairness) if one does not make data-specific assumptions on an instance [9] It would be possible to state a logarithmic dependence on T in our setting as well while making assumptions on the gaps between arms, but since our fairness constraint manifests itself as a cost that depends on k, we choose for clarity to avoid such assumptions; without them, our dependence on T is also optimal. 5 3.2 Fair Classic Stochastic Bandits: A Lower Bound We now show that the regret bound for FAIRBANDITS has an optimal dependence on k: no fair algorithm has diminishing regret before T = Ω(k3) rounds. At a high level, we construct our lower bound example to embody the “worst of both worlds" for fair algorithms: the arm payoff means are just close enough together that the chain takes a long time to break, and the arm payoff means are just far enough apart that the algorithm incurs high regret while the chain remains unbroken. This lets us prove the formal statement below. The full proof, which proceeds via Bayesian reasoning using priors for the arm means, may be found in our technical companion paper [17]. Theorem 3. There is a distribution P over k-arm instances of the stochastic multi-armed bandit problem such that any fair algorithm run on P experiences constant per-round regret for at least T = Ω k3 ln 1 δ rounds. Thus, we tightly characterize the optimal regret attainable by fair algorithms in the classic bandits setting, and formally separate it from the regret attainable by algorithms absent a fairness constraint. Note that this already shows a separation between the best possible learning rates for contextual bandit learning with and without the fairness constraint – the classic multi-armed bandit problem is a special case of every contextual bandit problem, and for general contextual bandit problems, it is also known how to get non-trivial regret after only T = O(k) many rounds [3, 8, 12]. 4 Contextual Bandits Setting 4.1 KWIK Learnability Implies Fair Bandit Learnability In this section, we show if a class of functions is KWIK learnable, then there is a fair algorithm for learning the same class of functions in the contextual bandit setting, with a regret bound polynomially related to the function class’ KWIK bound. Intuitively, KWIK-learnability of a class of functions guarantees we can learn the function’s behavior to a high degree of accuracy with a high degree of confidence. As fairness constrains an algorithm most before the algorithm has determined the payoff functions’ behavior accurately, this guarantee enables us to learn fairly without incurring much additional regret. Formally, we prove the following polynomial relationship. Theorem 4. For an instance of the contextual multi-armed bandit problem where fj ∈C for all j ∈[k], if C is (ϵ, δ)-KWIK learnable with bound m(ϵ, δ), KWIKTOFAIR (δ, T) is δ-fair and achieves regret bound: R(T) = O max k2 · m ϵ∗, min (δ, 1/T) T 2k , k3 ln k δ for δ ≤ 1 √ T where ϵ∗= arg minϵ(max(ϵ · T, k · m(ϵ, min(δ,1/T ) kT 2 ))). First, we construct an algorithm KWIKTOFAIR(δ, T) that uses the KWIK learning algorithm as a subroutine, and prove that it is δ-fair. A call to KWIKTOFAIR(δ, T) will initialize a KWIK learner for each arm, and in each of the T rounds will implicitly construct a confidence interval around the prediction of each learner. If a learner makes a numeric valued prediction, we will interpret this as a confidence interval centered at the prediction with width ϵ∗. If a learner outputs ⊥, we interpret this as a trivial confidence interval (covering all of [0, 1]). We then use the same chaining technique used in the classic setting to choose an arm from the set of arms chained to the predicted top arm. Whenever all learners output predictions, they need no feedback. When a learner for j outputs ⊥, if j is selected then we have feedback rt j to give it; on the other hand, if j isn’t selected, we “roll back” the learning algorithm for j to before this round by not updating the algorithm’s state. 1: procedure KWIKTOFAIR(δ, T) 2: δ∗←min(δ, 1 T ) kT 2 , ϵ∗←arg minϵ(max(ϵ · T, k · m(ϵ, δ∗))) 3: Initialize KWIK(ϵ∗, δ∗)-learner Li, hi ←[ ] ∀i ∈[k] 4: for 1 ≤t ≤T do 5: S ←∅ ▷Initialize set of predictions S 6: for i = 1, . . . , k do 7: st i ←Li(xt i, hi) 8: S ←S ∪st i ▷Store prediction st i 6 9: if ⊥∈S then 10: Pull j∗←(x ∈R [k]), receive reward rt j∗ ▷Pick arm at random from all arms 11: else 12: it ∗←arg maxi st i 13: St ←{j | (st j −ϵ∗, st j + ϵ∗) chains to (st it∗−ϵ∗, st it∗+ ϵ∗)} 14: Pull j∗←(x ∈R St), receive reward rt j∗ ▷Pick arm at random from active set st i∗ 15: hj∗←hj∗:: (xt j∗, rt j∗) ▷Update the history for Lj∗ We begin by bounding the probability of certain failures of KWIKTOFAIR in Lemma 4. Lemma 4. With probability at least 1 −min(δ, 1 T ), for all rounds t and all arms i, (a) if st i ∈R then |st i −fi(xt i)| ≤ϵ∗and (b) P t I [st i = ⊥and i is pulled] ≤m(ϵ∗, δ∗). This in turn lets us prove the fairness of KWIKTOFAIR in Theorem 5. Intuitively, the KWIK algorithm’s confidence about predictions translates into confidence about expected rewards, which lets us choose between arms without violating fairness. Theorem 5. KWIKTOFAIR(δ, T) is δ-fair. We now use the KWIK bounds of the KWIK learners to upper-bound the regret of KWIKTOFAIR(δ, T). We proceed by bounding the regret incurred in those rounds when all KWIK algorithms make a prediction (i.e., when we have a nontrivial confidence interval for each arm’s expected reward) and then bounding the number of rounds for which some learner outputs ⊥(i.e., when we choose randomly from all arms and thus incur constant regret). These results combine to produce Lemma 5. Lemma 5. KWIKTOFAIR(δ, T) achieves regret O(max(k2 · m(ϵ∗, δ∗), k3 ln T k δ )). Our presentation of KWIKTOFAIR(δ, T) has a known time horizon T. Its guarantees extend to the case in which T is unknown via the standard “doubling trick” to prove Theorem 4. An important instance of the contextual bandit problem is the linear case, where C consists of the set of all linear functions of bounded norm in d dimensions, i.e. when the rewards of each arm are governed by an underlying linear regression model on contexts. Known KWIK algorithms [26] for the set of linear functions C then allow us, via our reduction, to give a fair contextual bandit algorithm for this setting with a polynomial regret bound. Lemma 6 ([26]). Let C = {fθ|fθ(x) = ⟨θ, x⟩, θ ∈Rd, ||θ|| ≤1} and X = {x ∈Rd : ||x|| ≤1}. C is KWIK learnable with KWIK bound m(ϵ, δ) = ˜O(d3/ϵ4). Then, an application of Theorem 4 implies that KWIKTOFAIR has a polynomial regret guarantee for the class of linear functions. Corollary 1. Let C and X be as in Lemma 6, and fj ∈C for each j ∈[k]. Then, KWIKTOFAIR(T, δ) using the learner from [26] has regret R(T) = ˜O max T 4/5k6/5d3/5, k3 ln k δ . 4.2 Fair Bandit Learnability Implies KWIK Learnability In this section, we show how to use a fair, no-regret contextual bandit algorithm to construct a KWIK learning algorithm whose KWIK bound has logarithmic dependence on the number of rounds T. Intuitively, any fair algorithm which achieves low regret must both be able to find and exploit an optimal arm (since the algorithm is no-regret) and can only exploit that arm once it has a tight understanding of the qualities of all arms (since the algorithm is fair). Thus, any fair no-regret algorithm will ultimately have tight (1 −δ)-confidence about each arm’s reward function. Theorem 6. Suppose A is a δ-fair algorithm for the contextual bandit problem over the class of functions C, with regret bound R(T, δ). Suppose also there exists f ∈C, x(ℓ) ∈X such that for every ℓ∈[⌈1 ϵ ⌉], f(x(ℓ)) = ℓ·ϵ. Then, FAIRTOKWIK is an (ϵ, δ)-KWIK algorithm for C with KWIK bound m(ϵ, δ), with m(ϵ, δ) the solution to m(ϵ,δ)ϵ 4 = R(m(ϵ, δ), ϵδ 2T ). Remark 1. The condition that C should contain a function that can take on values that are multiples of ϵ is for technical convenience; C can always be augmented by adding a single such function. 7 Our aim is to construct a KWIK algorithm B to predict labels for a sequence of examples labeled with some unknown function f ∗∈C. We provide a sketch of the algorithm, FAIRTOKWIK, below, and refer interested readers to our full technical paper [17] for a complete and formal description. We use our fair algorithm to construct a KWIK algorithm as follows: we will run our fair contextual bandit algorithm A on an instance that we construct online as examples xt arrive for B. The idea is to simulate a two arm instance, in which one arm’s rewards are governed by f ∗(the function to be KWIK learned), and the other arm’s rewards are governed by a function f that we can set to take any value in {0, ϵ, 2ϵ, . . . , 1}. For each input xt, we perform a thought experiment and consider A’s probability distribution over arms when facing a context which forces arm 2’s payoff to take each of the values 0, ϵ∗, 2ϵ∗, . . . , 1. Since A is fair, A will play arm 1 with weakly higher probability than arm 2 for those ℓ: ℓϵ∗≤f(xt); analogously, A will play arm 1 with weakly lower probability than arm 2 for those ℓ: ℓϵ∗≥f(xt). If there are at least 2 values of ℓfor which arm 1 and arm 2 are played with equal probability, one of those contexts will force A to suffer ϵ∗regret, so we continue the simulation of A on one of those instances selected at random, forcing at least ϵ∗/2 regret in expectation, and at the same time have B return ⊥. B receives f ∗(xt) on such a round, which is used to construct feedback for A. Otherwise, A must transition from playing arm 1 with strictly higher probability to playing 2 with strictly higher probability as ℓincreases: the point at which that occurs will “sandwich” the value of f(xt), since A’s fairness implies this transition must occur when the expected payoff of arm 2 exceeds that of arm 1. B uses this value to output a numeric prediction. An important fact we exploit is that we can query A’s behavior on (xt, x(ℓ)), for any xt and ℓ∈ ⌈1 ϵ∗⌉ without providing it feedback (and instead “roll back” its history to ht not including the query (xt, x(ℓ))). We update A’s history by providing it feedback only in rounds where B outputs ⊥. Finally, we note that, as in KWIKTOFAIR, the claims of FAIRTOKWIK extend to the infinite horizon case via the doubling trick. 4.3 An Exponential Separation Between Fair and Unfair Learning In this section, we use this Fair-KWIK equivalence to give a simple contextual bandit problem for which fairness imposes an exponential cost in its regret bound, unlike the polynomial cost proven in the linear case in Section 4.1. In this problem, the context domain is the d-dimensional boolean hypercube: X = {0, 1}d – i.e. the context each round for each individual consists of d boolean attributes. Our class of functions C is the class of boolean conjunctions: C = {f | f(x) = xi1 ∧xi2 ∧. . . ∧xik where 0 ≤k ≤d and i1, . . . , ik ∈[d]}. We first note that there exists a simple but unfair algorithm for this problem which obtains regret R(T) = O(k2d). A full description of this algorithm, called CONJUNCTIONBANDIT, may be found in our technical companion paper [17]. We now show that, in contrast, fair algorithms cannot guarantee subexponential regret in d. This relies upon a known lower bound for KWIK learning conjunctions [21]: Lemma 7. There exists a sequence of examples (x1, . . . , x2d−1) such that for ϵ, δ ≤1/2, every (ϵ, δ)-KWIK learning algorithm B for the class C of conjunctions on d variables must output ⊥for xt for each t ∈[2d −1]. Thus, B has a KWIK bound of at least m(ϵ, δ) = Ω(2d). We then use the equivalence between fair algorithms and KWIK learning to translate this lower bound on m(ϵ, δ) into a minimum worst case regret bound for fair algorithms on conjunctions. We modify Theorem 6 to yield the following lemma. Lemma 8. Suppose A is a δ-fair algorithm for the contextual bandit problem over the class C of conjunctions on d variables. If A has regret bound R(T, δ) then for δ′ = 2Tδ, FAIRTOKWIK is an (0, δ′)-KWIK algorithm for C with KWIK bound m(0, δ′) = 4R(m(0, δ′), δ). Lemma 7 then lets us lower-bound the worst case regret of fair learning algorithms on conjunctions. Corollary 2. For δ < 1 2T , any δ-fair algorithm for the contextual bandit problem over the class C of conjunctions on d boolean variables has a worst case regret bound of R(T) = Ω(2d). Together with the analysis of CONJUNCTIONBANDIT, this demonstrates a strong separation between fair and unfair contextual bandit algorithms: when the underlying functions mapping contexts to payoffs are conjunctions on d variables, there exist a sequence of contexts on which fair algorithms must incur regret exponential in d while unfair algorithms can achieve regret linear in d. 8 References [1] Jacob D. Abernethy, Kareem Amin, , Moez Draief, and Michael Kearns. Large-scale bandit problems and kwik learning. In Proceedings of (ICML-13), pages 588–596, 2013. [2] Philip Adler, Casey Falk, Sorelle A. Friedler, Gabriel Rybeck, Carlos Scheidegger, Brandon Smith, and Suresh Venkatasubramanian. Auditing black-box models by obscuring features. CoRR, abs/1602.07043, 2016. URL http://arxiv.org/abs/1602.07043. [3] Alekh Agarwal, Daniel J. Hsu, Satyen Kale, John Langford, Lihong Li, and Robert E. Schapire. Taming the monster: A fast and simple algorithm for contextual bandits. In Proceedings of ICML 2014, Beijing, China, 21-26 June 2014, pages 1638–1646, 2014. [4] Kareem Amin, Michael Kearns, and Umar Syed. Graphical models for bandit problems. arXiv preprint arXiv:1202.3782, 2012. [5] Peter Auer, Nicolo Cesa-Bianchi, and Paul Fischer. Finite-time analysis of the multiarmed bandit problem. Machine learning, 47(2-3):235–256, 2002. [6] Solon Barocas and Andrew D. Selbst. Big data’s disparate impact. California Law Review, 104, 2016. Available at SSRN: http://ssrn.com/abstract=2477899. [7] Anna Maria Barry-Jester, Ben Casselman, and Dana Goldstein. The new science of sentencing. The Marshall Project, August 8 2015. URL https://www.themarshallproject.org/2015/08/04/ the-new-science-of-sentencing. Retrieved 4/28/2016. [8] Alina Beygelzimer, John Langford, Lihong Li, Lev Reyzin, and Robert E. Schapire. Contextual bandit algorithms with supervised learning guarantees. In Proceedings of AISTATS 2011, Fort Lauderdale, USA, April 11-13, 2011, pages 19–26, 2011. [9] Sébastien Bubeck and Nicolo Cesa-Bianchi. Regret analysis of stochastic and nonstochastic multi-armed bandit problems. Machine Learning, 5(1):1–122, 2012. [10] Nanette Byrnes. Artificial intolerance. MIT Technology Review, March 28 2016. [11] Toon Calders and Sicco Verwer. Three naive bayes approaches for discrimination-free classification. Data Mining and Knowledge Discovery, 21(2):277–292, 2010. [12] Wei Chu, Lihong Li, Lev Reyzin, and Robert E. Schapire. Contextual bandits with linear payoff functions. In Proceedings of AISTATS 2011, Fort Lauderdale, USA, April 11-13, 2011, pages 208–214, 2011. [13] Cary Coglianese and David Lehr. Regulating by robot: Administrative decision-making in the machinelearning era. Georgetown Law Journal, 2016. Forthcoming. [14] Cynthia Dwork, Moritz Hardt, Toniann Pitassi, Omer Reingold, and Richard Zemel. Fairness through awareness. In Proceedings of ITCS 2012, pages 214–226. ACM, 2012. [15] Michael Feldman, Sorelle A. Friedler, John Moeller, Carlos Scheidegger, and Suresh Venkatasubramanian. Certifying and removing disparate impact. In Proceedings of ACM SIGKDD 2015, Sydney, NSW, Australia, August 10-13, 2015, pages 259–268, 2015. [16] Benjamin Fish, Jeremy Kun, and Ádám D Lelkes. A confidence-based approach for balancing fairness and accuracy. SIAM International Symposium on Data Mining, 2016. [17] Matthew Joseph, Michael Kearns, Jamie Morgenstern, and Aaron Roth. Fairness in learning: Classic and contextual bandits. CoRR, abs/1605.07139, 2016. URL http://arxiv.org/abs/1605.07139. [18] Toshihiro Kamishima, Shotaro Akaho, and Jun Sakuma. Fairness-aware learning through regularization approach. In Data Mining Workshops (ICDMW), 2011 IEEE 11th International Conference on, pages 643–650. IEEE, 2011. [19] Michael N Katehakis and Herbert Robbins. Sequential choice from several populations. PROCEEDINGSNATIONAL ACADEMY OF SCIENCES USA, 92:8584–8584, 1995. [20] Tze Leung Lai and Herbert Robbins. Asymptotically efficient adaptive allocation rules. Advances in applied mathematics, 6(1):4–22, 1985. [21] Lihong Li. A unifying framework for computational reinforcement learning theory. PhD thesis, Rutgers, The State University of New Jersey, 2009. [22] Lihong Li, Michael L Littman, Thomas J Walsh, and Alexander L Strehl. Knows what it knows: a framework for self-aware learning. Machine learning, 82(3):399–443, 2011. [23] Binh Thanh Luong, Salvatore Ruggieri, and Franco Turini. k-nn as an implementation of situation testing for discrimination discovery and prevention. In Proceedings of ACM SIGKDD 2011, pages 502–510. ACM, 2011. [24] Clair C Miller. Can an algorithm hire better than a human? The New York Times, June 25 2015. [25] Cynthia Rudin. Predictive policing using machine learning to detect patterns of crime. Wired Magazine, August 2013. [26] Alexander L Strehl and Michael L Littman. Online linear regression and its application to model-based reinforcement learning. In Advances in Neural Information Processing Systems, pages 1417–1424, 2008. [27] Rich Zemel, Yu Wu, Kevin Swersky, Toni Pitassi, and Cynthia Dwork. Learning fair representations. In Proceedings of (ICML-13), pages 325–333, 2013. 9 | 2016 | 524 |
6,466 | Variational Autoencoder for Deep Learning of Images, Labels and Captions Yunchen Pu†, Zhe Gan†, Ricardo Henao†, Xin Yuan‡, Chunyuan Li†, Andrew Stevens† and Lawrence Carin† †Department of Electrical and Computer Engineering, Duke University {yp42, zg27, r.henao, cl319, ajs104, lcarin}@duke.edu ‡Nokia Bell Labs, Murray Hill xyuan@bell-labs.com Abstract A novel variational autoencoder is developed to model images, as well as associated labels or captions. The Deep Generative Deconvolutional Network (DGDN) is used as a decoder of the latent image features, and a deep Convolutional Neural Network (CNN) is used as an image encoder; the CNN is used to approximate a distribution for the latent DGDN features/code. The latent code is also linked to generative models for labels (Bayesian support vector machine) or captions (recurrent neural network). When predicting a label/caption for a new image at test, averaging is performed across the distribution of latent codes; this is computationally efficient as a consequence of the learned CNN-based encoder. Since the framework is capable of modeling the image in the presence/absence of associated labels/captions, a new semi-supervised setting is manifested for CNN learning with images; the framework even allows unsupervised CNN learning, based on images alone. 1 Introduction Convolutional neural networks (CNNs) [1] are effective tools for image analysis [2], with most CNNs trained in a supervised manner [2, 3, 4]. In addition to being used in image classifiers, image features learned by a CNN have been used to develop models for image captions [5, 6, 7]. Most recent work on image captioning employs a CNN for image encoding, with a recurrent neural network (RNN) employed as a decoder of the CNN features, generating a caption. While large sets of labeled and captioned images have been assembled, in practice one typically encounters far more images without labels or captions. To leverage the vast quantity of these latter images (and to tune a model to the specific unlabeled/uncaptioned images of interest at test), semisupervised learning of image features is of interest. To account for unlabeled/uncaptioned images, it is useful to employ a generative image model, such as the recently developed Deep Generative Deconvolutional Network (DGDN) [8, 9]. However, while the CNN is a feedforward model for image features (and is therefore fast at test time), the original DGDN implementation required relatively expensive inference of the latent image features. Specifically, in [8] parameter learning and inference are performed with Gibbs sampling or Monte Carlo Expectation-Maximization (MCEM). We develop a new variational autoencoder (VAE) [10] setup to analyze images. The DGDN [8] is used as a decoder, and the encoder for the distribution of latent DGDN parameters is based on a CNN (termed a “recognition model” [10, 11]). Since a CNN is used within the recognition model, test-time speed is much faster than that achieved in [8]. The VAE framework manifests a novel means of semi-supervised CNN learning: a Bayesian SVM [12] leverages available image labels, the DGDN models the images (with or without labels), and the CNN manifests a fast encoder for the distribution of latent codes. For image-caption modeling, latent codes are shared between the CNN encoder, 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. DGDN decoder, and RNN caption model; the VAE learns all model parameters jointly. These models are also applicable to images alone, yielding an unsupervised method for CNN learning. Our DGDN-CNN model for images is related to but distinct from prior convolutional variational auto-encoder networks [13, 14, 15]. In those models the pooling process in the encoder network is deterministic (max-pooling), as is the unpooling process in the decoder [14] (related to upsampling [13]). Our model uses stochastic unpooling, in which the unpooling map (upsampling) is inferred from the data, by maximizing a variational lower bound. Summarizing, the contributions of this paper include: (i) a new VAE-based method for deep deconvolutional learning, with a CNN employed within a recognition model (encoder) for the posterior distribution of the parameters of the image generative model (decoder); (ii) demonstration that the fast CNN-based encoder applied to the DGDN yields accuracy comparable to that provided by Gibbs sampling and MCEM based inference, while being much faster at test time; (iii) the first semi-supervised CNN classification results, applied to large-scale image datasets; and (iv) extensive experiments on image-caption modeling, in which we demonstrate the advantages of jointly learning the image features and caption model (we also present semi-supervised experiments for image captioning). 2 Variational Autoencoder Image Model 2.1 Image Decoder: Deep Deconvolutional Generative Model Consider N images {X(n)}N n=1, with X(n) ∈RNx×Ny×Nc; Nx and Ny represent the number of pixels in each spatial dimension, and Nc denotes the number of color bands in the image (Nc = 1 for gray-scale images and Nc = 3 for RGB images). To introduce the image decoder (generative model) in its simplest form, we first consider a decoder with L = 2 layers. The code {S(n,k2,2)}K2 k2=1 feeds the decoder at the top (layer 2), and at the bottom (layer 1) the image X(n) is generated: Layer 2: ˜S(n,2) = PK2 k2=1 D(k2,2) ∗S(n,k2,2) (1) Unpool: S(n,1) ∼unpool(˜S(n,2)) (2) Layer 1: ˜S(n,1) = PK1 k1=1 D(k1,1) ∗S(n,k1,1) (3) Data Generation: X(n) ∼N(˜S(n,1), α−1 0 I) (4) Equation (4) is meant to indicate that E(X(n)) = ˜S(n,1), and each element of X(n) −E(X(n)) is iid zero-mean Gaussian with precision α0. Concerning notation, expressions with two superscripts, D(kl,l), S(n,l) and ˜S(n,l), for layer l ∈{1, 2} and image n ∈{1, . . . , N}, are 3D tensors. Expressions with three superscripts, S(n,kl,l), are 2D activation maps, representing the klth “slice” of 3D tensor S(n,l); S(n,kl,l) is the spatially-dependent activation map for image n, dictionary element kl ∈{1, . . . , Kl}, at layer l of the model. Tensor S(n,l) is formed by spatially aligning and “stacking” the {S(n,kl,l)}Kl kl=1. Convolution D(kl,l) ∗S(n,kl,l) between 3D D(kl,l) and 2D S(n,kl,l) indicates that each of the Kl−1 2D “slices” of D(kl,l) is convolved with the spatially-dependent S(n,kl,l); upon aligning and “stacking” these convolutions, a tensor output is manifested for D(kl,l) ∗S(n,kl,l) (that tensor has Kl−1 2D slices). Assuming dictionary elements {D(kl,l)} are known, along with the precision α0. We now discuss the generative process of the decoder. The layer-2 activation maps {S(n,k2,2)}K2 k2=1 are the code that enters the decoder. Activation map S(n,k2,2) is spatially convolved with D(k2,2), yielding a 3D tensor; summing over the K2 such tensors manifested at layer-2 yields the pooled 3D tensor ˜S(n,2). Stochastic unpooling (discussed below) is employed to go from ˜S(n,2) to S(n,1). Slice k1 of S(n,1), S(n,k1,1), is convolved with D(k1,1), and summing over k1 yields E(X(n)). For the stochastic unpooling, S(n,k1,1) is partitioned into contiguous px × py pooling blocks (analogous to pooling blocks in CNN-based activation maps [1]). Let z(n,k1,1) i,j ∈{0, 1}pxpy be a vector of pxpy −1 zeros, and a single one; z(n,k1,1) i,j corresponds to pooling block (i, j) in S(n,k1,1). The 2 location of the non-zero element of z(n,k1,1) i,j identifies the location of the single non-zero element in the corresponding pooling block of S(n,k1,1). The non-zero element in pooling block (i, j) of S(n,k1,1) is set to ˜S(n,k1,2) i,j , i.e., element (i, j) in slice k1 of ˜S(n,2). Within the prior of the decoder, we impose z(n,k1,1) i,j ∼Mult(1; 1/(pxpy), . . . , 1/(pxpy)). Both ˜S(n,2) and S(n,2) are 3D tensors with K1 2D slices; as a result of the unpooling, the 2D slices in the sparse S(n,2) have pxpy times more elements than the corresponding slices in the dense ˜S(n,2). The above model may be replicated to constitute L > 2 layers. The decoder is represented concisely as pα(X|s, z), where vector s denotes the “unwrapped” set of top-layer features {S(·,kL,L)}, and vector z denotes the unpooling maps at all L layers. The model parameters α are the set of dictionary elements at the L layers, as well as the precision α0. The prior over the code is p(s) = N(0, I). 2.2 Image Encoder: Deep CNN To make explicit the connection between the proposed CNN-based encoder and the above decoder, we also initially illustrate the encoder with an L = 2 layer model. While the two-layer decoder in (1)-(4) is top-down, starting at layer 2, the encoder is bottom-up, starting at layer 1 with image X(n): Layer 1: ˜C(n,k1,1) = X(n) ∗s F(k1,1) , k1 = 1, . . . , K1 (5) Pool: C(n,1) ∼pool( ˜C(n,1)) (6) Layer 2: ˜C(n,k2,2) = C(n,1) ∗s F(k2,2) , k2 = 1, . . . , K2 (7) Code Generation: sn ∼N µφ( ˜C(n,2)), diag(σ2 φ( ˜C(n,2))) (8) Image X(n) and filter F(k1,1) are each tensors, composed of Nc stacked 2D images (“slices”). To implement X(n) ∗s F(k1,1), the respective spatial slices of X(n) and F(k1,1) are convolved; the results of the Nc convolutions are aligned spatially and summed, yielding a single 2D spatially-dependent filter output ˜C(n,k1,1) (hence notation ∗s, to distinguish ∗in (1)-(4)). The 2D maps { ˜C(n,k1,1)}K1 k1=1 are aligned spatially and “stacked” to constitute the 3D tensor ˜C(n,1). Each contiguous px × py pooling region in ˜C(n,1) is stochastically pooled to constitute C(n,1); the posterior pooling statistics in (6) are detailed below. Finally, the pooled tensor C(n,1) is convolved with K2 layer-2 filters {F(k2,2)}K2 k2=1, each of which yields the 2D feature map ˜C(n,k2,2); the K2 feature maps { ˜C(n,k2,2)}K2 k2=1 are aligned and “stacked” to manifest ˜C(n,2). Concerning the pooling in (6), let ˜C(n,k1,1) i,j reflect the pxpy components in pooling block (i, j) of ˜C(n,k1,1). Using a multi-layered perceptron (MLP), this is mapped to the pxpy-dimensional real vector η(n,k1,1) i,j = MLP( ˜C(n,k1,1) i,j ), defined as η(n,k1,1) i,j = W1h, with h = tanh W2vec( ˜C(n,k1,1) i,j ) . The pooling vector is drawn z(n,k1,1) i,j ∼Mult(1; Softmax(η(n,k1,1) i,j )); as a recognition model, Mult(1; Softmax(η(n,k1,1) i,j )) is also treated as the posterior distribution for the DGDN unpooling in (2). Similarly, to constitute functions µφ( ˜C(n,2)) and σ2 φ( ˜C(n,2)) in (8), each layer of ˜C(n,2) is fed through a distinct MLP. Details are provided in the Supplementary Material (SM). Parameters φ of qφ(s, z|X) correspond to the filter banks {F(kl,l)}, as well as the parameters of the MLPs. The encoder is a CNN (yielding fast testing), utilized in a novel manner to manifest a posterior distribution on the parameters of the decoder. As discussed in Section 4, the CNN is trained in a novel manner, allowing semi-supervised and even unsupervised CNN learning. 3 Leveraging Labels and Captions 3.1 Generative Model for Labels: Bayesian SVM Assume a label ℓn ∈{1, . . . , C} is associated with training image X(n); in the discussion that follows, labels are assumed available for each image (for notational simplicity), but in practice only a subset of the N training images need have labels. We design C one-versus-all binary SVM classifiers 3 [16], responsible for mapping top-layer image features sn to label ℓn; sn is the same image code as in (8), from the top DGDN layer. For the ℓ-th classifier, with ℓ∈{1, . . . , C}, the problem may be posed as training with {sn, y(ℓ) n }N n=1, with y(ℓ) n ∈{−1, 1}. If ℓn = ℓthen y(ℓ) n = 1, and y(ℓ) n = −1 otherwise. Henceforth we consider the Bayesian SVM for each one of the binary learning tasks, with labeled data {sn, yn}N n=1. Given a feature vector s, the goal of the SVM is to find an f(s) that minimizes the objective function γ PN n=1 max(1 −ynf(sn), 0)+R(f(s)), where max(1−ynf(sn), 0) is the hinge loss, R(f(s)) is a regularization term that controls the complexity of f(s), and γ is a tuning parameter controlling the trade-off between error penalization and the complexity of the classification function. Recently, [12] showed that for the linear classifier f(s) = βT s, minimizing the SVM objective function is equivalent to estimating the mode of the pseudo-posterior of β: p(β|S, y, γ) ∝QN n=1 L(yn|sn, β, γ)p(β|·), where y = [y1 . . . yN]T , S = [s1 . . . sN], L(yn|sn, β, γ) is the pseudo-likelihood function, and p(β|·) is the prior distribution for the vector of coefficients β. In [12] it was shown that L(yn|sn, β, γ) admits a location-scale mixture of normals representation by introducing latent variables λn: L(yn|sn, β, γ) = e−2γ max(1−ynβT sn,0) = R ∞ 0 √γ √2πλn exp −(1+λn−ynβT sn)2 2γ−1λn dλn. (9) Note that (9) is a mixture of Gaussian distributions w.r.t. random variable ynβT sn, where the mixture is formed with respect to λn, which controls the mean and variance of the Gaussians. This encourages data augmentation for variable λn , permitting efficient Bayesian inference (see [12, 17] for details). Parameters {βℓ}C ℓ=1 for the C binary SVM classifiers are analogous to the fully connected parameters of a softmax classifier connected to the top of a traditional CNN [2]. If desired, the pseudo-likelihood of the SVM-based classifier can be replaced by a softmax-based likelihood. In Section 5 we compare performance of the SVM and softmax based classifiers. 3.2 Generative Model for Captions For image n, assume access to an associated caption Y(n); for notational simplicity, we again assume a caption is available for each training image, although in practice captions may only be available on a subset of images. The caption is represented as Y(n) = (y(n) 1 , . . . , y(n) Tn ), and y(n) t is a 1-of-V (“one-hot”) encoding, with V the size of the vocabulary, and Tn the length of the caption for image n. Word t, y(n) t , is embedded into an M-dimensional vector w(n) t = Wey(n) t , where We ∈RM×V is a word embedding matrix (to be learned), i.e., w(n) t is a column of We, chosen by the one-hot y(n) t . The probability of caption Y(n) given top-layer DGDN image features sn is defined as p(Y(n)|sn) = p(y(n) 1 |sn) QTn t=2 p(y(n) t |y(n) <t , sn). Specifically, we generate the first word y(n) 1 from sn, with p(y(n) 1 ) = softmax(Vh(n) 1 ), where h(n) 1 = tanh(Csn). Bias terms are omitted for simplicity. All other words in the caption are then sequentially generated using a recurrent neural network (RNN), until the end-sentence symbol is generated. Each conditional p(y(n) t |y(n) <t , sn) is specified as softmax(Vh(n) t ), where h(n) t is recursively updated through h(n) t = H(w(n) t−1, h(n) t−1). C and V are weight matrices (to be learned), and V is used for computing a distribution over words. The transition function H(·) can be implemented with a gated activation function, such as Long Short-Term Memory (LSTM) [18] or a Gated Recurrent Unit (GRU) [19]. Both LSTM and GRU have been proposed to address the issue of learning long-term dependencies. In experiments we have found that GRU provides slightly better performance than LSTM (we implemented and tested both), and therefore the GRU is used. 4 Variational Learning of Model Parameters To make the following discussion concrete, we describe learning and inference within the context of images and captions, combining the models in Sections 2 and 3.2. This learning setup is also applied to model images with associated labels, with the caption model replaced in that case with the Bayesian SVM of Section 3.1 (details provided in the SM). In the subsequent discussion we employ the image encoder qφ(s, z|X), the image decoder pα(X|s, z), and the generative model for the caption (denoted pψ(Y|s), where ψ represents the GRU parameters). 4 The desired parameters {φ, α, ψ} are optimized by minimizing the variational lower bound. For a single captioned image, the variational lower bound Lφ,α,ψ(X, Y) can be expressed as Lφ,α,ψ(X, Y) = ξ Eqφ(s|X)[log pψ(Y|s)] + Eqφ(s,z|X)[log pα(X, s, z) −log qφ(s, z|X)] where ξ is a tuning parameter that balances the two components of Lφ,α,ψ(X, Y). When ξ is set to zero, it corresponds to the variational lower bound for a single uncaptioned image: Uφ,α(X) = Eqφ(s,z|X)[log pα(X, s, z) −log qφ(s, z|X)] (10) The lower bound for the entire dataset is then: Jφ,α,ψ = P (X,Y)∈Dc Lφ,α,ψ(X, Y) + P X∈Du Uφ,α(X) (11) where Dc denotes the set of training images with associated captions, and Du is the set of training images that are uncaptioned (and unlabeled). To optimize Jφ,α,ψ w.r.t. φ, ψ and α, we utilize Monte Carlo integration to approximate the expectation, Eqφ(s,z|X), and stochastic gradient descent (SGD) for parameter optimization. We use the variance reduction techniques in [10] and [11] to compute the gradients. Details are provided in the SM. When ξ is set to 1, Lφ,α,ψ(X, Y) recovers the exact variational lower bound. Motivated by assigning the same weight to every data point, we set ξ = NX/(Tρ) or NX/(Cρ) in the experiments, where NX is the number of pixels in each image, T is the number of words in the corresponding caption, C is the number of categories for the corresponding label and ρ is the proportion of labeled/captioned data in the mini-batch. At test time, we consider two tasks: inference of a caption or label for a new image X⋆. Again, considering captioning of a new image (with similar inference for labeling), after the model parameters are learned p(Y⋆|X⋆) = R pψ(Y⋆|s⋆)p(s⋆|X⋆)ds⋆≈PNs s=1 pψ(Y⋆|s⋆ s), where s⋆ s ∼qφ(s|X = X⋆), and Ns is the number of samples. Monte Carlo sampling is used to approximate the integral, and the recognition model, qφ(s|X), is employed to approximate p(s|X), for fast inference of image representation. 5 Experiments The architecture of models and initialization of model parameters are provided in the SM. No datasetspecific tuning other than early stopping on validation sets was conducted. The Adam algorithm [20] with learning rate 0.0002 is utilized for optimization of the variational learning expressions in Section 4. We use mini-batches of size 64. Gradients are clipped if the norm of the parameter vector exceeds 5, as suggested in [21]. All the experiments of our models are implemented in Theano [22] using a NVIDIA GeForce GTX TITAN X GPU with 12GB memory. 5.1 Benchmark Classification We first present image classification results on MNIST, CIFAR-10 & -100 [23], Caltech 101 [24] & 256 [25], and ImageNet 2012 datasets. For Caltech 101 and Caltech 256, we use 30 and 60 images per class for training, respectively. The predictions are based on averaging the decision values of Ns = 50 collected samples from the approximate posterior distribution over the latent variables from qφ(s|X). As a reference for computational cost, our model takes about 5 days to train on ImageNet. We compared our VAE setup to a VAE with deterministic unpooling, and we also compare with a DGDN trained using Gibbs sampling and MCEM [8]; classification results and testing time are summarized in Table 1. Other state-of-the-art results can be found in [8]. The results based on Gibbs sampling and MCEM are obtained by our own implementation on the same GPU, which are consistent with the classification accuracies reported in [8]. For Gibbs-sampling-based learning, only suitable for the first five small/modest size datasets we consider, we collect 50 posterior samples of model parameters α, after 1000 burn-in iterations during training. Given a sample of model parameters, the inference of top-layer features at test is also done via Gibbs sampling. Specifically, we collect 100 samples after discarding 300 burn-in samples; fewer samples leads to worse performance. The predictions are based on averaging the decision values 5 Table 1: Classification error (%) and testing time (ms per image) on benchmarks. Method MNIST CIFAR-10 CIFAR-100 Caltech 101 Caltech 256 test test test test test test test test test test error time error time error time error time error time Gibbs [8] 0.37 3.1 8.21 10.4 34.33 10.4 12.87 50.4 29.50 52.3 MCEM [8] 0.45 0.8 9.04 1.1 35.92 1.1 13.51 8.8 30.13 8.9 VAE-d 0.42 0.007 10.74 0.02 37.96 0.02 14.79 0.3 32.18 0.3 VAE (Ours) 0.38 0.007 8.19 0.02 35.01 0.02 11.99 0.3 29.33 0.3 Method ImageNet 2012 ImageNet Pretrained for top-1 top-5 test Caltech 101 Caltech 256 error error time test error test time test error test time MCEM [8] 37.9 16.1 14.4 6.85 14.1 22.10 14.2 VAE (Ours) 38.2 15.7 1.0 6.91 0.9 22.53 0.9 of the collected samples (50 samples of model parameters α, and for each 100 inference samples of latent parameters s and z, for a total of 5000 samples). With respect to the testing of MCEM, all data-dependent latent variables are integrated (summed) out in the expectation, except for the top-layer feature map, for which we find a MAP point estimate via gradient descent. As summarized in Table 1, the proposed recognition model is much faster than Gibbs sampling and MCEM at test time (up to 400x speedup), and yields accuracy commensurate with these other two methods (often better). To illustrate the role of stochastic unpooling, we replaced it with deterministic unpooling as in [14]. The results, indicated as VAE-d in Table 1, demonstrate the powerful capabilities of the stochastic unpooling operation. We also tried VAE-d on the ImageNet 2012 dataset; however, the performance is much worse than our proposed VAE, hence those results are not reported. 5.2 Semi-Supervised Classification We now consider semi-supervised classification. With each mini-batch, we use 32 labeled samples and 32 unlabeled samples, i.e., ρ = 0.5. Table 2: Semi-supervised classification error (%) on MNIST. N is the number of labeled images per class. N TSVM Deep generative model [26] Ladder network [27] Our model M1+TSVM M1+M2 Γ-full Γ-conv ξ = 0 ξ = Nx/(Cρ) 10 16.81 11.82± 0.25 3.33 ± 0.14 1.06 ± 0.37 0.89±0.50 5.83 ± 0.97 1.49 ± 0.36 60 6.16 5.72± 0.05 2.59 ±0.05 0.82 ± 0.17* 2.19 ± 0.19 0.77 ± 0.09 100 5.38 4.24± 0.07 2.40 ±0.02 0.84 ± 0.08 0.74 ± 0.10* 1.75 ± 0.14 0.63 ± 0.06 300 3.45 3.49± 0.04 2.18 ±0.04 0.63 ± 0.02* 1.42 ± 0.08 0.51 ± 0.04 *These results are achieved with our own implementation based on the publicly available code. MNIST We first test our model on the MNIST classification benchmark. We randomly split the 60,000 training samples into a 50,000-sample training set and a 10,000-sample validation set (used to evaluate early stopping). The training set is further randomly split into a labeled and unlabeled set, and the number of labeled samples in each category varies from 10 to 300. We perform testing on the standard 10,000 test samples with 20 different training-set splits. Table 2 shows the classification results. For ξ = 0, the model is trained in an unsupervised manner. When doing unsupervised learning, the features extracted by our model are sent to a separate transductive SVM (TSVM). In this case, our results can be directly compared to the results of the M1+TSVM model [26], demonstrating the effectiveness of our recognition model in providing good representations of images. Using 10 labeled images per class, our semi-supervised learning approach with ξ = Nx/(Cρ) achieves a test error of 1.49, which is competitive with state-of-the-art results [27]. When using a larger number of labeled images, our model consistently achieves the best results. ImageNet 2012 ImageNet 2012 is used to assess the scalability of our model to large datasets (also considered, for supervised learning, in Table 1). Since no comparative results exist for semisupervised learning with ImageNet, we implemented the 8-layer AlexNet [2] and the 22-layer GoogLeNet [4] as the supervised model baselines, which were trained by utilizing only the labeled data1. We split the 1.3M training images into a labeled and unlabeled set, and vary the proportion 1We use the default settings in the Caffe package, which provide a top-1 accuracy of 57.1% and 68.7%, as well as a top-5 accuracy of 80.2% and 88.9% on the validation set for AlexNet and GoogLeNet, respectively. 6 of labeled images from 1% to 100%. The classes are balanced to ensure that no particular class is over-represented, i.e., the ratio of labeled and unlabeled images is the same for each class. We repeat the training process 10 times, and each time we utilize different sets of images as the unlabeled ones. 0 10 20 30 40 50 60 70 80 90 1 5 10 20 30 40 50 60 70 80 90 100 Proportion (%) of Labeled Images Accuracy (%) AlexNet Top−1 AlexNet Top−5 GoogLeNet Top−1 GoogLeNet Top−5 Ours Top−1 Ours Top−5 Figure 1: Semi-supervised classification accuracy on the validation set of ImageNet 2012. Figure 1 shows our results, together with the baselines. Tabulated results and a plot with error bars are provided in the SM. The variance of our model’s results (caused by different randomly selected labeled examples) is around 1% when considering a small proportion of labeled images (less than 10% labels), and the variance drops to less than 0.2% when the proportion of labeled images is larger than 30%. As can be seen from Figure 1, our semi-supervised learning approach with 60% labeled data achieves comparable results (61.24% top-1 accuracy) with the results of full datasets (61.8% top-1 accuracy), demonstrating the effectiveness of our approach for semi-supervised classification. Our model provides consistently better results than AlexNet [2] which has a similar five convolutional layers architecture as ours. Our model is outperformed by GoogLeNet when more labeled images are provided. This is not surprising since GoogLeNet utilizes a considerably more complicated CNN architecture than ours. To further illustrate the role of each component of our model, we replaced the Bayesian SVM with a softmax classifier (see discussion at the end of Section 3.1). The softmax results are slightly worse, and provided in the SM. The gap between the results of Bayesian SVM and softmax are around 1% when the proportion of labeled images is less 30% and drop to around 0.5% when a larger proportion of labeled images is considered (larger than 30%). This further illustrates that the performance gain is primarily due to the semi-supervised learning framework used in our model, rather than the discriminative power of the SVM. 5.3 Image Captioning We present image captioning results on three benchmark datasets: Flickr8k [29], Flickr30k [30] and Microsoft (MS) COCO [31]. These datasets contain 8000, 31000 and 123287 images, respectively. Each image is annotated with 5 sentences. For fair comparison, we use the same pre-defined splits for all the datasets as in [5]. We use 1000 images for validation, 1000 for test and the rest for training on Flickr8k and Flickr30k. For MS COCO, 5000 images are used for both validation and testing. The widely used BLEU metric [32] and sentence perplexity (PPL) are employed to quantitatively evaluate the performance of our image captioning model. A low PPL indicates a better language model. For the MS COCO dataset, we further evaluate our model with metrics METEOR [33] and CIDEr [34]. Our joint model takes three days to train on MS COCO. We show results for three models: (i) Two-step model: this model consists of our generative and recognition model developed in Section 2 to analyze images alone, in an unsupervised manner. The extracted image features are fed to a separately trained RNN. (ii) Joint model: this is the joint model developed in Sections 2 and 3.2. (iii) Joint model with ImageNet: in this model training is performed in a semi-supervised manner, with the training set of ImageNet 2012 treated as uncaptioned images, to complement the captioned training set. The image captioning results are summarized in Table 3. Our two-step model achieves better performance than similar baseline two-step methods, in which VggNet [3] and GoogLeNet [4] were used as feature extractors. The baseline VggNet and GoogLeNet models require labeled images for training, and hence are trained on ImageNet. By contrast, in our two-step approach, the deep model is trained in an unsupervised manner, using uncaptioned versions of images from the training set. This fact may explain the improved quality of our results in Table 3. 7 Table 3: BLEU-1,2,3,4, METEOR, CIDEr and PPL metrics compared to other state-of-the-art results and baselines on Flickr8k, Flickr 30k and MS COCO datasets. Method Flickr8k Flickr30k B-1 B-2 B-3 B-4 PPL B-1 B-2 B-3 B-4 PPL Baseline results VggNet+RNN 0.56 0.37 0.24 0.16 15.71 0.57 0.38 0.25 0.17 18.83 GoogLeNet+RNN 0.56 0.38 0.24 0.16 15.71 0.58 0.39 0.26 0.17 18.77 Our two step model 0.61 0.41 0.27 0.17 15.82 0.61 0.41 0.27 0.17 18.73 Our results with other state-of-the-art results Hard-Attention [6] 0.67 0.46 0.31 0.21 0.67 0.44 0.30 0.20 Our joint model 0.70 0.49 0.33 0.22 15.24 0.69 0.50 0.35 0.22 16.17 Our joint model with ImageNet 0.72 0.52 0.36 0.25 13.24 0.72 0.53 0.38 0.25 15.34 State-of-the-art results using extra information Attributes-CNN+RNN [7] 0.74 0.54 0.38 0.27 12.60 0.73 0.55 0.40 0.28 15.96 Method MS COCO B-1 B-2 B-3 B-4 METEOR CIDEr PPL Baseline results VggNet+RNN 0.61 0.42 0.28 0.19 0.19 0.56 13.16 GoogLeNet+RNN 0.60 0.40 0.26 0.17 0.19 0.55 14.01 Our two step 0.61 0.42 0.27 0.18 0.20 0.58 13.46 Our results with other state-of-the-art results DMSM [28] 0.26 0.24 18.10 Hard-Attention [6] 0.72 0.50 0.36 0.25 0.23 Our joint model 0.71 0.51 0.38 0.26 0.22 0.89 11.57 Our joint model with ImageNet 0.72 0.52 0.37 0.28 0.24 0.90 11.14 State-of-the-art results using extra information Attributes-CNN+LSTM [7] 0.74 0.56 0.42 0.31 0.26 0.94 10.49 It is worth noting that our joint model yields significant improvements over our two-step model, nearly 10% in average for BLEU scores, demonstrating the importance of inferring a shared latent structure. It can also be seen that our improvement with semi-supervised use of ImageNet is most significant with the small/modest datasets (Flickr8k and Flickr30k), compared to the large dataset (MS COCO). Our model performs better than most image captioning systems. The only method with better performance than ours is [7], which employs an intermediate image-to-attributes layer, that requires determining an extra attribute vocabulary. Examples of generated captions from the validation set of ImageNet 2012, which has no ground truth captions and is unseen during training (the semi-supervised learning only uses the training set of ImageNet 2012), are shown in Figure 2. a man with a snowboard next to a man with glasses a big black dog standing on the grass a player is holding a hockey stick a desk with a keyboard a man is standing next to a brown horse a box full of apples and oranges Figure 2: Examples of generated caption from unseen images on the validation dataset of ImageNet. 6 Conclusions A recognition model has been developed for the Deep Generative Deconvolutional Network (DGDN) [8], based on a novel use of a deep CNN. The recognition model has been coupled with a Bayesian SVM and an RNN, to also model associated labels and captions, respectively. The model is learned using a variational autoencoder setup, and allows semi-supervised learning (leveraging images without labels or captions). The algorithm has been scaled up with a GPU-based implementation, achieving results competitive with state-of-the-art methods on several tasks (and novel semi-supervised results). Acknowledgements This research was supported in part by ARO, DARPA, DOE, NGA, ONR and NSF. The Titan X used in this work was donated by the NVIDIA Corporation. 8 References [1] Y. LeCun, B. Boser, J. S. Denker, D. Henderson, R. E. Howard, W. Hubbard, and L. D. Jackel. Backpropagation applied to handwritten zip code recognition. Neural Computation, 1989. [2] A. Krizhevsky, I. Sutskever, and G. E. Hinton. Imagenet classification with deep convolutional neural networks. In NIPS, 2012. [3] K. Simonyan and A. Zisserman. Very deep convolutional networks for large-scale image recognition. In ICLR, 2015. [4] C. Szegedy, W. Liui, Y. Jia, P. Sermanet, S. Reed, D. Anguelov, D. Erhan, V. Vanhoucke, and A. Rabinovich. Going deeper with convolutions. In CVPR, 2015. [5] O. Vinyals, A. Toshev, S. Bengio, and D. Erhan. Show and tell: A neural image caption generator. In CVPR, 2015. [6] K. Xu, J. L. Ba, R. Kiros, K. Cho, A. Courville, R. Salakhutdinov, R. S. Zemel, and Y. Bengio. Show, attend and tell: Neural image caption generation with visual attention. In ICML, 2015. [7] Q. Wu, C. Shen, A. Hengel, L. Liu, and A. Dick. What value do explicit high level concepts have in vision to language problems? In CVPR, 2016. [8] Y. Pu, X. Yuan, A. Stevens, C. Li, and L. Carin. A deep generative deconvolutional image model. In AISTATS, 2016. [9] Y. Pu, X. Yuan, and L. Carin. Generative deep deconvolutional learning. In ICLR workshop, 2015. [10] D. P. Kingma and M. Welling. Auto-encoding variational Bayes. In ICLR, 2014. [11] A. Mnih and K. Gregor. Neural variational inference and learning in belief networks. In ICML, 2014. [12] N. G. Polson and S. L. Scott. Data augmentation for support vector machines. Bayes. Anal., 2011. [13] T. D. Kulkarni, W.l Whitney, P. Kohli, and J. B. Tenenbaum. Deep convolutional inverse graphics network. In NIPS, 2015. [14] A. Dosovitskiy, J. T. Springenberg, M. Tatarchenko, and T. Brox. Learning to generate chairs, tables and cars with convolutional networks. In CVPR, 2015. [15] C. Li, J. Zhu, T. Shi, and B. Zhang. Max-margin deep generative models. In NIPS, 2015. [16] V. Vapnik. The nature of statistical learning theory. Springer-Verlag New York, Inc., 1995. [17] R. Henao, X. Yuan, and L. Carin. Bayesian nonlinear SVMs and factor modeling. NIPS, 2014. [18] S Hochreiter and J. Schmidhuber. Long short-term memory. Neural Computation, 1997. [19] K. Cho, B. V. Merrienboer, C. Gulcehre, D. Bahdanau, F. Bougares, H. Schwenk, and Y. Bengio. Learning phrase representations using rnn encoder-decoder for statistical machine translation. In EMNLP, 2014. [20] D. Kingma and J. Ba. Adam: A method for stochastic optimization. In ICLR, 2015. [21] I. Sutskever, O. Vinyals, and Q. V. Le. Sequence to sequence learning with neural networks. In NIPS, 2014. [22] F. Bastien, P. Lamblin, R. Pascanu, J. Bergstra, I. Goodfellow, A. Bergeron, N. Bouchard, D. Warde-Farley, and Y. Bengio. Theano: new features and speed improvements. In NIPS Workshop, 2012. [23] A. Krizhevsky and G. Hinton. Learning multiple layers of features from tiny images. Computer Science Department, University of Toronto, Tech. Rep, 2009. [24] F. Li, F. Rob, and P. Perona. Learning generative visual models from few training examples: An incremental bayesian approach tested on 101 object categories. Computer Vision and Image Understanding, 2007. [25] G. Griffin, A. Holub, and P. Perona. Caltech-256 object category dataset. 2007. [26] D.P. Kingma, S. Mohamed, D.J. Rezende, and M. Welling. Semi-supervised learning with deep generative models. In NIPS, 2014. [27] A. Rasmus, M. Berglund, M. Honkala, H. Valpola, and T. Raiko. Semi-supervised learning with ladder networks. In NIPS, 2015. [28] H. Fang, S. Gupta, F. Iandola, R. Srivastava, L. Deng, P. Dollár, J. Gao, X. He, M. Mitchell, J. C. Platt, C. L. Zitnick, and G. Zweig. From captions to visual concepts and back. In CVPR, 2015. [29] M. Hodosh, P. Young, and J. Hockenmaier. Framing image description as a ranking task: Data, models and evaluation metrics. Journal of Artificial Intelligence Research, 2013. [30] P. Young, A. Lai, M. Hodosh, and J. Hockenmaier. From image descriptions to visual denotations: New similarity metrics for semantic inference over event descriptions. Transactions of the Association for Computational Linguistics, 2014. [31] T. Lin, M. Maire, S. Belongie, J. Hays, P. Perona, D. Ramanan, P. Dollár, and C. L. Zitnick. Microsoft COCO: Common objects in context. In ECCV, 2014. [32] K. Papineni, S. Roukos, T. Ward, and W. Zhu. Bleu: a method for automatic evaluation of machine translation. Transactions of the Association for Computational Linguistics, 2002. [33] S. Banerjee and A. Lavie. Meteor: An automatic metric for MT evaluation with improved correlation with human judgments. In ACL workshop, 2005. [34] R. Vedantam, Z. C. Lawrence, and D. Parikh. Cider: Consensus-based image description evaluation. In CVPR, 2015. 9 | 2016 | 525 |
6,467 | Weight Normalization: A Simple Reparameterization to Accelerate Training of Deep Neural Networks Tim Salimans OpenAI tim@openai.com Diederik P. Kingma OpenAI dpkingma@openai.com Abstract We present weight normalization: a reparameterization of the weight vectors in a neural network that decouples the length of those weight vectors from their direction. By reparameterizing the weights in this way we improve the conditioning of the optimization problem and we speed up convergence of stochastic gradient descent. Our reparameterization is inspired by batch normalization but does not introduce any dependencies between the examples in a minibatch. This means that our method can also be applied successfully to recurrent models such as LSTMs and to noise-sensitive applications such as deep reinforcement learning or generative models, for which batch normalization is less well suited. Although our method is much simpler, it still provides much of the speed-up of full batch normalization. In addition, the computational overhead of our method is lower, permitting more optimization steps to be taken in the same amount of time. We demonstrate the usefulness of our method on applications in supervised image recognition, generative modelling, and deep reinforcement learning. 1 Introduction Recent successes in deep learning have shown that neural networks trained by first-order gradient based optimization are capable of achieving amazing results in diverse domains like computer vision, speech recognition, and language modelling [7]. However, it is also well known that the practical success of first-order gradient based optimization is highly dependent on the curvature of the objective that is optimized. If the condition number of the Hessian matrix of the objective at the optimum is low, the problem is said to exhibit pathological curvature, and first-order gradient descent will have trouble making progress [22, 32]. The amount of curvature, and thus the success of our optimization, is not invariant to reparameterization [1]: there may be multiple equivalent ways of parameterizing the same model, some of which are much easier to optimize than others. Finding good ways of parameterizing neural networks is thus an important problem in deep learning. While the architectures of neural networks differ widely across applications, they are typically mostly composed of conceptually simple computational building blocks sometimes called neurons: each such neuron computes a weighted sum over its inputs and adds a bias term, followed by the application of an elementwise nonlinear transformation. Improving the general optimizability of deep networks is a challenging task [6], but since many neural architectures share these basic building blocks, improving these building blocks improves the performance of a very wide range of model architectures and could thus be very useful. Several authors have recently developed methods to improve the conditioning of the cost gradient for general neural network architectures. One approach is to explicitly left multiply the cost gradient with an approximate inverse of the Fisher information matrix, thereby obtaining an approximately whitened natural gradient. Such an approximate inverse can for example be obtained by using a Kronecker factored approximation to the Fisher matrix and inverting it (KFAC, [23]), by using an 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. approximate Cholesky factorization of the inverse Fisher matrix (FANG, [10]), or by whitening the input of each layer in the neural network (PRONG, [5]). Alternatively, we can use standard first order gradient descent without preconditioning, but change the parameterization of our model to give gradients that are more like the whitened natural gradients of these methods. For example, Raiko et al. [27] propose to transform the outputs of each neuron to have zero output and zero slope on average. They show that this transformation approximately diagonalizes the Fisher information matrix, thereby whitening the gradient, and that this leads to improved optimization performance. Another approach in this direction is batch normalization [14], a method where the output of each neuron (before application of the nonlinearity) is normalized by the mean and standard deviation of the outputs calculated over the examples in the minibatch. This reduces covariate shift of the neuron outputs and the authors suggest it also brings the Fisher matrix closer to the identity matrix. Following this second approach to approximate natural gradient optimization, we propose a simple but general method, called weight normalization, for improving the optimizability of the weights of neural network models. The method is inspired by batch normalization, but it is a deterministic method that does not share batch normalization’s property of adding noise to the gradients. In addition, the overhead imposed by our method is lower: no additional memory is required and the additional computation is negligible. The method show encouraging results on a wide range of deep learning applications. 2 Weight Normalization We consider standard artificial neural networks where the computation of each neuron consists in taking a weighted sum of input features, followed by an elementwise nonlinearity: y = φ(w · x + b), (1) where w is a k-dimensional weight vector, b is a scalar bias term, x is a k-dimensional vector of input features, φ(.) denotes an elementwise nonlinearity such as the rectifier max(., 0), and y denotes the scalar output of the neuron. After associating a loss function to one or more neuron outputs, such a neural network is commonly trained by stochastic gradient descent in the parameters w, b of each neuron. In an effort to speed up the convergence of this optimization procedure, we propose to reparameterize each weight vector w in terms of a parameter vector v and a scalar parameter g and to perform stochastic gradient descent with respect to those parameters instead. We do so by expressing the weight vectors in terms of the new parameters using w = g ||v||v (2) where v is a k-dimensional vector, g is a scalar, and ||v|| denotes the Euclidean norm of v. This reparameterization has the effect of fixing the Euclidean norm of the weight vector w: we now have ||w|| = g, independent of the parameters v. We therefore call this reparameterizaton weight normalization. The idea of normalizing the weight vector has been proposed before (e.g. [31, 33]) but earlier work typically still performed optimization in the w-parameterization, only applying the normalization after each step of stochastic gradient descent. This is fundamentally different from our approach: we propose to explicitly reparameterize the model and to perform stochastic gradient descent in the new parameters v, g directly. Doing so improves the conditioning of the gradient and leads to improved convergence of the optimization procedure: By decoupling the norm of the weight vector (g) from the direction of the weight vector (v/||v||), we speed up convergence of our stochastic gradient descent optimization, as we show experimentally in section 5. Instead of working with g directly, we may also use an exponential parameterization for the scale, i.e. g = es, where s is a log-scale parameter to learn by stochastic gradient descent. Parameterizing the g parameter in the log-scale is more intuitive and more easily allows g to span a wide range of different magnitudes. Empirically, however, we did not find this to be an advantage. In our experiments, the eventual test-set performance was not significantly better or worse than the results with directly learning g in its original parameterization, and optimization was slightly slower. 2 2.1 Gradients Training a neural network in the new parameterization is done using standard stochastic gradient descent methods. Here we differentiate through (2) to obtain the gradient of a loss function L with respect to the new parameters v, g. Doing so gives ∇gL = ∇wL · v ||v|| , ∇vL = g ||v||∇wL −g∇gL ||v||2 v, (3) where ∇wL is the gradient with respect to the weights w as used normally. Backpropagation using weight normalization thus only requires a minor modification to the usual backpropagation equations, and is easily implemented using standard neural network software, either by directly specifying the network in terms of the v, g parameters and relying on auto-differentiation, or by applying (3) in a post-processing step. We provide reference implementations using both approaches for Theano, Tensorflow and Keras at https://github.com/openai/weightnorm. Unlike with batch normalization, the expressions above are independent of the minibatch size and thus cause only minimal computational overhead. An alternative way to write the gradient is ∇vL = g ||v||Mw∇wL, with Mw = I −ww′ ||w||2 , (4) where Mw is a projection matrix that projects onto the complement of the w vector. This shows that weight normalization accomplishes two things: it scales the weight gradient by g/||v||, and it projects the gradient away from the current weight vector. Both effects help to bring the covariance matrix of the gradient closer to identity and benefit optimization, as we explain below. Due to projecting away from w, the norm of v grows monotonically with the number of weight updates when learning a neural network with weight normalization using standard gradient descent without momentum: Let v′ = v + ∆v denote our parameter update, with ∆v ∝∇vL (steepest ascent/descent), then ∆v is necessarily orthogonal to the current weight vector w since we project away from it when calculating ∇vL (equation 4). Since v is proportional to w, the update is thus also orthogonal to v and increases its norm by the Pythagorean theorem. Specifically, if ||∆v||/||v|| = c the new weight vector will have norm ||v′|| = p ||v||2 + c2||v||2 = √ 1 + c2||v|| ≥||v||. The rate of increase will depend on the the variance of the weight gradient. If our gradients are noisy, c will be high and the norm of v will quickly increase, which in turn will decrease the scaling factor g/||v||. If the norm of the gradients is small, we get √ 1 + c2 ≈1, and the norm of v will stop increasing. Using this mechanism, the scaled gradient self-stabilizes its norm. This property does not strictly hold for optimizers that use separate learning rates for individual parameters, like Adam [15] which we use in experiments, or when using momentum. However, qualitatively we still find the same effect to hold. Empirically, we find that the ability to grow the norm ||v|| makes optimization of neural networks with weight normalization very robust to the value of the learning rate: If the learning rate is too large, the norm of the unnormalized weights grows quickly until an appropriate effective learning rate is reached. Once the norm of the weights has grown large with respect to the norm of the updates, the effective learning rate stabilizes. Neural networks with weight normalization therefore work well with a much wider range of learning rates than when using the normal parameterization. It has been observed that neural networks with batch normalization also have this property [14], which can also be explained by this analysis. By projecting the gradient away from the weight vector w, we also eliminate the noise in that direction. If the covariance matrix of the gradient with respect to w is given by C, the covariance matrix of the gradient in v is given by D = (g2/||v||2)MwCMw. Empirically, we find that w is often (close to) a dominant eigenvector of the covariance matrix C: removing that eigenvector then gives a new covariance matrix D that is closer to the identity matrix, which may further speed up learning. 3 2.2 Relation to batch normalization An important source of inspiration for this reparameterization is batch normalization [14], which normalizes the statistics of the pre-activation t for each minibatch as t′ = t −µ[t] σ[t] , with µ[t], σ[t] the mean and standard deviation of the pre-activations t = v · x. For the special case where our network only has a single layer, and the input features x for that layer are whitened (independently distributed with zero mean and unit variance), these statistics are given by µ[t] = 0 and σ[t] = ||v||. In that case, normalizing the pre-activations using batch normalization is equivalent to normalizing the weights using weight normalization. Convolutional neural networks usually have much fewer weights than pre-activations, so normalizing the weights is often much cheaper computationally. In addition, the norm of v is non-stochastic, while the minibatch mean µ[t] and variance σ2[t] can in general have high variance for small minibatch size. Weight normalization can thus be viewed as a cheaper and less noisy approximation to batch normalization. Although exact equivalence does not usually hold for deeper architectures, we still find that our weight normalization method provides much of the speed-up of full batch normalization. In addition, its deterministic nature and independence on the minibatch input also means that our method can be applied more easily to models like RNNs and LSTMs, as well as noise-sensitive applications like reinforcement learning. 3 Data-Dependent Initialization of Parameters Besides a reparameterization effect, batch normalization also has the benefit of fixing the scale of the features generated by each layer of the neural network. This makes the optimization robust against parameter initializations for which these scales vary across layers. Since weight normalization lacks this property, we find it is important to properly initialize our parameters. We propose to sample the elements of v from a simple distribution with a fixed scale, which is in our experiments a normal distribution with mean zero and standard deviation 0.05. Before starting training, we then initialize the b and g parameters to fix the minibatch statistics of all pre-activations in our network, just like in batch normalization, but only for a single minibatch of data and only during initialization. This can be done efficiently by performing an initial feedforward pass through our network for a single minibatch of data X, using the following computation at each neuron: t = v · x ||v|| , and y = φ t −µ[t] σ[t] , (5) where µ[t] and σ[t] are the mean and standard deviation of the pre-activation t over the examples in the minibatch. We can then initialize the neuron’s biase b and scale g as g ← 1 σ[t], b ←−µ[t] σ[t] , (6) so that y = φ(w · x + b). Like batch normalization, this method ensures that all features initially have zero mean and unit variance before application of the nonlinearity. With our method this only holds for the minibatch we use for initialization, and subsequent minibatches may have slightly different statistics, but experimentally we find this initialization method to work well. The method can also be applied to networks without weight normalization, simply by doing stochastic gradient optimization on the parameters w directly, after initialization in terms of v and g: this is what we compare to in section 5. Independently from our work, this type of initialization was recently proposed by different authors [24, 18] who found such data-based initialization to work well for use with the standard parameterization in terms of w. The downside of this initialization method is that it can only be applied in similar cases as where batch normalization is applicable. For models with recursion, such as RNNs and LSTMs, we will have to resort to standard initialization methods. 4 4 Mean-only Batch Normalization Weight normalization, as introduced in section 2, makes the scale of neuron activations approximately independent of the parameters v. Unlike with batch normalization, however, the means of the neuron activations still depend on v. We therefore also explore the idea of combining weight normalization with a special version of batch normalization, which we call mean-only batch normalization: With this normalization method, we subtract out the minibatch means like with full batch normalization, but we do not divide by the minibatch standard deviations. That is, we compute neuron activations using t = w · x, ˜t = t −µ[t] + b, y = φ(˜t) (7) where w is the weight vector, parameterized using weight normalization, and µ[t] is the minibatch mean of the pre-activation t. During training, we keep a running average of the minibatch mean which we substitute in for µ[t] at test time. The gradient of the loss with respect to the pre-activation t is calculated as ∇tL = ∇˜tL −µ[∇˜tL], (8) where µ[.] denotes once again the operation of taking the minibatch mean. Mean-only batch normalization thus has the effect of centering the gradients that are backpropagated. This is a comparatively cheap operation, and the computational overhead of mean-only batch normalization is thus lower than for full batch normalization. In addition, this method causes less noise during training, and the noise that is caused is more gentle as the law of large numbers ensures that µ[t] and µ[∇˜t] are approximately normally distributed. Thus, the added noise has much lighter tails than the highly kurtotic noise caused by the minibatch estimate of the variance used in full batch normalization. As we show in section 5.1, this leads to improved accuracy at test time. 5 Experiments We experimentally validate the usefulness of our method using four different models for varied applications in supervised image recognition, generative modelling, and deep reinforcement learning. 5.1 Supervised Classification: CIFAR-10 To test our reparameterization method for the application of supervised classification, we consider the CIFAR-10 data set of natural images [19]. The model we are using is based on the ConvPool-CNN-C architecture of [30], with some small modifications: we replace the first dropout layer by a layer that adds Gaussian noise, we expand the last hidden layer from 10 units to 192 units, and we use 2 × 2 max-pooling, rather than 3 × 3. The only hyperparameter that we actively optimized (the standard deviation of the Gaussian noise) was chosen to maximize the performance of the network on a holdout set of 10000 examples, using the standard parameterization (no weight normalization or batch normalization). A full description of the resulting architecture is given in table A in the supplementary material. We train our network for CIFAR-10 using Adam [15] for 200 epochs, with a fixed learning rate and momentum of 0.9 for the first 100 epochs. For the last 100 epochs we set the momentum to 0.5 and linearly decay the learning rate to zero. We use a minibatch size of 100. We evaluate 5 different parameterizations of the network: 1) the standard parameterization, 2) using batch normalization, 3) using weight normalization, 4) using weight normalization combined with mean-only batch normalization, 5) using mean-only batch normalization with the normal parameterization. The network parameters are initialized using the scheme of section 3 such that all four cases have identical parameters starting out. For each case we pick the optimal learning rate in {0.0003, 0.001, 0.003, 0.01}. The resulting error curves during training can be found in figure 1: both weight normalization and batch normalization provide a significant speed-up over the standard parameterization. Batch normalization makes slightly more progress per epoch than weight normalization early on, although this is partly offset by the higher computational cost: with our implementation, training with batch normalization was about 16% slower compared to the standard parameterization. In contrast, weight normalization was not noticeably slower. During the later stage of training, weight normalization and batch normalization seem to optimize at about the same speed, with the normal parameterization (with or without mean-only batch normalization) still lagging behind. After optimizing the network for 200 5 0 50 100 150 200 0 0.05 0.1 training epochs training error normal param. weight norm. batch norm. WN + mean−only BN mean−only BN Figure 1: Training error for CIFAR-10 using different parameterizations. For weight normalization, batch normalization, and mean-only batch normalization we show results using Adam with a learning rate of 0.003. For the normal parameterization we instead use 0.0003 which works best in this case. For the last 100 epochs the learning rate is linearly decayed to zero. Model Test Error Maxout [8] 11.68% Network in Network [21] 10.41% Deeply Supervised [20] 9.6% ConvPool-CNN-C [30] 9.31% ALL-CNN-C [30] 9.08% our CNN, mean-only B.N. 8.52% our CNN, weight norm. 8.46% our CNN, normal param. 8.43% our CNN, batch norm. 8.05% ours, W.N. + mean-only B.N. 7.31% DenseNet [13] 5.77% Figure 2: Classification results on CIFAR-10 without data augmentation. epochs using the different parameterizations, we evaluate their performance on the CIFAR-10 test set. The results are summarized in table 2: weight normalization, the normal parameterization, and mean-only batch normalization have similar test accuracy (≈8.5% error). Batch normalization does significantly better at 8.05% error. Mean-only batch normalization combined with weight normalization has the best performance at 7.31% test error, and interestingly does much better than mean-only batch normalization combined with the normal parameterization: This suggests that the noise added by batch normalization can be useful for regularizing the network, but that the reparameterization provided by weight normalization or full batch normalization is also needed for optimal results. We hypothesize that the substantial improvement by mean-only B.N. with weight normalization over regular batch normalization is due to the distribution of the noise caused by the normalization method during training: for mean-only batch normalization the minibatch mean has a distribution that is approximately Gaussian, while the noise added by full batch normalization during training has much higher kurtosis. The result with mean-only batch normalization combined with weight normalization represented the state-of-the-art for CIFAR-10 among methods that do not use data augmentation, until it was recently surpassed by DenseNets [13]. 5.2 Generative Modelling: Convolutional VAE Next, we test the effect of weight normalization applied to deep convolutional variational autoencoders (CVAEs) [16, 28, 29], trained on the MNIST data set of images of handwritten digits and the CIFAR-10 data set of small natural images. Variational auto-encoders are generative models that explain the data vector x as arising from a set of latent variables z, through a joint distribution of the form p(z, x) = p(z)p(x|z), where the decoder p(x|z) is specified using a neural network. A lower bound on the log marginal likelihood log p(x) can be obtained by approximately inferring the latent variables z from the observed data x using an encoder distribution q(z|x) that is also specified as a neural network. This lower bound is then optimized to fit the model to the data. We follow a similar implementation of the CVAE as in [29] with some modifications, mainly that the encoder and decoder are parameterized with ResNet [11] blocks, and that the diagonal posterior is replaced with a more flexible specification based on inverse autoregressive flow. A further developed version of this model is presented in [17], where the architecture is explained in detail. For MNIST, the encoder consists of 3 sequences of two ResNet blocks each, the first sequence acting on 16 feature maps, the others on 32 feature maps. The first two sequences are followed by a 2-times subsampling operation implemented using 2 × 2 stride, while the third sequence is followed by a fully connected layer with 450 units. The decoder has a similar architecture, but with reversed direction. For CIFAR-10, we used a neural architecture with ResNet units and multiple intermediate stochastic layers. We used Adamax [15] with α = 0.002 for optimization, in combination with 6 Polyak averaging [26] in the form of an exponential moving average that averages parameters over approximately 10 epochs. In figure 3, we plot the test-set lower bound as a function of number of training epochs, including error bars based on multiple different random seeds for initializing parameters. As can be seen, the parameterization with weight normalization has lower variance and converges to a better optimum. We observe similar results across different hyper-parameter settings. 50 100 150 200 250 300 training epochs 88.0 87.5 87.0 86.5 86.0 85.5 85.0 84.5 84.0 bound on marginal likelihood Convolutional VAE on MNIST normal parameterization weight normalization 0 50 100 150 200 250 300 350 400 450 training epochs 8000 8500 9000 9500 10000 bound on marginal likelihood Convolutional VAE on CIFAR-10 normal parameterization weight normalization Figure 3: Marginal log likelihood lower bound on the MNIST (top) and CIFAR-10 (bottom) test sets for a convolutional VAE during training, for both the standard implementation as well as our modification with weight normalization. For MNIST, we provide standard error bars to indicate variance based on different initial random seeds. 5.3 Generative Modelling: DRAW Next, we consider DRAW, a recurrent generative model by [9]. DRAW is a variational auto-encoder with generative model p(z)p(x|z) and encoder q(z|x), similar to the model in section 5.2, but with both the encoder and decoder consisting of a recurrent neural network comprised of Long Short-Term Memory (LSTM) [12] units. LSTM units consist of a memory cell with additive dynamics, combined with input, forget, and output gates that determine which information flows in and out of the memory. The additive dynamics enables learning of long-range dependencies in the data. At each time step of the model, DRAW uses the same set of weight vectors to update the cell states of the LSTM units in its encoder and decoder. Because of the recurrent nature of this process it is not trivial to apply batch normalization here: Normalizing the cell states diminishes their ability to pass through information. Fortunately, weight normalization can easily be applied to the weight vectors of each LSTM unit, and we find this to work well empirically. Some other potential solutions were recently proposed in [4, 2]. 0 10 20 30 40 50 60 70 80 90 100 −120 −115 −110 −105 −100 −95 −90 −85 −80 training epochs bound on marginal log likelihood normal parameterization weight normalization Figure 4: Marginal log likelihood lower bound on the MNIST test set for DRAW during training, for both the standard implementation as well as our modification with weight normalization. 100 epochs is not sufficient for convergence for this model, but the implementation using weight normalization clearly makes progress much more quickly than with the standard parameterization. 7 We take the Theano implementation of DRAW provided at https://github.com/jbornschein/ draw and use it to model the MNIST data set of handwritten digits. We then make a single modification to the model: we apply weight normalization to all weight vectors. As can be seen in figure 4, this significantly speeds up convergence of the optimization procedure, even without modifying the initialization method and learning rate that were tuned for use with the normal parameterization. 5.4 Reinforcement Learning: DQN Next we apply weight normalization to the problem of Reinforcement Learning for playing games on the Atari Learning Environment [3]. The approach we use is the Deep Q-Network (DQN) proposed by [25]. This is an application for which batch normalization is not well suited: the noise introduced by estimating the minibatch statistics destabilizes the learning process. We were not able to get batch normalization to work for DQN without using an impractically large minibatch size. In contrast, weight normalization is easy to apply in this context, as is the initialization method of section 3. Stochastic gradient learning is performed using Adamax [15] with momentum of 0.5. We search for optimal learning rates in {0.0001, 0.0003, 0.001, 0.003}, generally finding 0.0003 to work well with weight normalization and 0.0001 to work well for the normal parameterization. We also use a larger minibatch size (64) which we found to be more efficient on our hardware (Amazon Elastic Compute Cloud g2.2xlarge GPU instance). Apart from these changes we follow [25] as closely as possible in terms of parameter settings and evaluation methods. However, we use a Python/Theano/Lasagne reimplementation of their work, adapted from the implementation available at https://github.com/spragunr/deep_q_rl, so there may be small additional differences in implementation. Figure 5 shows the training curves obtained using DQN with the standard parameterization and with weight normalization on Space Invaders. Using weight normalization the algorithm progresses more quickly and reaches a better final result. Table 6 shows the final evaluation scores obtained by DQN with weight normalization for four games: on average weight normalization improves the performance of DQN. 0 50 100 150 200 0 500 1000 1500 2000 2500 training epochs test reward per episode normal parameterization weight normalization Figure 5: Evaluation scores for Space Invaders obtained by DQN after each epoch of training, for both the standard parameterization and using weight normalization. Learning rates for both cases were selected to maximize the highest achieved test score. Game normal weightnorm Mnih Breakout 410 403 401 Enduro 1,250 1,448 302 Seaquest 7,188 7,375 5,286 Space Invaders 1,779 2,179 1,975 Figure 6: Maximum evaluation scores obtained by DQN, using either the normal parameterization or using weight normalization. The scores indicated by Mnih et al. are those reported by [25]: Our normal parameterization is approximately equivalent to their method. Differences in scores may be caused by small differences in our implementation. Specifically, the difference in our score on Enduro and that reported by [25] might be due to us not using a play-time limit during evaluation. 6 Conclusion We have presented weight normalization, a simple reparameterization of the weight vectors in a neural network that accelerates the convergence of stochastic gradient descent optimization. Weight normalization was applied to four different models in supervised image recognition, generative modelling, and deep reinforcement learning, showing a consistent advantage across applications. The reparameterization method is easy to apply, has low computational overhead, and does not introduce dependencies between the examples in a minibatch, making it our default choice in the development of new deep learning architectures. 8 References [1] S. Amari. Neural learning in structured parameter spaces - natural Riemannian gradient. In Advances in Neural Information Processing Systems, pages 127–133. MIT Press, 1997. [2] J. L. Ba, J. R. Kiros, and G. E. Hinton. Layer normalization. arXiv preprint arXiv:1607.06450, 2016. [3] M. G. Bellemare, Y. Naddaf, J. Veness, and M. Bowling. The arcade learning environment: An evaluation platform for general agents. Journal of Artificial Intelligence Research, 47:253–279, 06 2013. [4] T. Cooijmans, N. Ballas, C. Laurent, and A. Courville. Recurrent batch normalization. arXiv preprint arXiv:1603.09025, 2016. [5] G. Desjardins, K. Simonyan, R. Pascanu, et al. Natural neural networks. In Advances in Neural Information Processing Systems, pages 2062–2070, 2015. [6] X. Glorot and Y. Bengio. Understanding the difficulty of training deep feedforward neural networks. In International conference on artificial intelligence and statistics, pages 249–256, 2010. [7] I. Goodfellow, Y. Bengio, and A. Courville. Deep learning. Book in preparation for MIT Press, 2016. [8] I. J. Goodfellow, D. Warde-Farley, M. Mirza, A. Courville, and Y. Bengio. Maxout networks. In ICML, 2013. [9] K. Gregor, I. Danihelka, A. Graves, and D. Wierstra. Draw: A recurrent neural network for image generation. arXiv preprint arXiv:1502.04623, 2015. [10] R. Grosse and R. Salakhudinov. Scaling up natural gradient by sparsely factorizing the inverse fisher matrix. In ICML, pages 2304–2313, 2015. [11] K. He, X. Zhang, S. Ren, and J. Sun. Deep residual learning for image recognition. arXiv preprint arXiv:1512.03385, 2015. [12] S. Hochreiter and J. Schmidhuber. Long short-term memory. Neural computation, 9(8):1735–1780, 1997. [13] G. Huang, Z. Liu, and K. Q. Weinberger. Densely connected convolutional networks. arXiv preprint arXiv:1608.06993, 2016. [14] S. Ioffe and C. Szegedy. Batch normalization: Accelerating deep network training by reducing internal covariate shift. In ICML, 2015. [15] D. Kingma and J. Ba. Adam: A method for stochastic optimization. arXiv preprint arXiv:1412.6980, 2014. [16] D. P. Kingma and M. Welling. Auto-Encoding Variational Bayes. Proceedings of the 2nd International Conference on Learning Representations, 2013. [17] D. P. Kingma, T. Salimans, and M. Welling. Improving variational inference with inverse autoregressive flow. arXiv preprint arXiv:1606.04934, 2016. [18] P. Krähenbühl, C. Doersch, J. Donahue, and T. Darrell. Data-dependent initializations of convolutional neural networks. arXiv preprint arXiv:1511.06856, 2015. [19] A. Krizhevsky and G. Hinton. Learning multiple layers of features from tiny images, 2009. [20] C.-Y. Lee, S. Xie, P. Gallagher, Z. Zhang, and Z. Tu. Deeply-supervised nets. In Deep Learning and Representation Learning Workshop, NIPS, 2014. [21] M. Lin, C. Qiang, and S. Yan. Network in network. In ICLR: Conference Track, 2014. [22] J. Martens. Deep learning via hessian-free optimization. In Proceedings of the 27th International Conference on Machine Learning (ICML-10), pages 735–742, 2010. [23] J. Martens and R. Grosse. Optimizing neural networks with kronecker-factored approximate curvature. arXiv preprint arXiv:1503.05671, 2015. [24] D. Mishkin and J. Matas. All you need is a good init. arXiv preprint arXiv:1511.06422, 2015. [25] V. Mnih, K. Kavukcuoglu, D. Silver, A. A. Rusu, J. Veness, M. G. Bellemare, A. Graves, M. Riedmiller, A. K. Fidjeland, G. Ostrovski, et al. Human-level control through deep reinforcement learning. Nature, 518(7540):529–533, 2015. [26] B. T. Polyak and A. B. Juditsky. Acceleration of stochastic approximation by averaging. SIAM Journal on Control and Optimization, 30(4):838–855, 1992. [27] T. Raiko, H. Valpola, and Y. LeCun. Deep learning made easier by linear transformations in perceptrons. In International Conference on Artificial Intelligence and Statistics, pages 924–932, 2012. [28] D. J. Rezende, S. Mohamed, and D. Wierstra. Stochastic backpropagation and approximate inference in deep generative models. In ICML, pages 1278–1286, 2014. [29] T. Salimans, D. P. Kingma, and M. Welling. Markov chain Monte Carlo and variational inference: Bridging the gap. In ICML, 2015. [30] J. T. Springenberg, A. Dosovitskiy, T. Brox, and M. Riedmiller. Striving for simplicity: The all convolutional net. In ICLR Workshop Track, 2015. [31] N. Srebro and A. Shraibman. Rank, trace-norm and max-norm. In Proceedings of the 18th Annual Conference on Learning Theory, pages 545—-560, 2005. [32] I. Sutskever, J. Martens, G. Dahl, and G. Hinton. On the importance of initialization and momentum in deep learning. In ICML, pages 1139–1147, 2013. [33] S. Zhang, H. Jiang, S. Wei, and L.-R. Dai. Rectified linear neural networks with tied-scalar regularization for lvcsr. In INTERSPEECH, pages 2635–2639, 2015. 9 | 2016 | 526 |
6,468 | Learning Additive Exponential Family Graphical Models via ℓ2,1-norm Regularized M-Estimation Xiao-Tong Yuan† Ping Li‡§ Tong Zhang‡ Qingshan Liu† Guangcan Liu† †B-DAT Lab, Nanjing University of Info. Sci.&Tech. Nanjing, Jiangsu, 210044, China ‡Depart. of Statistics and §Depart. of Computer Science, Rutgers University Piscataway, NJ, 08854, USA {xtyuan,qsliu, gcliu}@nuist.edu.cn, {pingli,tzhang}@stat.rutgers.edu Abstract We investigate a subclass of exponential family graphical models of which the sufficient statistics are defined by arbitrary additive forms. We propose two ℓ2,1norm regularized maximum likelihood estimators to learn the model parameters from i.i.d. samples. The first one is a joint MLE estimator which estimates all the parameters simultaneously. The second one is a node-wise conditional MLE estimator which estimates the parameters for each node individually. For both estimators, statistical analysis shows that under mild conditions the extra flexibility gained by the additive exponential family models comes at almost no cost of statistical efficiency. A Monte-Carlo approximation method is developed to efficiently optimize the proposed estimators. The advantages of our estimators over Gaussian graphical models and Nonparanormal estimators are demonstrated on synthetic and real data sets. 1 Introduction As an important class of statistical models for exploring the interrelationship among a large number of random variables, undirected graphical models (UGMs) have enjoyed popularity in a wide range of scientific and engineering domains, including statistical physics, computer vision, data mining, and computational biology. Let X = [X1, ..., Xp]⊤be a p-dimensional random vector with each variable Xi taking values in a set X. Suppose G = (V, E) is an undirected graph consists of a set of vertices V = {1, ..., p} and a set of unordered pairs E representing edges between the vertices. The pairwise UGMs over X corresponding to G can be written as the following exponential family distribution: P(X; θ) ∝exp ∑ s∈V θsφs(Xs) + ∑ (s,t)∈E θstϕst(Xs, Xt) . (1) In such a pairwise model, (Xs, Xt) are conditionally independent (given the rest of the variables) if and only if the weight θst is zero. The most popular instances of pairwise UGMs are Gaussian graphical models (GGMs) [19, 2] for real-valued random variables and Ising (or Potts) models [15] for binary or finite nominal discrete random variables. More broadly, in order to derive multivariate graphical models from univariate exponential family distributions (such as the Gaussian, binomial/multinomial, Poisson, exponential distributions, etc.), the exponential family graphical models (EFGMs) [27, 21] were proposed as a unified framework to learn UGMs with node-wise conditional distributions arising from generalized linear models (GLMs). 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. 1.1 Overview of contribution A fundamental issue that arises in UGMs is to specify sufficient statistics, i.e., {φs(Xs), ϕst(Xs, Xt)}, for modeling the interactions among variables. It is noteworthy that most prior pairwise UGMs use pairwise product of variables (or properly transformed variables) as pairwise sufficient statistics [16, 11, 27]. This is clearly restrictive in modern data analysis tasks where the underlying pairwise interactions among variables are more often than not highly complex and unknown a prior. The goal of this work is to remove such a restriction and explore the feasibility (in theory and practice) of defining sufficient statistics in an additive formulation to approximate the underlying unknown sufficient statistics. To this end, we consider the following Additive Exponential Family Graphical Model (AdEFGM) distribution with joint density function: P(X; f) = exp ∑ s∈V fs(Xs) + ∑ (s,t)∈E fst(Xs, Xt) −A(f) , (2) where fs : X →R and fst(·, ·) : X 2 →R are respectively node-wise and pairwise statistics, and A(f) := log ∫ X p exp {∑ s∈V fs(Xs) + ∑ (s,t)∈E fst(Xs, Xt) } dX is the log-partition function. We require the condition A(f) < ∞holds so that the definition of probability is valid. In this paper, we assume the formulations of sufficient statistics fs and fst are unknown but they admit linear representations over two sets of pre-fixed basis functions {φk(·), k = 1, 2, ..., q} and {ϕl(·, ·), l = 1, 2, ..., r}, respectively. That is, fs(Xs) = q ∑ k=1 θs,kφk(Xs), fst(Xs, Xt) = r ∑ l=1 θst,lϕl(Xs, Xt), (3) where q and r are the truncation order parameters. In the formulation (3), the choice of basis and their sizes is flexible and task-dependent. For instance, if the mapping functions fs and fst are periodic, then we can choose {φk(·)} as 1-D Fourier basis and {ϕl(·, ·)} as 2-D Fourier basis. As another instance, the basis {ϕl} can be chosen as multiple kernels which are commonly used in computer vision tasks. Specially, when q = r = 1, ϕl(Xs, Xt) = XsXt and φk(Xs) is fixed as certain parametric function, AdEFGM reduces to the standard EFGM [27, 21]. In general cases, by imposing an additive structure on the sufficient statistics fs and fst, AdEFGM is expected to be able to capture more complex interactions among variables beyond pairwise product. As the core contribution of this paper, we propose two ℓ2,1-norm regularized maximum likelihood estimation (MLE) estimators to learn the weights of AdEFGM in high dimensional settings. The first estimator is formulated as an ℓ2,1-norm regularized MLE to jointly estimate all the parameters in the model. The second estimator is formulated as an ℓ2,1-norm regularized node-wise conditional MLE to estimate the parameters associated with each node individually. Theoretically, we prove that under mild conditions the joint MLE estimator achieves convergence rate O(( √ (2|E| + p) ln p/n) where |E| while the node-wise conditional estimator achieves convergence rate O( √ (d + 1) ln p/n) in which d is the degree of the underlying graph G. Computationally, we propose a Monte-Carlo approximation scheme to efficiently optimize the estimators via proximal gradient descent methods. We conduct numerical studies on simulated and real data to support our claims. The simulation results confirm that, when the data are drawn from an underlying UGMs with highly nonlinear sufficient statistics, our estimators significantly outperform GGMs and Nonparanormal [10] estimators in most cases. The experimental results on a stock price data show that our estimators are able to recover more accurate category links among stocks than GMMs and Nonparanormal estimators. 1.2 Related work In order to model random variables beyond parametric UGMs such as GGMs and Ising models, researchers recently investigated semi-parametric/nonparametric extensions of these parametric models. The Nonparanormal [11] and copula-based methods [5] are semi-parametric graphical models which assume that data is Gaussian after applying a monotone transformation. More broadly, one could learn transformations of the variables and then fit any parametric UGMs (like EFGMs) over the transformed variables. In [10, 26], two rank-based estimators were used to estimate correlation matrix and then fit the GGMs. In [24], a semi-parametric method was proposed to fit the conditional 2 means of the features with an arbitrary additive formulation. The Semi-EFGM proposed in [28] is a semi-parametric rank-based conditional estimator for exponential family graphical models. In [1], a kernel method was proposed for learning the structure of graphical models by treating variables as Gaussians in a mapped high-dimensional feature space. In [7], Gu proposed a functional minimization framework to estimate the nonparametric model (1) over a Reproducing Hilbert Kernel Space (RKHS). Nonparametric exponential family graphical models based on score matching loss were investigated in [9, 20]. The forest density estimation [8] is a fully nonparametric method for estimating UGMs with structure restricted to be a forest. In contrast to all these existing semiparametric/nonparametric models, our approach is novel in model definition and computation: we impose a simple additive structure on sufficient statistics to describe complex interactions between variables and use Monte-Carlo approximation to estimate the intractable normalization constant for efficient optimization. 1.3 Notation and organization Notation Let θ = {θs,k, θst,l : s ∈V, k = 1, 2, .., , (s, t) ∈V 2, s ̸= t, l = 1, 2, ...} be a vector of parameters associated with AdEFGM and G = {{(s, k)}k, {(st, l)}l : s ∈V, (s, t) ∈V 2, s ̸= t} be a group induced by the additive structures of nodes and edges. We conventionally define the following grouped-norm related notations: ∥θ∥2,1 = ∑ g∈G ∥θg∥, ∥θ∥2,∞= maxg∈G ∥θg∥, supp(θ, G) = {g ∈G : ∥θg∦= 0} and ∥θ∥2,0 = |supp(θ, G)|. For any S ⊆G, these notations can be defined restrictively over θS. We denote ¯S = G \ S the complement of S in G. Organization. The remaining of this paper is organized as follows: In §2, we present two maximum likelihood estimators for learning the model parameters of AdEFGM. The statistical guarantees of the proposed estimators are analyzed in §3. Monte-Carlo simulations and experimental results on real stock price data are presented in §4. Finally, we conclude this paper in §5. Due to space limit, all the technical proofs of theoretical results are deferred to an appendix section which is included in the supplementary material. 2 ℓ2,1-norm Regularized MLE for AdEFGM In this section, we investigate the problem of estimating the parameters of AdEFGM in high dimensional settings. By substituting (3) into (2), the distribution of an AdEFGM can be converted to the following form: P(X; θ) = exp {B(X; θ) −A(θ)} , (4) where θ = {θs,k, θst,l}, and B(X; θ) := ∑ s∈V,k θs,kφk(Xs) + ∑ (s,t)∈E,l θst,lϕl(Xs, Xt), A(θ) := log ∫ X p exp {B(X; θ)} dX. Suppose we have n i.i.d. samples Xn = {X(i)}n i=1 drawn from the following AdEFGM with true parameters θ∗: P(X; θ∗) = exp {B(X; θ∗) −A(θ∗)} . (5) An important goal of graphical model learning is to estimate the true parameters θ∗from the observed data Xn. The more accurate parameter estimation is, the more accurate we are able to recover the underlying true graph structure. We next propose two ℓ2,1-norm regularized maximum likelihood estimation (MLE) methods for joint and node-conditional learning of parameters, respectively. 2.1 Joint MLE estimation Given the sample set Xn = {X(i)}n i=1, the negative log-likelihood of the joint distribution (5) is: L(θ; Xn) = −1 n n ∑ i=1 B(X(i); θ) + A(θ). It is trivial to verify L(θ; Xn) has the following first order derivative (see, e.g., [25]): ∂L ∂θs,k = Eθ[φk(Xs)] −1 n n ∑ i=1 φk(X(i) s ), ∂L ∂θst,l = Eθ[ϕl(Xs, Xt)] −1 n n ∑ i=1 ϕl(X(i) s , X(i) t ), (6) 3 where the expectation Eθ[·] is taken over the joint distribution (2). Also, it is well known that L(θ; Xn) is convex in θ. In order to estimate the parameters which are expected to be sparse in edge level due to the potential sparse structure of graph, we consider the following ℓ2,1-norm regularized MLE estimator: ˆθn = arg min θ {L(θ; Xn) + λn∥θ∥2,1} , (7) where ∥θ∥2,1 = ∑ s∈V (∑q k=1 θ2 s,k )1/2 + ∑ (s,t)∈V 2,s̸=t (∑r l=1 θ2 st,l )1/2 is the ℓ2,1-norm with respect to the basis statistics and λn > 0 is the regularization strength parameter dependent on n. The ℓ2,1-norm penalty is used to promote edgewise sparsity as the graph structure is expected to be sparse in high dimensional settings. 2.2 Node-conditional MLE estimation Recent state of the art methods for learning UGMs suggest a natural procedure deriving multivariate graphical models from univariate distributions [12, 15, 27]. The common idea in these methods is to learn the graph structure by estimating node-neighborhoods, or by fitting the node-conditional distribution of each individual node conditioned on the rest of the nodes. Indeed, these node-wise fitting methods have been shown to have strong statistical guarantees and attractive computational performance. Inspired by these approaches, we propose an alternative estimator to estimate the weights of sufficient statistics associated with each individual node. With a slight abuse of notation, we denote θs a subvector of θ associated with node s, i.e., θs := {θs,k | k = 1, ..., q} ∪{θst,l | t ∈N(s), l = 1, ..., r}, where N(s) is the neighborhood of s. Given the joint distribution (4), it is easy to show that the conditional distribution of Xs given the rest variables, X\s, is written by: P(Xs | X\s; θs) = exp { C(Xs | X\s; θs) −D(X\s; θs) } , (8) where C(Xs | X\s; θs) := ∑ k θs,kφk(Xs) + ∑ t∈N(s),l θst,lϕl(Xs, Xt), and D(X\s; θs) := log ∫ X exp { C(Xs | X\s; θs) } dXs is the log-partition function which ensures normalization. We note that the condition A(θ) < ∞for the joint log-partition function implies D(X\s; θs) < ∞. In order to estimate the parameters associated with a node, we consider using the sparsity regularized conditional maximum likelihood estimation. Given n independent samples Xn drawn from (5), we can write the negative log-likelihood of the conditional distribution as: ˜L(θs; Xn) = 1 n n ∑ i=1 { −C(X(i) s | X(i) \s ; θs) + D(X(i) \s ; θs) } . It is standard that ˜L(θs; Xn) is convex with respect to θs and it has the following first-order derivative: ∂˜L(θs; Xn) ∂θs,k = 1 n n ∑ i=1 { −φk(X(i) s ) + Eθs[φk(Xs) | X(i) \s ] } , ∂˜L(θs; Xn) ∂θst,l = 1 n n ∑ i=1 { −ϕl(X(i) s , X(i) t ) + Eθs[ϕl(Xs, X(i) t ) | X(i) \s ] } , (9) where the expectation Eθs[· | X\s] is taken over the node-wise conditional distribution (8). Let us consider the following ℓ2,1-norm regularized conditional MLE formulation associated with the variable Xs: ˆθn s = arg min θs { ˜L(θs; Xn) + λn∥θs∥2,1 } , (10) where ∥θs∥2,1 = (∑q k=1 θ2 s,k )1/2 +∑ t̸=s (∑r l=1 θ2 st,l )1/2 is the grouped ℓ2,1-norm with respect to the node-wise and pairwise basis associated with s and λn > 0 controls the regularization strength. 4 2.3 Computation via Monte-Carlo approximation We consider using proximal gradient descent methods [22] to solve the composite optimization problems in (7) and (10). For both estimators, the major computational overhead is to iteratively calculate the expectation terms involved in the gradients ∇L(θ; Xn) and ∇˜L(θs; Xn). In general, these expectation terms have no close-form for exact calculation and sampling methods such as importance sampling and MCMC are usually needed for approximate estimation. There are, however, two challenging issues with such a sampling based optimization procedure: (1) the multivariate sampling methods typically suffer from high computational cost even when the dimensionality p is moderately large; and (2) the non-vanishing sampling error of gradient will accumulate during the iteration which according to the results in [18] will deteriorate the overall convergence performance. Obviously, the main source of these challenges is caused by the intractable log-partition terms appeared in the estimators. To more efficiently apply the first-order methods without suffering from iterative sampling and error accumulation, it is a natural idea to replace the log-partition terms by a Monte-Carlo approximation and minimize the resulting approximated formulation. Taking the joint estimator (7) as an example, we resort to the basic importance sampling method to approximately estimate the log-partition term A(θ) = log ∫ X p exp {B(X; θ)} dX. Assume we have m i.i.d. samples Ym = {Y (j)}m j=1 drawn from a random vector Y ∈X p with known probability density P(Y ). Given θ, an importance sampling estimate of exp{A(θ)} is given by exp{ ˆA(θ; Ym)} = 1 m m ∑ j=1 exp { B(Y (j); θ) } P(Y (j)) . We consider the following Monte-Carlo approximation to the estimator (7): ˆˆθn = arg min θ { ˆL(θ; Xn, Ym) + λn∥θ∥2,1 } , (11) where ˆL(θ; Xn, Ym) = −1 n ∑n i=1 B(X(i); θ) + ˆA(θ; Ym). Since the random samples Ym are fixed in (11), the sampling operation can be avoided in the computation of ∇ˆL(θ; Xn, Ym). Concerning the accuracy of the approximate estimator (11), the following result guarantees that, with high probability, the minimizer of the approximate estimator (11) is suboptimal to the population estimator (7) with suboptimality O(1/√m). A proof of this proposition is provided in A.1 (see the supplementary material). Proposition 1. Assume that P(Y ) > 0. Then the following inequality holds with high probability: L(ˆˆθn; Xn)+λn∥ˆˆθn∥2,1 ≤L(ˆθn; Xn)+λn∥ˆθn∥2,1+ 2.58ˆσ ( exp{−A(ˆˆθn} + exp{−ˆA(ˆθn; Ym)} ) √m , where ˆσn = 1 m ∑m j=1 ( exp{B(Y (j);ˆθn)} P(Y (j)) −exp{ ˆA(ˆθn; Ym)} )2 . A similar Monte-Carlo approximation strategy can be applied to the node-wise MLE estimator (10). 3 Statistical Analysis In this section, we provide statistical guarantees on parameter estimation error for the joint MLE estimator (7) and the node-conditional estimator (10). In large picture, our analysis follows the techniques presented in [13, 30] by specifying the conditions under which these techniques can be applied to our setting. 3.1 Analysis of the joint estimator We are interested in the concentration bounds of the random variables defined by Zs,k := φk(Xs) −Eθ∗[φk(Xs)], Zst,l := ϕl(Xs, Xt) −Eθ∗[ϕl(Xs, Xt)], 5 where the expectation Eθ∗[·] is taken over the underlying true distribution (5). By the “law of the unconscious statistician” we have E[Zs,k] = E[Zst,l] = 0. That is, {Zs,k} and {Zst,l} are zeromean random variables. We introduce the following technical condition on {Zs,k, Zst,l} which we will show to guarantee the gradient ∇L(θ∗; Xn) vanishes exponentially fast, with high probability, as sample size increases. Assumption 1. For all (s, k) and all (s, t, l), we assume that there exist constants σ > 0 and ζ > 0 such that for all |η| ≤ζ, E[exp{ηZs,k}] ≤exp { σ2η2/2 } , E[exp{ηZst,l}] ≤exp { σ2η2/2 } . This assumption essentially imposes an exponential-type bound on the moment generating function of the random variables Zs,k, Zst,l. It is well known that the Hessian ∇2L(θ; Xn) is positive semidefinite at any θ and it is independent on the sample set Xn. We also need the following condition which guarantees the restricted positive definiteness of ∇2L(θ; Xn) over certain low dimensional subspace when θ is in the vicinity of θ∗. Assumption 2 (Locally Restricted Positive Definite Hessian). Let S = supp(θ∗; G). There exist constants δ > 0 and β > 0 such that for any θ ∈{∥θ−θ∗∥≤δ}, the inequality ϑ⊤∇2L(θ; Xn)ϑ ≥ β∥ϑ∥2 holds for any ϑ ∈CS := {∥θ ¯S∥2,1 ≤3∥θS∥2,1}. Assumption 2 requires that the Hessian ∇2L(θ; Xn) is positive definite in the cone CS when θ lies in a local ball centered at θ∗. This condition is a specification of the concept restricted strong convexity [30] to AdEFGM. Remark 1 (Minimal Representation). We say an AdEFGM has minimal representation if there is a unique parameter vector θ associated with the distribution (4). This condition equivalently requires that there exists no non-zero ϑ such that B(X; ϑ) is equal to an absolute constant. This implies that for any θ and for all non-zero ϑ, Varθ [B(X; ϑ)] = ϑ⊤∇2L(θ; Xn)ϑ > 0. If AdEFGM has minimal representation at θ∗, then there must exist sufficiently small constants δ > 0 and β > 0 such that for any θ ∈{∥θ −θ∗∥≤δ}, ϑ⊤∇2L(θ; Xn)ϑ ≥β∥ϑ∥2. Therefore, Assumption 2 holds true when AdEFGM has minimal representation at θ∗. The following theorem is our main result on the estimation error of the joint MLE estimator (7). A proof of this result is provided in Appendix A.2 in the supplementary material. Theorem 1. Assume that the conditions in Assumption 1 and Assumption 2 hold. If sample size n satisfies n > max {6 max{q, r} ln p σ2ζ2 , 54c2 0σ2 max{q, r}∥θ∗∥2,0 ln p δ2β2 } , then with probability at least 1 −2 max{q, r}p−1, the following inequality holds: ∥ˆθn −θ∗∥≤3c0β−1σ √ 6 max{q, r}∥θ∗∥2,0 ln p/n. Remark 2. The main message Theorem 1 conveys is that when n is sufficiently large, the estimation error ∥ˆθn −θ∗∥vanishes at the order of O( √ max{q, r}(2|E| + p) ln p/n) with high probability. This convergence rate matches the results obtained in [17, 16] for GGMs and the results in [10, 26] for Nonparanormal. 3.2 Analysis of the node-conditional estimator For the node-conditional estimator (10), we study the rate of convergence of the parameter estimation error ∥ˆθn s −θ∗ s∥as a function of sample size n. We need Assumption 1 and the following assumption in our analysis. Assumption 3. For any node s, let S = supp(θ∗ s; G). There exist constants ˜δ > 0 and ˜β > 0 such that for any θs ∈{∥θs −θ∗ s∥< ˜δ}, the inequality ϑ⊤ s ∇2 ˜L(θs; Xn)ϑs ≥˜β∥ϑs∥2 holds for any ϑs ∈˜CS := {∥(θs) ¯S∥2,1 ≤3∥(θs)S∥2,1}. 6 The following is our main result on the convergence rate of node-conditional estimation error ∥ˆθn s − θ∗ s∥. A proof of this result is provided in Appendix A.3 in the supplementary material. Theorem 2. Assume that the conditions in Assumption 1 and Assumption 3 hold. If sample size n satisfies n > max {6 max{q, r} ln p σ2ζ2 , 216˜c2 0˜σ2 max{q, r}∥θ∗ s∥2,0 ln p δ2 ˜β2 } , then with probability at least 1 −4 max{q, r}p−2, the following inequality holds: ∥ˆθn s −θ∗ s∥≤6˜c0 ˜β−1σ √ 6 max{q, r}∥θ∗s∥2,0 ln p/n. Remark 3. Theorem 2 indicates that with overwhelming probability, the estimation error ∥ˆθn s −θ∗ s∥= O( √ (d + 1) ln p)/n) where d is the degree of the underlying graph, i.e., d = maxs∈V ∥θ∗ s∥2,0 −1. We may combine the parameter estimation errors from all the nodes as a global measurement of accuracy. Indeed, by Theorem 2 and union of probability we get that maxs∈V ∥ˆθn s −θ∗ s∥= O( √ (d + 1) ln p/n) holds with probability at least 1−4 max{q, r}p−1. This estimation error bound matches those for GGMs with neighborhood-selection-type estimators [29]. 4 Experiments This section is devoted to showing the actual learning performance of AdEFGM. We first investigate graph structure recovery accuracy using simulation data (for which we know the ground truth), and then we apply our method to a stock price data for inferring the statistical dependency among stocks. 4.1 Monte-Carlo simulation This is a proof-of-concept experiment. The purpose is to confirm that when the pairwise interactions of the underlying graphical models are highly nonlinear and unknown a prior, our additive estimator will be significantly superior to existing parametric/semi-parametric graphical models for inferring the structure of graphs. The numerical results of AdEFGM reported in this experiment are obtained by the joint MLE estimator in (7). Simulated data Our simulation study employs a graphical model of which the edges are generated independently with probability P. We will consider the model under different levels of sparsity by adjusting the probability P. For simplicity purpose, we assume fs(Xs) ≡1 and consider a nonlinear pairwise interaction function fst(Xs, Xt) = cos(π(Xs −Xt)/5). We fit the data to the additive model (4) with a 2-D Fourier basis of size 8. Using Gibbs sampling, we generate a training sample of size n from the true graphical model, and an independent sample of the same size from the same distribution for tuning the strength parameter λn. We compare performance for n = 200, varying values of p ∈{50, 100, 150, 200, 250, 300}, and different sparsity levels under P = {0.02, 0.05, 0.1}, replicated 10 times for each configuration. Baselines We compare the performance of our estimator to Graphical Lasso [6] as a GGM estimator and SKEPTIC [10] as a Nonparanormal estimator. In our implementation, we use a version of SKEPTIC with Kendall’s tau to infer the correlation. Evaluation metric To evaluate the support recovery performance, we use the standard F-score from the information retrieval literature. The larger F-score is, the better the support recovery performance. The numerical values over 10−3 in magnitude are considered to be nonzero. Results Figure 1 shows the support recovery F-scores of the considered methods on the synthetic data. From this group of results we can observe that by using 2-D Fourier basis to approximate the unknown cosine distance function, AdEFGM is able to more accurately recover the underlying graph structure than the other two considered methods. The advantage of AdEFGM illustrated here is as expected because it is designed to automatically learn the unknown complex pairwise interactions while GGM and Nonparanormal are restrictive to certain UGMs with known sufficient statistics. 4.2 Stock price data We further study the performance of AdEFGM on a stock price data. This data contains the historical prices of S&P500 stocks over 5 years, from January 1, 2008 to January 1, 2013. By taking out the 7 50 100 150 200 250 300 0 0.2 0.4 0.6 0.8 1 Dimension p Recovery F−score Cosine Distance AdEFGM GGM Nonparanormal 50 100 150 200 250 300 0 0.2 0.4 0.6 0.8 1 Dimension p Recovery F−score Cosine Distance AdEFGM GGM Nonparanormal 50 100 150 200 250 300 0 0.2 0.4 0.6 0.8 1 Dimension p Recovery F−score Cosine Distance AdEFGM GGM Nonparanormal Figure 1: Simulated data: Support recovery F-score curves. Left panels: P = 0.02, Middle panels: P = 0.05, Right panels: P = 0.1. 2 4 6 8 10 x 10 4 0 0.2 0.4 0.6 0.8 1 Number of links Link Precision AdEFGM GGM Nonparanormal 2 4 6 8 10 x 10 4 0 0.2 0.4 0.6 0.8 1 Number of links Link Recall AdEFGM GGM Nonparanormal 2 4 6 8 10 x 10 4 0 0.2 0.4 0.6 Number of links Link F−score AdEFGM GGM Nonparanormal Figure 2: Stock price data S&P500: Category link precision, recall and F-score curves. stocks with less than 5 years of history, we end up with 465 stocks, each having daily closing prices over 1,260 trading days. The prices are first adjusted for dividends and splits and the used to calculate daily log returns. Each day’s return can be represented as a point in R465. To apply AdEFGM to this data, we consider the general model (4) with the 2-D Fourier basis being used to approximate the pairwise interaction between stocks Xs and Xt. Since the category information of S&P500 is available, we measure the performance by Precision, Recall and F-score of the top k links (edges) on the constructed graph. A link is regarded as true if and only if it connects two nodes belonging to the same category. We use the joint MLE estimator for this experiment. Figure 2 shows the curves of precision, recall and F-score as functions of k in a wide range [103, 105]. It is apparent that AdEFGM significantly outperforms GGM and Nonparanormal for identifying correct category links. This result suggests that the interactions among the S&P500 stocks are highly nonlinear. 5 Conclusions In this paper, we proposed and analyzed AdEFGMs as a generic class of additive undirected graphical models. By expressing node-wise and pairwise sufficient statistics as linear representations over a set of basis statistics, AdEFGM is able to capture complex interactions among variables which are not uncommon in modern engineering applications. We investigated two types of ℓ2,1-norm regularized MLE estimators for joint and node-conditional high dimensional estimation. Based on our theoretical justification and empirical observation, we can draw the following two conclusions: 1) the ℓ2,1-norm regularized AdEFGM learning is a powerful tool for inferring pairwise exponential family graphical models with unknown arbitrary sufficient statistics; and 2) the extra flexibility gained by AdEFGM comes at almost no cost of statistical and computational efficiency. Acknowledgments Xiao-Tong Yuan and Ping Li were partially supported by NSF-Bigdata-1419210, NSF-III-1360971, ONR-N00014-13-1-0764, and AFOSR-FA9550-13-1-0137. Xiao-Tong Yuan is also partially supported by NSFC-61402232, NSFC-61522308, and NSFJP-BK20141003. Tong Zhang is supported by NSF-IIS-1407939 and NSF-IIS-1250985. Qingshan Liu is supported by NSFC-61532009. Guangcan Liu is supported by NSFC-61622305, NSFC-61502238 and NSFJP-BK20160040. 8 References [1] F. Bach and M. Jordan. Learning graphical models with mercer kernels. In Proceedings of the 16th Annual Conference on Neural Information Processing Systems (NIPS’02), 2002. [2] O. Banerjee, L. E. Ghaoui, and A. d’Aspremont. Model selection through sparse maximum likelihood estimation for multivariate gaussian or binary data. JMLR, 9:485–516, 2008. [3] R. G. Baraniuk, M. Davenport, R. A. DeVore, and M. Wakin. A simple proof of the restricted isometry property for random matrices. Constructive Approximation, 28(3):253–263, 2008. [4] E. J. Candès, Y. C. Eldarb, D. Needella, and P. Randallc. Compressedsensing with coherent and redundantdictionarie. Applied and Computational Harmonic Analysis, 31(1):59–73, 2011. [5] A. Dobra and A. Lenkoski. Copula gaussian graphical models and their application to modeling functional disability data. The Annals of Applied Statistics, 5:969–993, 2011. [6] J. Friedman, T. Hastie, and R. Tibshirani. Sparse inverse covariance estimation with the graphical lasso. Biostatistics, 9(3):432–441, 2008. [7] C. Gu, Y. Jeon, and Y. Lin. Nonparametric density estimation in high-dimensions. Statistica Sinica, 23:1131–1153, 2013. [8] J. Lafferty, H. Liu, and L. Wasserman. Sparse nonparametric graphical models. Statistical Science, 27(4):519–537, 2012. [9] L. Lin, M. Drton, A. Shojaie, et al. Estimation of high-dimensional graphical models using regularized score matching. Electronic Journal of Statistics, 10(1):806–854, 2016. [10] H. Liu, F. Han, M. Yuan, J. Lafferty, and L. Wasserman. High dimensional semiparametric gaussian copula graphical models. Annals of Statistics, 40(4):2293–2326, 2012. [11] H. Liu, J. Lafferty, and L. Wasserman. The nonparanormal: Semiparametric estimation of high dimensional undirected graphs. Journal of Machine Learning Research, 10:2295–2328, 2009. [12] N. Meinshausen and P. Bühlmann. High-dimensional graphs and variable selection with the lasso. Annals of Statistics, 34(3):1436–1462, 2006. [13] S. N. Negahban, P. Ravikumar, M. J. Wainwright, and B. Yu. A unified framework for high-dimensional analysis of m-estimators with decomposable regularizers. Statistical Science, 27(4):538–557, 2012. [14] A. B. Owen. Monte Carlo theory, methods and examples. 2013. [15] P. Ravikumar, M. Wainwright, and J. Lafferty. High-dimensional ising model selection using l1regularized logistic regression. Annals of Statistics, 38(3):1287–1319, 2010. [16] P. Ravikumar, M. J. Wainwright, G. Raskutti, and B. Yu. High-dimensional covariance estimation by minimizing ℓ1-penalized log-determinant divergence. Electronic Journal of Statistics, 5:935–980, 2011. [17] A. J. Rothman, P. J. Bickel, E. Levina, and J. Zhu. Sparse permutation invariant covariance estimation. Electronic Journal of Statistics, 2:494–515, 2008. [18] M. Schmidt, N. L. Roux, and F. R. Bach. Convergence rates of inexact proximal-gradient methods for convex optimization. In Proceedings of the 25th Annual Conference on Neural Information Processing Systems (NIPS’11), pages 1458–1466, 2011. [19] T. P. Speed and H. T. Kiiveri. Gaussian markov distributions over finite graphs. Annals of Statistics, 14:138–150, 1986. [20] S. Sun, M. Kolar, and J. Xu. Learning structured densities via infinite dimensional exponential families. In Proceedings of the 29th Annual Conference on Neural Information Processing Systems (NIPS’15), 2015. [21] W. Tansey, O. H. M. Padilla, A. S. Suggala, and P. Ravikumar. Vector-space markov random fields via exponential families. In Proceedings of the 32nd International Conference on Machine Learning (ICML’15), pages 684–692, 2015. [22] P. Tseng. On accelerated proximal gradient methods for convex-concave optimization. submitted to SIAM Journal of Optimization, 2008. [23] R. Vershynin. Introduction to the non-asymptotic analysis of random matrices. CoRR, arxiv: abs/1011.3027, 2011. [24] A. Voorman, A. Shojaie, and D. Witten. Graph estimation with joint additive models. Biometrika, 101(1):85–101, 2014. [25] M. Wainwright and M. Jordan. Graphical models, exponential families, and variational inference. Foundations and Trends in Machine Learning, 1(1-2):1–305, 2008. [26] L. Xue and H. Zou. Regularized rank-based estimation of high-dimensional nonparanormal graphical models. Annals of Statistics, 40(5):2541–2571, 2012. [27] E. Yang, P. Ravikumar, G. I. Allen, and Z. Liu. Graphical models via univariate exponential family distributions. Journal of Machine Learning Research, 16:3813–3847, 2015. [28] Z. Yang, Y. Ning, and H. Liu. On semiparametric exponential family graphical models. arXiv preprint arXiv:1412.8697, 2014. [29] M. Yuan. High dimensional inverse covariance matrix estimation via linear programming. Journal of Machine Learning Research, 11:2261–2286, 2010. [30] C.-H. Zhang and T. Zhang. A general framework of dual certificate analysis for structured sparse recovery problems. CoRR, arxiv: abs/1201.3302, 2012. 9 | 2016 | 527 |
6,469 | Disentangling factors of variation in deep representations using adversarial training Michael Mathieu, Junbo Zhao, Pablo Sprechmann, Aditya Ramesh, Yann LeCun 719 Broadway, 12th Floor, New York, NY 10003 {mathieu, junbo.zhao, pablo, ar2922, yann}@cs.nyu.edu Abstract We introduce a conditional generative model for learning to disentangle the hidden factors of variation within a set of labeled observations, and separate them into complementary codes. One code summarizes the specified factors of variation associated with the labels. The other summarizes the remaining unspecified variability. During training, the only available source of supervision comes from our ability to distinguish among different observations belonging to the same class. Examples of such observations include images of a set of labeled objects captured at different viewpoints, or recordings of set of speakers dictating multiple phrases. In both instances, the intra-class diversity is the source of the unspecified factors of variation: each object is observed at multiple viewpoints, and each speaker dictates multiple phrases. Learning to disentangle the specified factors from the unspecified ones becomes easier when strong supervision is possible. Suppose that during training, we have access to pairs of images, where each pair shows two different objects captured from the same viewpoint. This source of alignment allows us to solve our task using existing methods. However, labels for the unspecified factors are usually unavailable in realistic scenarios where data acquisition is not strictly controlled. We address the problem of disentaglement in this more general setting by combining deep convolutional autoencoders with a form of adversarial training. Both factors of variation are implicitly captured in the organization of the learned embedding space, and can be used for solving single-image analogies. Experimental results on synthetic and real datasets show that the proposed method is capable of generalizing to unseen classes and intra-class variabilities. 1 Introduction A fundamental challenge in understanding sensory data is learning to disentangle the underlying factors of variation that give rise to the observations [1]. For instance, the factors of variation involved in generating a speech recording include the speaker’s attributes, such as gender, age, or accent, as well as the intonation and words being spoken. Similarly, the factors of variation underlying the image of an object include the object’s physical representation and the viewing conditions. The difficulty of disentangling these hidden factors is that, in most real-world situations, each can influence the observation in a different and unpredictable way. It is seldom the case that one has access to rich forms of labeled data in which the nature of these influences is given explicitly. Often times, the purpose for which a dataset is collected is to further progress in solving a certain supervised learning task. This type of learning is driven completely by the labels. The goal is for the learned representation to be invariant to factors of variation that are uninformative to the task at hand. While recent approaches for supervised learning have enjoyed tremendous success, their performance comes at the cost of discarding sources of variation that may be important for solving 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. other, closely-related tasks. Ideally, we would like to be able to learn representations in which the uninformative factors of variation are separated from the informative ones, instead of being discarded. Many other exciting applications require the use of generative models that are capable of synthesizing novel instances where certain key factors of variation are held fixed. Unlike classification, generative modeling requires preserving all factors of variation. But merely preserving these factors is not sufficient for many tasks of interest, making the disentanglement process necessary. For example, in speech synthesis, one may wish to transfer one person’s dialog to another person’s voice. Inverse problems in image processing, such as denoising and super-resolution, require generating images that are perceptually consistent with corrupted or incomplete observations. In this work, we introduce a deep conditional generative model that learns to separate the factors of variation associated with the labels from the other sources of variability. We only make the weak assumption that we are able to distinguish between observations assigned to the same label during training. To make disentanglement possible in this more general setting, we leverage both Variational Auto-Encoders (VAEs) [12, 25] and Generative Adversarial Networks (GANs) [9]. 2 Related work There is a vast literature on learning disentangled representations. Bilinear models [26] were an early approach to separate content and style for images of faces and text in various fonts. What-where autoencoders [22, 28] combine discrimination and reconstruction criteria to attempt to recover the factors of variation not associated with the labels. In [10], an autoencoder is trained to separate a translation invariant representation from a code that is used to recover the translation information. In [2], the authors show that standard deep architectures can discover and explicitly represent factors of variation aside those relevant for classification, by combining autoencoders with simple regularization terms during the training. In the context of generative models, the work in [23] extends the Restricted Boltzmann Machine by partitioning its hidden state into distinct factors of variation. The work presented in [11] uses a VAE in a semi-supervised learning setting. Their approach is able to disentangle the label information from the hidden code by providing an additional one-hot vector as input to the generative model. Similarly, [18] shows that autoencoders trained in a semi-supervised manner can transfer handwritten digit styles using a decoder conditioned on a categorical variable indicating the desired digit class. The main difference between these approaches and ours is that the former cannot generalize to unseen identities. The work in [5, 13] further explores the application of content and style disentanglement to computer graphics. Whereas computer graphics involves going from an abstract description of a scene to a rendering, these methods learn to go backward from the rendering to recover the abstract description. This description can include attributes such as orientation and lighting information. While these methods are capable of producing impressive results, they benefit from being able to use synthetic data, making strong supervision possible. Closely related to the problem of disentangling factors of variations in representation learning is that of learning fair representations [17, 7]. In particular, the Fair Variational Auto-Encoder [17] aims to learn representations that are invariant to certain nuisance factors of variation, while retaining as much of the remaining information as possible. The authors propose a variant of the VAE that encourages independence between the different latent factors of variation. The problem of disentangling factors of variation also plays an important role in completing image analogies, the goal of the end-to-end model proposed in [24]. Their method relies on having access to matching examples during training. Our approach requires neither matching observations nor labels aside from the class identities. These properties allow the model to be trained on data with a large number of labels, enabling generalizing over the classes present in the training data. 3 Background 3.1 Variational autoencoder The VAE framework is an approach for modeling a data distribution using a collection of independent latent variables. Let x be a random variable (real or binary) representing the observed data and z a collection of real-valued latent variables. The generative model over the pair (x, z) is given by 2 p(x, z) = p(x | z)p(z), where p(z) is the prior distribution over the latent variables and p(x | z) is the conditional likelihood function. Generally, we assume that the components of z are independent Bernoulli or Gaussian random variables. The likelihood function is parameterized by a deep neural network referred to as the decoder. A key aspect of VAEs is the use of a learned approximate inference procedure that is trained purely using gradient-based methods [12, 25]. This is achieved by using a learned approximate posterior q(z | x) = N(µ, σI) whose parameters are given by another deep neural network referred to as the encoder. Thus, we have z ∼Enc(x) = q(z|x) and ˜x Dec(z) = p(x|z). The parameters of these networks are optimized by minimizing the upper-bound on the expected negative log-likelihood of x, which is given by Eq(z | x)[−log pθ(x | z)] + KL(q(z|x) || p(z)). (1) The first term in (1) corresponds to the reconstruction error, and the second term is a regularizer that ensures that the approximate posterior stays close to the prior. 3.2 Generative adversarial networks Generative Adversarial Networks (GAN) [9] have enjoyed great success at producing realistic natural images [21]. The main idea is to use an auxiliary network Disc, called the discriminator, in conjunction with the generative model, Gen. The training procedure establishes a min-max game between the two networks as follows. On one hand, the discriminator is trained to differentiate between natural samples sampled from the true data distribution, and synthetic images produced by the generative model. On the other hand, the generator is trained to produce samples that confuse the discriminator into mistaking them for genuine images. The goal is for the generator to produce increasingly more realistic images as the discriminator learns to pick up on increasingly more subtle inaccuracies that allow it to tell apart real and fake images. Both Disc and Gen can be conditioned on the label of the input that we wish to classify or generate, respectively [20]. This approach has been successfully used to produce samples that belong to a specific class or possess some desirable property [4, 19, 21]. The training objective can be expressed as a min-max problem given by min Gen max Disc Lgan, where Lgan = log Disc(x, id) + log(1 −Disc(Gen(z, id), id)). (2) where pd(x, id) is the data distribution conditioned on a given class label id, and p(z) is a generic prior over the latent space (e.g. N(0, I)). 4 Model 4.1 Conditional generative model We introduce a conditional probabilistic model admitting two independent sources of variation: an observed variable s that characterizes the specified factors of variation, and a continuous latent variable z that characterizes the remaining variability. The variable s is given by a vector of real numbers, rather than a class ordinal or a one-hot vector, as we intend for the model to generalize to unseen identities. Given an observed specified component s, we can sample z ∼p(z) = N(0, I) and x ∼pθ(x | z, s), (3) in order to generate a new instance x compatible with s. The variables s and z are marginally independent, which promotes disentanglement between the specified and unspecified factors of variation. Again here, pθ(x|z, s) is a likelihood function described by and decoder network, Dec, and the approximate posterior is modeled using an independent Gaussian distribution, qφ(z|x, s) = N(µ, σI), whose parameters are specified via an encoder network, Enc. In this new setting, the variational upper-bound is be given by Eq(z | x,s)[−log pθ(x | z, s)] + KL(q(z | x, s) | p(z)). (4) The specified component s can be obtained from one or more images belonging to the same class. In this work, we consider the simplest case in which s is obtained from a single image. To this end, 3 we define a deterministic encoder fs that maps images to their corresponding specified components. All sources of stochasticity in s come from the data distribution. The conditional likelihood given by (3) can now be written as x ∼pθ(x | z, fs(x′)) where x′ is any image sharing the same label as x, including x itself. In addition to fs, the model has an additional encoder fz that parameterizes the approximate posterior q(z | x, s). It is natural to consider an architecture in which parameters of both encoders are shared. We now define a single encoder Enc by Enc(x) = (fs(x), fz(x)) = (s, (µ, σ) = (s, z), where s is the specified component, and z = (µ, σ) the parameters of the approximate posterior that constitute the unspecified component. To generate a new instance, we synthesize s and z using Dec to obtain ˜x = Dec(s, z). The model described above cannot be trained by minimizing the log-likelihood alone. In particular, there is nothing that prevents all of the information about the observation from flowing through the unspecified component. The decoder could learn to ignore s, and the approximate posterior could map images belonging to the same class to different regions of the latent space. This degenerate solution can be easily prevented when we have access to labels for the unspecified factors of variation, as in [24]. In this case, we could enforce that s be informative by requiring that Dec be able to reconstruct two observations having the same unspecified label after their unspecified components are swapped. But for many real-world scenarios, it is either impractical or impossible to obtain labels for the unspecified factors of variation. In the following section, we explain a way of eliminating the need for such labels. 4.2 Discriminative regularization An alternative approach to preventing the degenerate solution described in the previous section, without the need for labels for the unspecified components, makes use of GANs (3.2). As before, we employ a procedure in which the unspecified components of a pair of observations are swapped. But since the observations need not be aligned along the unspecified factors of variation, it no longer makes sense to enforce reconstruction. After swapping, the class identities of both observations will remain the same, but the sources of variability within their corresponding classes will change. Hence, rather than enforcing reconstruction, we ensure that both observations are assigned high probabilities of belonging to their original classes by an external discriminator. Formally, we introduce the discriminative term given by (2) into the loss given by (5), yielding Eq(z | x,s)[−log pθ(x | z, s)] + KL(q(z | x, s) || p(z)) + λLgan, (5) where λ is a non-negative weight. Recent works have explored combining VAE with GAN [14, 6]. These approaches aim at including a recognition network (allowing solving inference problems) to the GAN framework. In the setting used in this work, GAN is used to compensate the lack of aligned training data. The work in [14] investigates the use of GANs for obtaining perceptually better loss functions (beyond pixels). While this is not the goal of our work, our framework is able to generate sharper images, which comes as a side effect. We evaluated including a GAN loss also for samples, however, the system became unstable without leading to perceptually better generations. An interesting variant could be to use separate discriminator for images generated with and without supervision. 4.3 Training procedure Let x1 and x′ 1 be samples sharing the same label, namely id1, and x2 a sample belonging to a different class, id2. On one hand we want to minimize the upper bound of negative log likelihood of x1 when feeding to the decoder inputs of the form (z1, fs(x1)) and (z1, fs(x′ 1)), where z1 are samples form the approximate posterior q(z|x1). On the other hand, we want to minimize the adversarial loss of samples generated by feeding to the decoder inputs given by (z, fs(x2)), where z is sampled from the approximate posterior q(z|x1). This corresponds to swapping specified and unspecified factors of x1 and x2. We could only use upper bound if we had access to aligned data. As in the GAN setting described in Section 3.2, we alternate this procedure with updates of the adversary network. The diagram of the network is shown in figure 1, and the described training procedure is summarized in on Algorithm 1, in the supplementary material. 4 Enc X1 Enc X1' Enc X2 Dec X11 ~ Dec X11' ~ Dec X12 ~ Dec X 2 ~. Adv Adv Z1 Z1' Z2 S1' S1 S2 N(0,1) X1 L X1 L id(X2) id(X2) Figure 1: Training architecture. The inputs x1 and x′ 1 are two different samples with the same label, whereas x2 can have any label. 5 Experiments Datasets. We evaluate our model on both synthetic and real datasets: Sprites dataset [24], MNIST [15], NORB [16] and the Extended-YaleB dataset [8]. We used Torch7 [3] to conduct all experiments. The network architectures follow that of DCGAN [21] and are described in detail in the supplementary material. Evaluation. To the best of our knowledge, there is no standard benchmark dataset (or task) for evaluating disentangling performance [2]. We propose two forms of evaluation to illustrate the behavior of the proposed framework, one qualitative and one quantitative. Qualitative evaluation is obtained by visually examining the perceptual quality of single-image analogies and conditional images generation. For all datasets, we evaluated the models in four different settings: swapping: given a pair of images, we generate samples conditioning on the specified component extracted from one of the images and sampling from the approximate posterior obtained from the other one. This procedure is analogous to the sampling technique employed during training, described in Section 4.3, and corresponds to solving single-image analogies; retrieval: in order to asses the correlation between the specified and unspecified components, we performed nearest neighbor retrieval in the learned embedding spaces. We computed the corresponding representations for all samples (for the unspecified component we used the mean of the approximate posterior distribution) and then retrieved the nearest neighbors for a given query image; interpolation: to evaluate the coverage of the data manifold, we generated a sequence of images by linearly interpolating the codes of two given test images (for both specified and unspecified representations); conditional generation: given a test image, we generate samples conditioning on its specified component, sampling directly from the prior distribution, p(z). In all the experiments images were randomly chosen from the test set, please see specific details for each dataset. The objective evaluation of generative models is a difficult task and itself subject of current research [27]. Frequent evaluation metrics, such as measuring the log-likelihood of a set of validation samples, are often not very meaningful as they do not correlate to the perceptual quality of the images [27]. Furthermore, the loss function used by our model does not correspond a bound on the likelihood of a generative model, which would render this evaluation less meaningful. As a quantitative measure, we evaluate the degree of disentanglement via a classification task. Namely, we measure how much information about the identity is contained in the specified and unspecified components. MNIST. In this setup, the specified part is simply the class of the digit. The goal is to show that the model is able to learn to disentangle the style from the identity of the digit and to produce satisfactory analogies. We cannot test the ability of the model to generalize to unseen identities. In this case, one could directly condition on a class label [11, 18]. It is still interesting that the proposed model is able to transfer handwriting style without having access to matched examples while still be able to learn a smooth representation of the digits as show in the interpolation results. Results are shown in Figure 2. We observe that the generated images are convincing and particularly sharp, the latter is an “side-effect” produced by the GAN term in our training loss. Sprites. The dataset is composed of 672 unique characters (we refer to them as sprites), each of which is associated with 20 animations [24]. Any image of a sprite can present 7 sources of variation: body type, gender, hair type, armor type, arm type, greaves type, and weapon type. Unlike the work in [24], we do not use any supervision regarding the positions of the sprites. The results obtained for 5 Figure 2: left(a): A visualization grid of 2D MNIST image swapping generation. The top row and leftmost column digits come from the test set. The other digits are generated using z from leftmost digit, and s from the digit at the top of the column. The diagonal digits show reconstructions. Right(b): Interpolation visualization. Digits located at top-left corner and bottom-right corner come from the dataset. The rest digits are generated by interpolating s and z. Like (a), each row has constant a z each column a constant s. Figure 3: left(a): A visualization grid of 2D sprites swapping generation. Same visualization arrangement as in 2(a); right(b): Interpolation visualization. Same arrangement as in 2(b). the swapping and interpolation settings are displayed in Figure 3 while retrieval result are showed in 4. Samples from the conditional model are shown in 5(a). We observe that the model is able to generalize to unseen sprites quite well. The generated images are sharp and single image analogies are resolved successfully. The interpolation results show that one can smoothly transition between identities or positions. It is worth noting that this dataset has a fixed number of discrete positions. Thus, 3(b) shows a reasonable coverage of the manifold with some abrupt changes. For instance, the hands are not moving up from the pixel space, but appearing gradually from the faint background. NORB. For the NORB dataset we used instance identity (rather than object category) for defining the labels. This results in 25 different object identities in the training set and another 25 distinct objects identities in the testing set. As in the sprite dataset, the identities used at testing have never been presented to the network at training time. In this case, however, the small number of identities seen at training time makes the generalization more difficult. In Figure 6 we present results for interpolation and swapping. We observe that the model is able to resolve analogies well. However, the quality of the results are degraded. In particular, classes having high variability (such as planes) are not reconstructed well. Also some of the models are highly symmetric, thus creating a lot of uncertainty. We conjecture that these problems could be eliminated in the presence of more training data. Queries in the case of NORB are not as expressive as with the sprites, but we can still observe good behavior. We refer to these images to the supplementary material. Extended-YaleB. The datasets consists of facial images of 28 individuals taken under different positions and illuminations. The training and testing sets contains roughly 600 and 180 images per individual respectively. Figure 7 shows interpolation and swapping results for a set of testing images. Due to the small number of identities, we cannot test in this case the generalization to unseen identities. We observe that the model is able to resolve the analogies in a satisfactory, position and illumination are transferred correctly although these positions have not been seen at train time for 6 Figure 4: left(a): sprite retrieval querying on specified component; right(b): sprite retrieval querying on unspecified component. Sprites placed at the left of the white lane are used as the query. Figure 5: left(a): sprite generation by sampling; right(b): NORB generation by sampling. Figure 6: left(a): A visualization grid of 2D NORB image swapping generation. Same visualization arrangement as in 2(a); right(b): Interpolation visualization. Same arrangement as in 2(b). these individuals. In the supplementary material we show samples drawn from the conditional model as well as other examples of interpolation and swapping. Quantitative evaluation. We analyze the disentanglement of the specified and unspecified representations, by using them as input features for a prediction task. We trained a two-layer neural network with 256 hidden units to predict structured labels for the sprite dataset, toy category for the NORB dataset (four-legged animals, human figures, airplanes, trucks, and cars) and the subject identity for Extended-YaleB dataset. We used early-stopping on a validation set to prevent overfitting. We report both training and testing errors in Table 1. In all cases the unspecified component is agnostic to the identity information, almost matching the performance of random selection. On the other hand, the specified components are highly informative, producing almost the same results as a classifier directly trained on a discriminative manner. In particular, we observe some overfitting in the NORB dataset. This might also be due to the difficulty of generalizing to unseen identities using a small dataset. Influence of components of the framework. It is worth evaluating the contribution of the different components of the framework. Without the adversarial regularization, the model is unable to learn disentangled representations. It can be verified empirically that the unspecified component is completely ignored, as discussed in Section 4.1. A valid question to ask is if the training of s has be done jointly in an end-to-end manner or could be pre-computed. In Section 4 of the supplementary material we run our setting by using an embedding trained before hand to classify the identities. The model is still able to learned a disentangled representations. The quality of the generated images as well as the analogies are compromised. Better pre-trained embeddings could be considered, for example, enforcing the representation of different images to be close to each other and far from those corresponding to different identities. However, joint end-to-end training has still the advantage of requiring fewer parameters, due to the parameter sharing of the encoders. 7 Figure 7: left(a): A visualization grid of 2D Extended-YaleB face image swapping generation. right(b): Interpolation visualization. See 2 for description. Table 1: Comparison of classification upon z and s. Shown numbers are all error rate. set Sprites NORB Extended-YaleB z s z s z s train 58.6% 5.5% 79.8% 2.6% 96.4% 0.05% test 59.8% 5.2% 79.9% 13.5% 96.4% 0.08% random-chance 60.7% 80.0% 96.4% 6 Conclusions and discussion This paper presents a conditional generative model that learns to disentangle the factors of variations of the data specified and unspecified through a given categorization. The proposed model does not rely on strong supervision regarding the sources of variations. This is achieved by combining two very successful generative models: VAE and GAN. The model is able to resolve the analogies in a consistent way on several datasets with minimal parameter/architecture tuning. Although this initial results are promising there is a lot to be tested and understood. The model is motivated on a general settings that is expected to encounter in more realistic scenarios. However, in this initial study we only tested the model on rather constrained examples. As was observed in the results shown using the NORB dataset, given the weaker supervision assumed in our setting, the proposed approach seems to have a high sample complexity relying on training samples covering the full range of variations for both specified and unspecified variations. The proposed model does not attempt to disentangle variations within the specified and unspecified components. There are many possible ways of mapping a unit Gaussian to corresponding images, in the current setting, there is nothing preventing the obtained mapping to present highly entangled factors of variations. References [1] Yoshua Bengio. Learning deep architectures for AI. Foundations and trends R⃝in Machine Learning, 2(1):1–127, 2009. [2] Brian Cheung, Jesse A. Livezey, Arjun K. Bansal, and Bruno A. Olshausen. Discovering hidden factors of variation in deep networks. CoRR, abs/1412.6583, 2014. [3] Ronan Collobert, Koray Kavukcuoglu, and Clément Farabet. Torch7: A matlab-like environment for machine learning. In BigLearn, NIPS Workshop, number EPFL-CONF-192376, 2011. [4] Emily Denton, Soumith Chintala, Arthur Szlam, and Rob Fergus. Deep generative image models using a laplacian pyramid of adversarial networks. In NIPS, 2015. [5] Alexey Dosovitskiy, Jost Tobias Springenberg, and Thomas Brox. Learning to generate chairs with convolutional neural networks. CoRR, abs/1411.5928, 2014. [6] Vincent Dumoulin, Ishmael Belghazi, Ben Poole, Alex Lamb, Martin Arjovsky, Olivier Mastropietro, and Aaron Courville. Adversarially learned inference. arXiv preprint arXiv:1606.00704, 2016. [7] Harrison Edwards and Amos Storkey. Censoring representations with an adversary. arXiv preprint arXiv:1511.05897, 2015. 8 [8] Athinodoros S Georghiades, Peter N Belhumeur, and David J Kriegman. From few to many: Illumination cone models for face recognition under variable lighting and pose. Pattern Analysis and Machine Intelligence, IEEE Transactions on, 23(6):643–660, 2001. [9] Ian J. Goodfellow, Jean Pouget-Abadie, Mehdi Mirza, Bing Xu, David Warde-Farley, Sherjil Ozair, Aaron C. Courville, and Yoshua Bengio. Generative adversarial networks. NIPS, 2014. [10] Geoffrey E. Hinton, Alex Krizhevsky, and Sida D. Wang. Transforming auto-encoders. In Proceedings of the 21th International Conference on Artificial Neural Networks - Volume Part I, ICANN’11, pages 44–51, Berlin, Heidelberg, 2011. Springer-Verlag. [11] Diederik P Kingma, Shakir Mohamed, Danilo Jimenez Rezende, and Max Welling. Semi-supervised learning with deep generative models. In Advances in Neural Information Processing Systems, pages 3581–3589, 2014. [12] Diederik P Kingma and Max Welling. Auto-encoding variational bayes. arXiv preprint arXiv:1312.6114, 2013. [13] Tejas D Kulkarni, William F Whitney, Pushmeet Kohli, and Josh Tenenbaum. Deep convolutional inverse graphics network. In Advances in Neural Information Processing Systems, pages 2530–2538, 2015. [14] Anders Boesen Lindbo Larsen, Søren Kaae Sønderby, and Ole Winther. Autoencoding beyond pixels using a learned similarity metric. arXiv preprint arXiv:1512.09300, 2015. [15] Yann LeCun, Léon Bottou, Yoshua Bengio, and Patrick Haffner. Gradient-based learning applied to document recognition. Proceedings of the IEEE, 86(11):2278–2324, 1998. [16] Yann LeCun, Fu Jie Huang, and Leon Bottou. Learning methods for generic object recognition with invariance to pose and lighting. In CVPR, 2004. [17] Christos Louizos, Kevin Swersky, Yujia Li, Max Welling, and Richard Zemel. The variational fair autoencoder. ICLR, 2016. [18] Alireza Makhzani, Jonathon Shlens, Navdeep Jaitly, and Ian J. Goodfellow. Adversarial autoencoders. CoRR, abs/1511.05644, 2015. [19] Michaël Mathieu, Camille Couprie, and Yann LeCun. Deep multi-scale video prediction beyond mean square error. ICLR, abs/1511.05440, 2015. [20] Mehdi Mirza and Simon Osindero. Conditional generative adversarial nets. arXiv preprint arXiv:1411.1784, 2014. [21] Alec Radford, Luke Metz, and Soumith Chintala. Unsupervised representation learning with deep convolutional generative adversarial networks. CoRR, abs/1511.06434, 2015. [22] Marc’Aurelio Ranzato, Fu-Jie Huang, Y-Lan Boureau, and Yann LeCun. Unsupervised learning of invariant feature hierarchies with applications to object recognition. In Proc. Computer Vision and Pattern Recognition Conference (CVPR’07). IEEE Press, 2007. [23] Scott Reed, Kihyuk Sohn, Yuting Zhang, and Honglak Lee. Learning to disentangle factors of variation with manifold interaction. In Proceedings of the 31st International Conference on Machine Learning (ICML-14), pages 1431–1439, 2014. [24] Scott E Reed, Yi Zhang, Yuting Zhang, and Honglak Lee. Deep visual analogy-making. In C. Cortes, N. D. Lawrence, D. D. Lee, M. Sugiyama, and R. Garnett, editors, Advances in Neural Information Processing Systems 28, pages 1252–1260. Curran Associates, Inc., 2015. [25] Danilo Jimenez Rezende, Shakir Mohamed, and Daan Wierstra. Stochastic backpropagation and approximate inference in deep generative models. arXiv preprint arXiv:1401.4082, 2014. [26] Joshua B. Tenenbaum and William T. Freeman. Separating style and content with bilinear models. Neural Comput., 12(6):1247–1283, June 2000. [27] Lucas Theis, Aäron van den Oord, and Matthias Bethge. A note on the evaluation of generative models. arXiv preprint arXiv:1511.01844, 2015. [28] Junbo Zhao, Michael Mathieu, Ross Goroshin, and Yann LeCun. Stacked what-where auto-encoders. In ICLR workshop submission, 2016. 9 | 2016 | 528 |
6,470 | Gaussian Processes for Survival Analysis Tamara Fernández Department of Statistics, University of Oxford. Oxford, UK. fernandez@stats.ox.ac.uk Nicolás Rivera Department of Informatics, King’s College London. London, UK. nicolas.rivera@kcl.ac.uk Yee Whye Teh Department of Statistics, University of Oxford. Oxford, UK. y.w.teh@stats.ox.ac.uk Abstract We introduce a semi-parametric Bayesian model for survival analysis. The model is centred on a parametric baseline hazard, and uses a Gaussian process to model variations away from it nonparametrically, as well as dependence on covariates. As opposed to many other methods in survival analysis, our framework does not impose unnecessary constraints in the hazard rate or in the survival function. Furthermore, our model handles left, right and interval censoring mechanisms common in survival analysis. We propose a MCMC algorithm to perform inference and an approximation scheme based on random Fourier features to make computations faster. We report experimental results on synthetic and real data, showing that our model performs better than competing models such as Cox proportional hazards, ANOVA-DDP and random survival forests. 1 Introduction Survival analysis is a branch of statistics focused on the study of time-to-event data, usually called survival times. This type of data appears in a wide range of applications such as failure times in mechanical systems, death times of patients in a clinical trial or duration of unemployment in a population. One of the main objectives of survival analysis is the estimation of the so-called survival function and the hazard function. If a random variable has density function f and cumulative distribution function F, then its survival function S is 1 −F, and its hazard λ is f/S. While the survival function S(t) gives us the probability a patient survives up to time t, the hazard function λ(t) is the instant probability of death given that she has survived until t. Due to the nature of the studies in survival analysis, the data contains several aspects that make inference and prediction hard. One important characteristic of survival data is the presence of many covariates. Another distinctive flavour of survival data is the presence of censoring. A survival time is censored when it is not fully observable but we have an upper or lower bound of it. For instance, this happens in clinical trials when a patient drops out the study. There are many methods for modelling this type of data. Arguably, the most popular is the KaplanMeier estimator [13]. The Kaplan-Meier estimator is a very simple, nonparametric estimator of the survival function. It is very flexible and easy to compute, it handles censored times and requires no-prior knowledge of the nature of the data. Nevertheless, it cannot handle covariates naturally and no prior knowledge can be incorporated. A well-known method that incorporates covariates is the Cox proportional hazard model [3]. Although this method is very popular and useful in applications, a drawback of it, is that it imposes the strong assumption that the hazard curves are proportional and non-crossing, which is very unlikely for some data sets. There is a vast literature of Bayesian nonparametric methods for survival analysis [9]. Some examples include the so-called Neutral-to-the-right priors [5], which models survival curves as e−˜µ((0,t]), where ˜µ is a completely random measure on R+. Two common choices for ˜µ are the Dirichlet process 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. [8] and the beta-Stacy process [20], the latter, being a bit more tractable due its conjugacy. Other alternatives place a prior on the hazard function, one example of this, is the extended gamma process [7]. The weakness of the above methods is that there is no natural nor direct way to incorporate covariates and thus, they have not been extensively used by practitioners of survival analysis. More recently, [4] developed a new model called ANOVA-DDP which mixes ideas from ANOVA and Dirichlet processes. This method successfully incorporates covariates without imposing strong constraints, though it is not clear how to incorporate expert knowledge. Within the context of Gaussian process, a few models has been considered, for instance [14] and [12]. Nevertheless these models fail to go beyond the proportional hazard assumption, which corresponds to one of the aims of this work. Another option is [11], which describes a survival model with non-proportional hazard and time-dependent covariates. Recently, we became aware of the work of [2], which uses a so-called accelerated failure times model. Here, the dependence of the failure times on covariates is modelled by rescaling time, with the rescaling factor modelled as a function of covariates with a Gaussian process prior. This model is different from our proposal, and is more complex to study and to work with. Lastly, another well-known method is Random Survival Forest [10]. This can be seen as a generalisation of Kaplan Meier estimator to several covariates. It is fast and flexible, nevertheless it cannot incorporate expert knowledge and lacks interpretation which is fundamental for survival analysis. In this paper we introduce a new semiparametric Bayesian model for survival analysis. Our model is able to handle censoring and covariates. Our approach models the hazard function as the multiplication of a parametric baseline hazard and a nonparametric part. The parametric part of our model allows the inclusion of expert knowledge and provides interpretability, while the nonparametric part allows us to handle covariates and to amend incorrect or incomplete prior knowledge. The nonparametric part is given by a non-negative function of a Gaussian process on R+. Giving the hazard function λ of a random variable T, we sample from it by simulating the first jump of a Poisson process with intensity λ. In our case, the intensity of the Poisson process is a function of a Gaussian process, obtaining what is called a Gaussian Cox process. One of the main difficulties of working with Gaussian Cox processes is the problem of learning the ‘true’ intensity given the data because, in general, it is impossible to sample the whole path of a Gaussian process. Nevertheless, exact inference was proved to be tractable by [1]. Indeed, the authors developed an algorithm by exploiting a nice trick which allows them to make inference without sampling the whole Gaussian process but just a finite number of points. In this paper, we study basic properties of our prior. We also provide an inference algorithm based in a sampler proposed by [18] which is a refined version of the algorithm presented in [1]. To make the algorithm scale we introduce a random Fourier features to approximate the Gaussian process and we supply the respective inference algorithm. We demonstrate the performance of our method experimentally by using synthetic and real data. 2 Model Consider a continuous random variable T on R+ = [0, ∞), with density function f and cumulative distribution function F. Associated with T, we have the survival function S = 1 −F and the hazard function λ = f/S. The survival function S(t) gives us the probability a patient survives up to time t, while the hazard function λ(t) gives us the instant risk of patient at time t. We define a Gaussian process prior over the hazard function λ. In particular, we choose λ(t) = λ0(t)σ(l(t)), where λ0(t) is a baseline hazard function, l(t) is a centred stationary Gaussian process with covariance function κ, and σ is a positive link function. For our implementation, we choose σ as the sigmoidal function σ = (1 + e−x)−1, which is a quite standard choice in applications. In this way, we generate T as the first jump of the Poisson process with intensity λ, i.e. T has distribution λ(t)e− R t 0 λ(s)ds. Our model for a data set of i.i.d. Ti, without covariates, is l(·) ∼GP(0, κ), λ(t)|l, λ0(t) = λ0(t)σ(l(t)), Ti|λ iid ∼λ(t)e− R Ti 0 λ(s)ds, (1) which can be interpreted as a baseline hazard with a multiplicative nonparametric noise. This is an attractive feature as an expert may choose a particular hazard function and then the nonparametric noise amends an incomplete or incorrect prior knowledge. The incorporation of covariates is discussed later in this section, while censoring is discussed in section 3. 2 Notice that E(σ(X)) = 1/2 for a zero-mean Gaussian random variable. Then, as we are working with a centred Gaussian process, it holds that E(λ(t)) = λ0(t)E(σ(l(t))) = λ0(t)/2. Hence, we can imagine our model as a random hazard centred in λ0(t)/2 with a multiplicative noise. In the simplest scenario, we may take a constant baseline hazard λ0(t) = 2Ωwith Ω> 0. In such case, we obtain a random hazard centred in Ω, which is simply the hazard function of a exponential random variable with mean 1/Ω. Another choice might be λ0(t) = 2βtα−1, which determines a random hazard function centred in βtα−1, which corresponds to the hazard function of the Weibull distribution, a popular default distribution in survival analysis. In addition to the hierarchical model in (1), we include hyperparameters to the kernel κ and to the baseline hazard λ0(t). In particular for the kernel, it is common to include a length scale parameter and an overall variance. Finally, we need to ensure the model we proposed defines a well-defined survival function, i.e. S(t) →0 as t tends to infinity. This is not trivial as our random survival function is generated by a Gaussian process. The next proposition, proved in the supplemental material, states that under suitable regularity conditions, the prior defines proper survival functions. Proposition 1. Let (l(t))t≥0 ∼GP(0, κ) be a stationary continuous Gaussian process. Suppose that κ(s) is non-increasing and that lims→∞κ(s) = 0. Moreover, assume it exists K > 0 and α > 0 such that λ0(t) ≥Ktα−1 for all t ≥1. Let S(t) be the random survival function associated with (l(t))t≥0, then limt→∞S(t) = 0 with probability 1. Note the above proposition is satisfied by the hazard functions of the Exponential and Weibull distributions. 2.1 Adding covariates We model the relation between time and covariates by the kernel of the Gaussian process prior. A simple way to generate kernels in time and covariates is to construct kernels for each covariate and time, and then perform basic operation of them, e.g. addition or multiplication. Let (t, X) denotes a time t and with covariates X ∈Rd. Then for pairs (t, X) and (s, Y ) we can construct kernels like ˆK((t, X), (s, Y )) = ˆK0(t, s) + Pd j=1 ˆKj(Xj, Yj), or, the following kernel, which is the one we use in our experiments, K((t, X), (s, Y )) = K0(t, s) + Pd j=1 XjYjKj(t, s). (2) Observe that the first kernel establishes an additive relation between time and covariates while the second creates an interaction between the value of the covariates and time. More complicated structures that include more interaction between covariates can be considered. We refer to the work of [6] for details about the construction and interpretation of the operations between kernels. Observe the new kernel produces a Gaussian process from the space of time and covariates to the real line, i.e it has to be evaluated in a pair of time and covariates. The new model to generate Ti, assuming we are given the covariates Xi, is l(·) ∼GP(0, K), λi(t)|l, λ0(t), Xi = λ0(t)σ(l(t, Xi)), Ti|λi indep ∼ λ(Ti)e− R Ti 0 λi(s)ds, (3) In our construction of the kernel K, we choose all kernels Kj as stationary kernels (e.g. squared exponential), so that K is stationary with respect to time, so proposition 1 is valid for each fixed covariate X, i.e. giving a fix covariate X, we have SX(t) = P(T > t|X) →0 as t →∞. 3 Inference 3.1 Data augmentation scheme Notice that the likelihood of the model in equation (3) has to deal with terms of the form λi(t) exp− R t 0 λi(s)ds as these expressions come from the density of the first jump of a nonhomogeneous Poisson process with intensity λi. In general the integral is not analytically tractable since λi is defined by a Gaussian process. A numerical scheme can be used, but it is approximate and 3 computationally expensive. Following [1] and [18], we develop a data augmentation scheme based on thinning a Poisson process that allows us to efficiently avoid a numerical method. If we want to sample a time T with covariate X, as given in equation (3), we can use the following generative process. Simulate a sequence of points g1, g2, . . . of points distributed according a Poisson process with intensity λ0(t). We assume the user is using a well-known parametric form, then sampling the points g1, g2, . . . is tractable (in the Weibull case this can be easily done). Starting from k = 1 we accept the point gk with probability σ(l(gk, X)). If it is accepted we set T = gk, otherwise we try the point gk+1 and repeat. We denote by G the set of rejected point, i.e. if we accepted gk, then G = {g1, . . . , gk−1}. Note the above sampling procedure needs to evaluate the Gaussian process in the points (gk, X) instead the whole space. Following the above scheme to sample T, the following proposition can be shown. Proposition 2. Let Λ0(t) = R T 0 λ0(t)dt, then p(G, T|λ0, l(t)) = λ0(T) Y g∈G λ0(g) e−Λ0(T ) σ(l(T)) Y g∈G (1 −σ(l(g))) (4) Proof sketch. Consider a Poisson process on [0, ∞) with intensity λ0(t). Then, the first term in the RHS of equation (4) is the density of putting points exactly in G ∪{T}. The second term is the probability of putting no points in [0, T] \ (G ∪{T}), i.e. e−Λ0(T ). The second term is independent of the first one. The last term comes from the acceptance/rejection part of the process. The points g ∈G are rejected with probability 1 −σ(g), while the point T is accepted with probability σ(T). Since the acceptance/rejection of points is independent of the Poisson process we get the result. Using the above proposition, the model of equation (1) can be reformulated as the following tractable generative model: l(·) ∼GP(0, K), (G, T)|λ0(t), l(t) ∼e−Λ0(T )(σ(l(T))λ0(T)) Y g∈G (1 −σ(l(g)))λ0(g). (5) Our model states a joint distribution for the pair (G, T) where G is the set of rejected jump point of the thinned Poisson process and T is the first accepted one. To perform inference we need data (Gi, Ti, Xi), whereas we only receive points (Ti, Xi). Thus, we need to sample the missing data Gi given (Ti, Xi). The next proposition gives us a way to do this. Proposition 3. [18] Let T be a data point with covariate X and let G be its set of rejected points. Then the distribution of G given (T, X, λ0, l) is distributed as a non-homogeneous Poisson process with intensity λ0(t)(1 −σ(l(t, X))) on the interval [0, T]. 3.2 Inference algorithm The above data augmentation scheme suggests the following inference algorithm. For each data point (Ti, Xi) sample Gi|(Ti, Xi, λ0, l), then sample l|((Gi, Ti, Xi)n i=1, λ0), where n is the number of data points. Observe that the sampling of l given (Gi, Ti, Xi)n i=1, λ0) can be seen as a Gaussian process binary classification problem, where the points Gi and Ti represent two different classes. A variety of MCMC techniques can be used to sample l, see [15] for details. For our algorithm we use the following notation. We denote the dataset as (Ti, Xi)n i=1. The set Gi refers to the set of rejected points of Ti. We denote G = Sn i=1 Gi and T = {T1, . . . , Tn} for the whole set of rejected and accepted points, respectively. For a point t ∈Gi ∪{Ti} we denote l(t) instead of l(t, Xi), but remember that each point has an associated covariate. For a set of points A we denote l(A) = {l(a) : a ∈A}. Also Λ0(t) refers to R t 0 λ0(s)ds and Λ0(t)−1 denotes its inverse function (it exists since Λ0(t) is increasing). Finally, N denotes the number of iterations we are going to run our algorithm. The pseudo code of our algorithm is given in Algorithm 1. Lines 2 to 11 sample the set of rejected points Gi for each survival time Ti. Particularly lines 3 to 5 use the Mapping theorem, which tells us how to map a homogeneous Poisson process into a non-homogeneous with the appropriate intensity. Observe it makes uses of the function Λ0 and its 4 Algorithm 1: Inference Algorithm. Input: Set of times T and the Gaussian proces l instantiated in T and other initial parameters 1 for q=1:N do 2 for i=1:n do 3 ni ∼Poisson(1; Λ0(Ti)); 4 ˜Ci ∼U(ni; 0, Λ0(Ti)); 5 Set Ai = Λ−1 0 ( ˜Ai); 6 Set A = ∪n i=1Ai 7 Sample l(A)|l(G ∪T ), λ0 8 for i=1:n do 9 Ui ∼U(ni; 0, 1) 10 set G(i) = {a ∈Ai such that Ui < 1 −σ(l(a))} 11 Set G = ∪n i=1Gi 12 Update parameters of λ0(t) 13 Update l(G ∪T ) and hyperparameter of the kernel. inverse function, which shall be provided or be easily computable. The following lines classify the points drawn from the Poisson process with intensity λ0 in the set Gi as in proposition 3. Line 7 is used to sample the Gaussian process in the set of points A given the values in the current set G ∪T . Observe that at the beginning of the algorithm, we have G = ∅. 3.3 Adding censoring Usually, in Survival analysis, we encounter three types of censoring: right, left and interval censoring. We assume each data point Ti is associated with an (observable) indicator δi, denoting the type of censoring or if the time is not censored. We describe how the algorithm described before can easily handle any type of censorship. Right censorship: In presence of right censoring, the likelihood for a survival time Ti is S(Ti). The related event in terms of the rejected points correspond to do not accept any location [0, Ti). Hence, we can treat right censorship in the same way as the uncensored case, by just sampling from the distribution of the rejected jump times prior Ti. In this case, Ti is not an accepted location, i.e. Ti is not considered in the set T of line 7 nor 13. Left censorship: In this set-up, we know the survival time is at most Ti, then the likelihood of such time is F(Ti). Treating this type of censorship is slightly more difficult than the previous case because the event is more complex. We ask for accepting at least one jump time prior Ti, which might leads us to have a larger set of latent variables. In order to avoid this, we proceed by imputing the ‘true’ survival time T ′ i by using its truncated distribution on [0, Ti]. Then we proceed using T ′ i (uncensored) instead of Ti. We can sample T ′ i as following: we sample the first point of a Poisson process with the current intensity λ, if such point is after Ti we reject the point and repeat the process until we get one. The imputation step has to be repeated at the beginning of each iteration. Interval censorship: If we know that survival time lies in the interval I = [Si, Ti] we can deal with interval censoring in the same way as left censoring but imputing the survival time T ′ i in I. 4 Approximation scheme As shown is algorithm 1, in line 7 we need to sample the Gaussian process (l(t))t≥0 in the set of points A from its conditional distribution, while in line 13, we have to update (l(t))t≥0 in the set G ∪T . Both lines require matrix inversion which scales badly for massive datasets or for data T that generates a large set G. In order to help the inference we use a random feature approximation of the Kernel [17]. We exemplify the idea on the kernel we use in our experiment, which is given by K((t, X), (s, Y )) = K0(t, s) + Pd j=1 XjYjKj(t, s), where each Kj is a square exponential kernel, with overall variance 5 σ2 j and length scale parameter φj Hence, for m ≥0, the approximation of our Gaussian process is given by gm(t, X) = gm 0 (t) + Pd j=1 Xjgm j (t) (6) where each gm j (t) = Pm k=1 aj k cos(sj kt) + bj k sin(sj kt), and each aj k and bj k are independent samples of N(0, σ2 j ) where σ2 j is the overall variance of the kernel Kj. Moreover, sj k are independent samples of N(0, 1/(2πφj)) where φj is the length scale parameter of the kernel Kj. Notice that gm(t, X) is a Gaussian process since each gm j (t) is the sum of independent normally distributed random variables. It is know that as m goes to infinity, the kernel of gm(t, X) approximates the kernel Kj. The above approximation can be done for any stationary kernel and we refer the reader to [17] for details. The inference algorithm for this scheme is practically the same, except for two small changes. The values l(A) in line 7 are easier to evaluate because we just need to know the values of the aj k and bj k, and no matrix inversion is needed. In line 13 we just need to update all values ak j and bk j . Since they are independent variables there is no need for matrix inversion. 5 Experiments All the experiments are performed using our approximation scheme of equation (6) with a value of m = 50. Recall that for each Gaussian process, we used a squared exponential kernel with overall variance σ2 j and length scale parameter φj. Hence for a set of d covariates we have a set of 2(d + 1) hyper-parameters associated to the Gaussian processes. In particular, we follow a Bayesian approach and place a log-Normal prior for the length scale parameter φj, and a gamma prior (inverse gamma is also useful since it is conjugate) for the variance σ2 j . We use elliptical slice sampler [16] for jointly updating the set of coefficients {aj k, bj k} and length-scale parameters. With respect the baseline hazard we consider two models. For the first option, we choose the baseline hazard 2βtα−1 of a Weibull random variable. Following a Bayesian approach, we choose a gamma prior on β and a uniform U(0, 2.3) on α. Notice the posterior distribution for β is conjugate and thus we can easily sample from it. For α, use a Metropolis step to sample from its posterior. Additionally, observe that for the prior distribution of α, we constrain the support to (0, 2.3). The reason for this is because the expected size of the set G increases with respect to α and thus slow down computations. As second alternative is to choose the baseline hazard as λ0(t) = 2Ω, with gamma prior over the parameter Ω. The posterior distribution of Ωis also gamma. We refer to both models as the Weibull model (W-SGP) and the Exponential model (E-SGP) respectively. The implementation for both models is exactly the same as in Algorithm 1 and uses the same hyperparameters described before. As the tuning of initial parameters can be hard, we use the maximum likelihood estimator as initial parameters of the model. 5.1 Synthetic Data In this section we present experiments made with synthetic data. Here we perform the experiment proposed in [4] for crossing data. We simulate n = 25, 50, 100 and 150 points from each of the following densities, p0(t) = N(3, 0.82) and p1(t) = 0.4N(4, 1) + 0.6N(2, 0.82), restricted to R+. The data contain the sample points and a covariate indicating if such points were sampled from the p.d.f p0 or p1. Additionally, to each data point, we add 3 noisy covariates taking random values in the interval [0, 1]. We report the estimations of the survival functions for the Weibull model in figure 1 while the results for the Exponential model are given in the supplemental material. It is clear that for the clean data (without extra noisy covariates), the more data the better the estimation. In particular, the model perfectly detects the cross in the survival functions. For the noisy data we can see that with few data points the noise seems to have an effect in the precision of our estimation in both models. Nevertheless, the more points the more precise is our estimate for the survival curves. With 150 points, each group seems to be centred on the corresponding real survival function, independent of the noisy covariates. We finally remark that for the W-SGP and E-SGP models, the prior of the hazards are centred in a Weibull and a Exponential hazard, respectively. Since the synthetic data does not come from those 6 G GG G G G G G G G G G G G G G G G G G G G GG G 0.00 0.25 0.50 0.75 1.00 0 2 4 G GG G G G G G G G G G G G G G G G G G G G GG G G G G G G G G G G GG G G G G G G G G G G G G G G 0 2 4 G GG G G G G G G G G G G G G G G G G G G G GG G G G G G G G G G G GG G G G G G G G G G G G GG G G G G G G G G G G G G G G G G G G GG G G GG G G G G G GG G G G G G G G G G G G G G G G G G G G G 0 2 4 6 G GG G G G G G G G G G G G G G G G G G G G GG G G G G G G G G G G GG G G G G G G G G G G G GG G G G G G G G G G G G G G G G G G G GG G G GG G G G G G GG G G G G G G G G G G G G G G G G G G G G G G G G G G G G G G G GG G G G G G G G G G G G G G G G G G G G G G G G G G G G G G G G G G G G G G 0 2 4 6 G GG G G G G G G G G G G G G G G G G G G G GG G 0.00 0.25 0.50 0.75 1.00 0 2 4 G GG G G G G G G G G G G G G G G G G G G G GG G G G G G G G G G G GG G G G G G G G G G G G G G G 0 2 4 G GG G G G G G G G G G G G G G G G G G G G GG G G G G G G G G G G GG G G G G G G G G G G G GG G G G G G G G G G G G G G G G G G G GG G G GG G G G G G GG G G G G G G G G G G G G G G G G G G G G 0 2 4 6 G GG G G G G G G G G G G G G G G G G G G G GG G G G G G G G G G G GG G G G G G G G G G G G GG G G G G G G G G G G G G G G G G G G GG G G GG G G G G G GG G G G G G G G G G G G G G G G G G G G G G G G G G G G G G G G GG G G G G G G G G G G G G G G G G G G G G G G G G G G G G G G G G G G G G G 0 2 4 6 Figure 1: Weibull Model. First row: clean data, Second row: data with noise covariates. Per columns we have 25, 50, 100 and 150 data points per each group (shown in X-axis) and data is increasing from left to right. Dots indicate data is generated from p0, crosses, from p1. In the first row a credibility interval is shown. In the second row each curve for each combination of noisy covariate is given. distributions, it will be harder to approximate the true survival function with few data. Indeed, we observe our models have problems at estimating the survival functions for times close to zero. 5.2 Real data experiments To compare our models we use the so-called concordance index. The concordance index is a standard measure in survival analysis which estimates how good the model is at ranking survival times. We consider a set of survival times with their respective censoring indices and set of covariates (T1, δ1, X1), . . . , (Tn, δn, Xn). On this particular context, we just consider right censoring. To compute the C-index, consider all possible pairs (Ti, δi, Xi; Tj, δj, Xj) for i ̸= j. We call a pair admissible if it can be ordered. If both survival times are right-censored i.e. δi = δj = 0 it is impossible to order them, we have the same problem if the smallest of the survival times in a pair is censored, i.e. Ti < Tj and δi = 0. All the other cases under this context will be called admissible. Given just covariates Xi, Xj and the status δi, δj, the model has to predict if Ti < Tj or the other way around. We compute the C-index by considering the number of pairs which were correctly sorted by the model, given the covariates, over the number of admissible pairs. A larger C-index indicates the model is better at predicting which patient dies first by observing the covariates. If the C-index close to 0.5, it means the prediction made by the model is close to random. We run experiments on the Veteran data, avaiable in the R-package survival package [19]. Veteran consists of a randomized trial of two treatment regimes for lung cancer. It has 137 samples and 5 covariates: treatment indicating the type of treatment of the patients, their age, the Karnofsky performance score, and indicator for prior treatment and months from diagnosis. It contains 9 censored times, corresponding to right censoring. In the experiment we run our Weibull model (W-SGP) and Exponential model (E-SGP), ANOVA DDP, Cox Proportional Hazard and Random Survival Forest. We perform 10-fold cross validation and compute the C-index for each fold. Figure 2 reports the results. For this dataset the only significant variable corresponds to the Karnofsky performance score. In particular as the values of this covariate increases, we expect an improved survival time. All the studied models achieve such behaviour and suggest a proportionality relation between the hazards. This is observable in the C-Index boxplot we can observe good results for proportional hazard rates. 7 G 0.5 0.6 0.7 0.8 ANOVA−DDP COX E−SGP RSF W−SGP C−Index G G GG G G G G G G GG G G G G G G G G G G G G G G G G G G G G G G G G G G G G G G G G G G G G G G G G G GG G G G G G G G G G G G G G G GG G G G G G G G G G G G G G G G G G G G G G G GG G G G G G G G G G G G GG G GG G G G G G G G G G G G G G G G G G G G G G G G G G G GG G G G G G G G G G G G G G G G G G G G 0.00 0.25 0.50 0.75 1.00 0 250 500 750 1000 time S(t) G G G G G All data Score 30, treatment 1 Score 30, treatment 2 Score 90, treatment 1 Score 90, treatment 2 COX (step) ANOVA−DDP ESGP (smooth) G GG G G G G G G G GG G G G G GG G G G G G G G G G G G G G G G G G G G G G G G G G G GGG GG G GG G G G G G G G G G G G G G G G G G G G G G G G GG G G G G G G GG G G G G G G G G G G G G G G G G G G G G G G G G G G GG G G G G G G GG G G G G G G G G G G G G G G G G 0.00 0.25 0.50 0.75 1.00 0 250 500 750 1000 time S(t) E−SGP G G G G G G G G G G G G Score 10 Score 20 Score 30 Score 40 Score 50 Score 60 Score 70 Score 75 Score 80 Score 85 Score 90 Score 99 Figure 2: Left: C-Index for ANOVA-DDP,COX,E-SGP,RSF,W-SGP; Middle: Survival curves obtained for the combination of score: 30, 90 and treatments: 1 (standard) and 2 (test); Right: Survival curves, using W-SGP, across all scores for fixed treatment 1, diagnosis time 5 moths, age 38 and no prior therapy. (Best viewed in colour) G GG G G G G G G G GG G G G G GG G G G G G G G G G G G G G G G G G G G G G G G G G G GGG GG G GG G G G G G G G G G G G G G G G G G G G G G G G GG G G G G G G GG G G G G G G G G G G G G G G G G G G G G G G G G G G GG G G G G G G GG G G G G G G G G G G G G G G G G 0.00 0.25 0.50 0.75 1.00 0 250 500 750 1000 time S(t) ANOVA−DDP G G G G G G G G G G G G Score 10 Score 20 Score 30 Score 40 Score 50 Score 60 Score 70 Score 75 Score 80 Score 85 Score 90 Score 99 G GG G G G G G G G GG G G G G GG G G G G G G G G G G G G G G G G G G G G G G G G G G GGG GG G GG G G G G G G G G G G G G G G G G G G G G G G G GG G G G G G G GG G G G G G G G G G G G G G G G G G G G G G G G G G G GG G G G G G G GG G G G G G G G G G G G G G G G G 0.00 0.25 0.50 0.75 1.00 0 250 500 750 1000 time S(t) COX G G G G G G G G G G G G Score 10 Score 20 Score 30 Score 40 Score 50 Score 60 Score 70 Score 75 Score 80 Score 85 Score 90 Score 99 G GG G G G G G G G GG G G G G GG G G G G G G G G G G G G G G G G G G G G G G G G G G GGG GG G GG G G G G G G G G G G G G G G G G G G G G G G G GG G G G G G G GG G G G G G G G G G G G G G G G G G G G G G G G G G G GG G G G G G G GG G G G G G G G G G G G G G G G G 0.00 0.25 0.50 0.75 1.00 0 250 500 750 1000 time S(t) RSF G G G G G G G G G G G G Score 10 Score 20 Score 30 Score 40 Score 50 Score 60 Score 70 Score 75 Score 80 Score 85 Score 90 Score 99 Figure 3: Survival curves across all scores for fixed treatment 1, diagnosis time 5 months, age 38 and no prior therapy. Left: ANOVA-DDP; Middle: Cox proportional; Right: Random survival forests. Nevertheless, our method detect some differences between the treatments when the Karnofsky performance score is 90, as it can be seen in figure 2. For the other competing models we observe an overall good result. In the case of ANOVA-DDP we observe the lowest C-INDEX. In figure 3 we see that ANOVA-DDP seems to be overestimating the Survival function for lower scores. Arguably, our survival curves are more visually pleasant than Cox proportional hazards and Random Survival Trees. 6 Discussion We introduced a Bayesian semiparametric model for survival analysis. Our model is able to deal with censoring and covariates. In can incorporate a parametric part, in which an expert can incorporate his knowledge via the baseline hazard but, at the same time, the nonparametric part allows the model to be flexible. Future work consist in create a method to choose initial parameter to avoid sensitivity problems at the beginning. Construction of kernels that can be interpreted by an expert is something desirable as well. Finally, even though the random features approximation is a good approach and helped us to run our algorithm in large datasets, it is still not sufficient for datasets with a massive number of covariates, specially if we consider a large number of interactions between covariates. Acknowledgments YWT’s research leading to these results has received funding from the European Research Council under the European Union’s Seventh Framework Programme (FP7/2007-2013) ERC grant agreement no. 617071. Tamara Fernández and Nicolás Rivera were supported by funding from Becas CHILE. 8 References [1] Ryan Prescott Adams, Iain Murray, and David JC MacKay. Tractable nonparametric bayesian inference in poisson processes with gaussian process intensities. In Proceedings of the 26th Annual International Conference on Machine Learning, pages 9–16. ACM, 2009. [2] James E Barrett and Anthony CC Coolen. Gaussian process regression for survival data with competing risks. arXiv preprint arXiv:1312.1591, 2013. [3] DR Cox. Regression models and life-tables. Journal of the Royal Statistical Society. Series B (Methodological), 34(2):187–220, 1972. [4] Maria De Iorio, Wesley O Johnson, Peter Müller, and Gary L Rosner. Bayesian nonparametric nonproportional hazards survival modeling. Biometrics, 65(3):762–771, 2009. [5] Kjell Doksum. Tailfree and neutral random probabilities and their posterior distributions. The Annals of Probability, pages 183–201, 1974. [6] David K Duvenaud, Hannes Nickisch, and Carl E Rasmussen. Additive gaussian processes. In Advances in neural information processing systems, pages 226–234, 2011. [7] RL Dykstra and Purushottam Laud. A bayesian nonparametric approach to reliability. The Annals of Statistics, pages 356–367, 1981. [8] Thomas S Ferguson. A bayesian analysis of some nonparametric problems. The annals of statistics, pages 209–230, 1973. [9] Nils Lid Hjort, Chris Holmes, Peter Müller, and Stephen G Walker. Bayesian nonparametrics, volume 28. Cambridge University Press, 2010. [10] Hemant Ishwaran, Udaya B Kogalur, Eugene H Blackstone, and Michael S Lauer. Random survival forests. The annals of applied statistics, pages 841–860, 2008. [11] Heikki Joensuu, Peter Reichardt, Mikael Eriksson, Kirsten Sundby Hall, and Aki Vehtari. Gastrointestinal stromal tumor: a method for optimizing the timing of ct scans in the follow-up of cancer patients. Radiology, 271(1):96–106, 2013. [12] Heikki Joensuu, Aki Vehtari, Jaakko Riihimäki, Toshirou Nishida, Sonja E Steigen, Peter Brabec, Lukas Plank, Bengt Nilsson, Claudia Cirilli, Chiara Braconi, et al. Risk of recurrence of gastrointestinal stromal tumour after surgery: an analysis of pooled population-based cohorts. The lancet oncology, 13(3):265–274, 2012. [13] Edward L Kaplan and Paul Meier. Nonparametric estimation from incomplete observations. Journal of the American statistical association, 53(282):457–481, 1958. [14] Sara Martino, Rupali Akerkar, and Håvard Rue. Approximate bayesian inference for survival models. Scandinavian Journal of Statistics, 38(3):514–528, 2011. [15] Iain Murray and Ryan P Adams. Slice sampling covariance hyperparameters of latent gaussian models. In Advances in Neural Information Processing Systems, pages 1732–1740, 2010. [16] Iain Murray, Ryan Prescott Adams, and David JC MacKay. Elliptical slice sampling. In AISTATS, volume 13, pages 541–548, 2010. [17] Ali Rahimi and Benjamin Recht. Random features for large-scale kernel machines. In Advances in neural information processing systems, pages 1177–1184, 2007. [18] Vinayak Rao and Yee W. Teh. Gaussian process modulated renewal processes. In Advances in Neural Information Processing Systems, pages 2474–2482, 2011. [19] Terry M Therneau and Thomas Lumley. Package ‘survival’, 2015. [20] Stephen Walker and Pietro Muliere. Beta-stacy processes and a generalization of the pólya-urn scheme. The Annals of Statistics, pages 1762–1780, 1997. 9 | 2016 | 529 |
6,471 | Learning under uncertainty: a comparison between R-W and Bayesian approach He Huang Laureate Institute for Brain Research Tulsa, OK, 74133 crane081@gmail.com Martin Paulus Laureate Institute for Brain Research Tulsa, OK, 74133 mpaulus@laureateinstitute.org Abstract Accurately differentiating between what are truly unpredictably random and systematic changes that occur at random can have profound effect on affect and cognition. To examine the underlying computational principles that guide different learning behavior in an uncertain environment, we compared an R-W model and a Bayesian approach in a visual search task with different volatility levels. Both R-W model and the Bayesian approach reflected an individual’s estimation of the environmental volatility, and there is a strong correlation between the learning rate in R-W model and the belief of stationarity in the Bayesian approach in different volatility conditions. In a low volatility condition, R-W model indicates that learning rate positively correlates with lose-shift rate, but not choice optimality (inverted U shape). The Bayesian approach indicates that the belief of environmental stationarity positively correlates with choice optimality, but not lose-shift rate (inverted U shape). In addition, we showed that comparing to Expert learners, individuals with high lose-shift rate (sub-optimal learners) had significantly higher learning rate estimated from R-W model and lower belief of stationarity from the Bayesian model. 1 Introduction Learning and using environmental statistics in choice-selection under uncertainty is a fundamental survival skill. It has been shown that, in tasks with embedded environmental statistics, subjects use sub-optimal heuristic Win-Stay-Lose-Shift (WSLS) strategy (Lee et al. 2011), and strategies that can be interpreted using Reinforcement Learning model (Behrens et al. 2007), or Bayesian inference model (Mathys et al. 2014; Yu et al. 2014). Value-based model-free RL model assumes subjects learn the values of chosen options using a prediction error that is scaled by a learning rate (Rescorla and Wagner, 1972; Sutton and Barto, 1998). This learning rate can be used to measure an individual’s reaction to environmental volatility (Browning et al. 2015). Higher learning rate is usually associated with a more volatile environment, and a lower learning rate is associated with a relatively stable situation. Different from traditional (model-free) RL model, Bayesian approach assumes subjects make decisions by learning the reward probability distribution of all options based on Bayes’ rule, i.e., sequentially updating the posterior probability by combining the prior knowledge and the new observation (likelihood function) over time. To examine how environment volatility may influence this inference process, Yu & Cohen 2009 proposed to use a dynamic belief model (DBM) 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. that assumes subjects update their belief of the environmental statistics by balancing between the prior belief and the belief of environmental stationarity, in which a belief of high stationarity will lead to a relatively fixed belief of the environmental statistics, and vice versa. Though formulated under different assumptions (Gershman 2015), those two approaches share similar characteristics. First, both the learning rate in RL model and the belief of stationarity in DBM reflect an individual’s estimation of the environmental volatility. In a highly volatile environment, one will be expected to have a high learning rate estimated by RL model, and a belief of low stationarity estimated by DBM. Second, though standard RL only updates the chosen option’s value and DBM updates the posterior probability of all options, assuming maximization decision rule (Blakely, Starin, & Poling, 1988), both models will lead to qualitatively similar choice preference. That is, the mostly rewarded choice will have an increasing value in RL model, and increasing reward probability in DBM, while the often-unrewarded choice will lead to a decreasing value in RL model, and decreasing reward probability in DBM. Thirdly, they can both explain Win-Stay strategy. That is, under the maximization assumption, choosing the option with maximum value in RL model, the rewarded option (Win) will reinforce this choice (i.e. remain the option with the maximum value) and thus will be chosen again (Stay). Similarly, choosing the option with the maximum reward probability in DBM, the rewarded option (Win) will also reinforce this choice (i.e. remain the option with the maximum reward probability) and thus will be chosen again (Stay). While both approaches share some characteristics as mentioned above and have showed strong evidence in explaining the overall subjects’ choices in previous studies, it is unclear how they differ in explaining other behavioral measures in tasks with changing reward contingency, such as decision optimality, i.e., percentage of trials in which one chooses the most likely rewarded option, and lose-shift rate, i.e., the tendency to follow the last target if the current choice is not rewarded. In a task with changing reward contingency (e.g., 80%:20% to 20%:80%), decision optimality relies on proper estimation of the environmental volatility, i.e., how frequent change points occur, and using proper strategy, i.e. staying with the mostly likely option and ignoring the noise before change points (i.e. not switching to the option with lower reward rate when it appears as the target). Thus it is important to know how the parameter in each model (learning rate vs. the belief of stationarity) affects decision optimality in tasks with different volatility. On the other hand, lose-shift can be explained as a heuristic decision policy that is used to reduce a cognitively difficult problem (Kahneman & Frederick, 2002), or as an artifact of learning that can be interpreted in a principled fashion (using RL: Worthy et al. 2014; using Bayesian inference: Bonawitz et al. 2014). Intuitively, when experiencing a loss in the current trial, in a high volatility environment where change points frequently occur, one may tend to shift to the last target; while in a stable environment with fixed reward rates, one may tend to stay with the option with the higher reward rate. That is, the frequency of using lose-shift strategy should depend on how frequent the environment changes. Thus it is also important to examine how the parameter in each model (learning rate vs. the belief of stationarity) affects lose-shift rate under different volatility conditions. However, so far little is known about how a model-free RL model and a Bayesian model differ in explaining decision optimality and lose-shift in tasks with different levels of volatility. In addition, it is unclear if parameters in each model can capture the individual differences in learning. For example, if they can provide satisfactory explanation of individuals who always choose the same choice while disregarding feedback information (No Learning), individuals who always choose the most likely rewarded option (expert), and individuals who always use the heuristic win-stay-lose-shift strategy. Here we aim to address the first question by investigating the relationship between decision optimality and lose-shift rate with parameters estimated from an Rescorla-Wagner (R-W model) and a Bayesian model in three volatility conditions (Fig 1a) in a visual search task (Yu et al. 2014): 1) stable, where the reward contingency at three locations remains the same (relative reward frequency at three locations: 1:3:9), 2) low volatility, where the reward contingency at three locations changes (e.g. from 1:3:9 to 9:1:3) based on N(30, 1) (i.e. on average change points occur every 30 trials), and 3) high volatility, where the reward contingency changes based on N(10, 1) (i.e. on average change points occur every 10 trials). For the second question, we will examine how the two models differ in explaining three types of behavior: No Learning, Expert, and WSLS (Fig 1b). 2 Target WSLS Expert No learning Trials … … … … … … … … Stable Trials A B C Most likely rewarded location Low volatility High volatility a b Volatility conditions Behavioral types Figure 1: Example of volatility conditions and behavioral types in a visual search task. a. Example of three volatility conditions. b. Example of three behavioral types. Colors indicate target location in each trial. WSLS: Win-stay-Lose-shift (follow last target). Expert: always choose the most likely location. No Learning: always choose the same location. 2 Value-based RL model Assuming a constant learning rate, the Rescorla-Wagner model takes the following form (Rescorla and Wagner, 1972; Sutton and Barto, 1998): V t+1 i = V t i + η(Rt −V t i ) (1) where η is the learning rate, and Rt is the reward feedback (0-no reward, 1-reward) for the chosen option i in trial t. In this paper, we assume subjects use a softmax decision rule for all models as follows: p(i) = eβVi P j eβVj (2) where β is the inverse decision temperature parameter, which measures the degree to which subjects use the estimated value in choosing among three options (i.e. a large β approximates ’maximization’ strategy). This model has two free parameters = {η, β} for each subject. 2.1 Simulation in three volatility conditions Learning rate is expected to increase as the volatility increases. To show this, we simulated three volatility conditions (Stable, Low and High volatility, Fig 2ab) and the results are summarized in Table1. For each condition, we simulated 100 runs (90 trial per run) of agents’ choices with η ranges from 0 to 1 with an increment of 0.1 and fixed β = 20. As is shown in Fig 2a, decision optimality in a stable and a low volatility environment has an inverted U shape as a function of learning rate η. It is not surprising, as in those conditions, where one should rely more on the long term statistics, if the learning rate is too high, then subjects will tend to shift more due to recent experience (Fig 2b), which would adversely influence decision optimality. On the other hand, in a high volatility environment, decision optimality has a linear correlation with the learning rate, suggesting that higher learning rate leads to better performance. In fact, the optimal learning rate increases as the environmental volatility increases (i.e. the peak of the inverted U should shift to the right). On the other hand, across all volatility conditions, lose shift rate increases as learning rate increases (Fig 2b), except for learning rate=0. It is not surprising as zero learning rate indicates subjects make random choices, thus it will be close to 1/3. 2.2 Simulation of three behavioral types To examine if learning rate can be used to explain different types of learning behavior, we have simulated three types of behavior (No Learning, Expert and WSLS, Fig 1b) in a low volatility condition. In particular, we simulated 60 runs (90 trials per run) of target sequences with a relative reward frequency 1:3:9 that changes based on N(30, 1), and generated three types of behavior for 3 Table 1: R-W model: Influence of learning rate η Condition Decision optimality Lose-shift rate Stable Inverted U shape, ηoptimal = low Positive linear Low volatility Inverted U shape, ηoptimal = medium Positive linear High volatility Positive linear relationship, ηoptimal = high Positive linear each run. For each simulated behavior type, R-W model was fitted using Maximum Likelihood Estimation with η ranges from 0 to 1 with an increment of .025 and β = 20. Based on what we have shown in 2.1, in a low volatility condition where decision optimality has an inverted U shape as a function of learning rate, individuals that perform poorly will be expected to have a low learning rate, and individuals that use heuristic WSLS strategy will be expected to have a high learning rate. We confirmed this in simulation (Fig 2c), that agents with the same choice over time (No Learning) have the lowest learning rate, indicating their choices have little influence from the reward feedback. Expert agents have the medium learning rate indicating the effect of long-term statistics. Agents that strictly follow WSLS have the highest learning rate, indicating their choices are heavily impacted by recent experience. Results for learning rate estimation of three behavioral types in stable and high volatility condition can be seen in Supplementary Figure S1. No learning Expert WSLS 0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 eta 0 0.2 0.4 0.6 0.8 1 Lose shift% 0 0.05 0.1 0.15 0.2 0.25 0.3 0.35 0.4 Optimal choice% Lose shift% Learning rate Low volatility a b eta 0 0.2 0.4 0.6 0.8 1 Optimal choice% 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1 Non N(30,1) N(10,1) Simu_all.m Simu_Fix_TD.m Simu_all_new.m c Learning rate η Learning rate η Learning type Learning rate η Stable Low volatility High volatility Simu_target.m Figure 2 Figure 2: R-W simulation. a. Percentage of trials in which agents chose the optimal choice (the most likely location) as a function of learning rate in three volatility conditions. b. Lose shift rate as a function of learning rate in three volatility conditions. c. Learning rate estimation of three simulated behavior types in low volatility condition. Errorbars indicate standard error of the mean across simulation runs. 3 A Bayesian approach Here we compare above R-W model to a dynamic belief model that is based on a Bayesian hidden Markov model, where we assume subjects make decisions by using the inferred posterior target probability st based on the inferred hidden reward probability γγγt and the reward contingency mapping bt (Equation 3). To examine the influence of volatility, we assume (γγγt, bt) has probability α of remaining the same as the last trial, and 1-α of being drawn from the prior distribution p0(γγγt, bt) (Equation 4). Here α represents an individual’s estimation of environmental stationarity, which contrasts with learning rate η in R-W model. For model details, please refer to Yu & Huang 2014. P(st|γγγt, bt) = ( 1 3, 1 3, 1 3), bk = 1 (γh, γm, γl), bk = 2 (γh, γl, γm), bk = 3 (γm, γh, γl), bk = 4 (γm, γl, γh), bk = 5 (γl, γh, γm), bk = 6 (γl, γm, γh), bk = 7 (3) 4 P(γγγt, bt|st−1) = αP(γγγt−1, bt−1|st−1) + (1 −α)p0(γγγt, bt) (4) where γγγt is the hidden reward probability, bt is the reward contingency mapping of the probability to the options, st−1 is the target history from trial 1 to trial t −1. We also used softmax decision rule here (Equation 2), thus this model also has two free parameters = {α, β}. 3.1 Simulation in three volatility conditions Belief of stationarity α is expected to decrease as the volatility increases, as subjects are expected to depend more on the recent trials to predict next outcome (Yu &Huang 2014). We have shown this in three simulated conditions under different volatility (Fig 3ab) and the results are summarized in Table 2. For each simulated condition (stable, low and high volatility), we simulated 100 runs (90 trials per run) for agents’ choices with α ranges from 0 to 1 and fixed β = 20. As is shown in Fig 3a, in a stable condition, decision optimality increases as α increases, indicating a fixed belief mode (i.e. no change of the environmental statistics) is optimal in this condition. In the other two volatile environments, decision optimality also increases as α increases, but both drop as α approaches 1. It is reasonable as in volatile environments a belief of high stationarity is no longer optimal. On the other hand, lose shift rate in all conditions (Fig 3b) have an inverted U shape as a function of alpha, where α = 0 leads to a random lose shift rate (1/3), and α = 1(fixed belief model) leads to the minimal lose shift rate. 3.2 Simulation of three behavioral types To examine if an individual’s belief of environmental stationarity can be used to explain different types of learning behavior, we fit DBM using Maximum Likelihood Estimation with the simulated behavioral data in 2.2. DBM results suggest that WSLS has a significantly lower belief of stationarity comparing to Expert behavior (Fig 3c), which is consistent with the higher volatility estimation reflected by a higher learning rate than Expert from R-W model (Fig 2c). Simulation results also suggest that No Learning agents have a significantly lower belief of stationarity than Expert learners, but not different from WSLS. However, the comparison of model accuracy between R-W and DBM (Fig 3d) shows DBM outperforms R-W in predicting Expert and WSLS behavior (p = .000), but it does not perform as well in No Learning behavior where R-W has significantly better performance (p = .000). Model accuracy is measured as the percentage of trials that the model correctly predicted subjects’ choice. Thus further investigation is needed to examine the validity of using DBM in explaining poor learners’ choice behavior in this task. Results for α in stable and high volatility condition can be seen in Supplementary Figure S2. alpha 0 0.2 0.4 0.6 0.8 1 Lose Shift% 0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1 Non N(30,1) N(10,1) Optimal choice% Lose shift% a b c DBM_Softmax_Ncp, CP CompareNcp_10_30_DBM.m alpha 0 0.2 0.4 0.6 0.8 1 Optimal choice% 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1 Non N(30,1) N(10,1) check_simuDBM.m d Add optimal alpha in Non, 45, 30, 10 CompareNcp_10_30_45_DBM.m Stable Low volatility High volatility α Learning type Belief of stationarity Belief of stationarity α Belief of stationarity α Learning type (Low volatility) (Low volatility) Simu_DBM_bk_low.m check_simuDBM_low.m No learning Expert WSLS 0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1 Compare_Simu_TD_DBM.m No learning Expert WSLS 0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1 RW DBM Model accuracy Figure 3 Figure 3: DBM simulation. a. Percentage of trials in which agents chose the optimal choice (the most likely location) as a function of α in three volatility conditions. b: Lose shift rate as a function of α in three volatility conditions. c. α estimation of three types of behavior in low volatility condition (N(30, 1)). d. Model performance comparison between R-W and DBM in low volatility condition. 5 Table 2: DBM: Influence of stationarity belief α Condition Decision optimality Lose-shift rate Stable Positive linear relationship, αoptimal =1 Inverted U shape Low volatility Inverted U shape, αoptimal = high Inverted U shape High volatility Inverted U shape, αoptimal = medium Inverted U shape 4 Experiment We applied the above models to two sets of data in a visual search task: (1) stable condition with no change points (from Yu & Huang, 2014) and (2) low volatility condition with change points based on N(30, 1). For both data sets, we fitted an R-W model and DBM for each subject, and compared learning rate η in R-W and estimation of stochasticity (1 −α) in DBM, as well as how they correlate with decision optimality and lose shift rate. For (2), we also looked at how model parameters differ in explaining No Learning, Expert and WSLS behavior. 4.1 Results 4.1.1 Stable condition In a visual search task with relative reward frequency 1:3:9 but no change points, we found a significant correlation between η estimated from R-W model and 1-α from DBM (r2 = .84, p = .0001, Fig 4a), which is consistent with the hypothesis that both the learning rate in R-W model and the belief of stochasticity in the Bayesian approach reflects subjects’ estimation of environmental volatility. We also examined the relationship between decision optimality (optimal choice%) (Fig 4b) and lose-shift rate (Fig 4c) with η and 1-α respectively. As is shown in Fig 4b, in this stable condition, decision optimality decreases as the learning rate increases, as well as the belief of stochasticity increases, which is consistent with Fig 2a (red, for η ≥.1) and Fig 3a (red). For lose-shift rate, there is a significant positive relationship between lose-shift% and η, as shown previously in Fig 2b (red), and an inverted U shape as suggested in Fig 3b (red). There are no significant differences in the prediction accuracy of R-W model and DBM (R-W: .81+/-.03, DBM: .81+/-.03) or inverse decision parameters (p > .05). 2 (RW) 0 0.5 1 Optimal choice% 0.5 0.6 0.7 0.8 0.9 1 Optimal choice% 1-, (DBM) 0 0.5 Optimal choice% 0.5 0.6 0.7 0.8 0.9 1 Optimal choice% 2 (RW) 0 0.5 1 Lose-shift% 0 0.2 0.4 0.6 0.8 1 Lose-shift% 1-, (DBM) 0 0.5 Lose-shift% 0 0.2 0.4 0.6 0.8 Lose-shift% eta-TD 0 0.2 0.4 0.6 0.8 1 alpha-DBM -0.2 -0.1 0 0.1 0.2 0.3 0.4 0.5 0.6 η (RW) 1-α (DBM) a b c Figure 4: Stable condition: R-W vs. DBM. a. Relationship between learning rate η in R-W model and 1-α in DBM. b. Optimal choice% as a function of η and 1-α. c. Lose-shift% as a function of η and 1-α. 4.1.2 Low volatility condition In a visual search task with relative reward frequency 1:3:9, and change of the reward contingency based on N(30, 1) (3 blocks of 90 trials/block), we looked at the correlation between model parameters, their correlation with decision optimality and lose-shift rate, as well as how model parameters differ in explaining different types of behavior. 6 Subjects (N=207) were grouped into poor learners (optimal choice%< .5, n = 63), good learners (.5≤optimal choice% ≤9/13, n = 108) and expert learners (optimal choice% > 9/13, n = 36) based on their performance (percentage of trials started from the most likely rewarded location). Consistent with what we have shown previously (Fig 3d-No Learning), R-W model outperformed DBM in poor learners (p = .000). Similar as in stable condition (Fig 4a), among good and expert learners, there is a significant positive correlation between η and 1-α (Fig 5b, r2 = .35, p = .000). The relationship between decision optimality and lose-shift% is shown in Fig 5c. As is shown, in this task where change points occur with relatively low frequency (N(30, 1)), lose shift% has an inverted U shape as a function of optimal choice%, indicating that a high lose-shift rate does not necessarily lead to better performance. a b c Good & Expert learners optimal choice% .1-.2 .2-.3 .3-.4 .4-.5 .5-6 .6-.7 .7-.8 .8-9 lose shift% -0.1 0 0.1 0.2 0.3 0.4 0.5 0.6 Optimal choice % vs. Lose-shift% Compare_TD2_DBM_overall.m Poor(<.5) Good(.5-9/13) Expert(>9/13) Model acc 0.6 0.65 0.7 0.75 0.8 0.85 0.9 RW DBM Model accuracy 2 (RW) 0 0.2 0.4 0.6 0.8 1 1-, (DBM) -0.1 0 0.1 0.2 0.3 0.4 0.5 0.6 Belief of stationarity α η (RW) 1-α(DBM) Figure 5: a. Prediction accuracy in poor, good and expert learners. b. Correlation between η from R-W and 1-α from DBM. c. Correlation between optimal choice% and lose-shift%. Next, we looked at how each model parameter correlates with decision optimality and lose-shift rate. For decision optimality (Fig 6ab), consistent with simulation result, it has an inverted U shape as a function of learning rate η in R-W model (Fig 6a), while it is positively correlated with α in DBM (Fig 6b). For lose-shift rate (Fig 6cd), also consistent with simulation result, it is positively correlated with η in R-W (Fig 6c), while having an inverted U shape as a function of α in DBM (Fig 6d). ,(DBM) 0-.2 .2-.4 .4-.6 .6-.8 .8-1 Optimal choice% 0.2 0.25 0.3 0.35 0.4 0.45 0.5 0.55 0.6 0.65 0.7 a Optimal choice % (DBM) ,(DBM) 0-.2 .2-.4 .4-.6 .6-.8 .8-1 LS% 0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 Lose-shift % (RW) Lose-shift % (DBM) b c d Compare_TD2_DBM_overall.m 2 (RW) 0-.2 .2-.4 .4-.6 .6-.8 .8-1 LS% 0.1 0.2 0.3 0.4 0.5 0.6 2 (RW) 0-.2 .2-.4 .4-.6 .6-.8 .8-1 Optimal choice% 0.4 0.45 0.5 0.55 0.6 0.65 0.7 Optimal choice % (RW) Learning rate η Belief of stationarity α Belief of stationarity α Learning rate η Figure 6: Decision optimality and lose-shift rate. a. Optimal choice% as a function of η in R-W model. b. Optimal choice% as a function of α in DBM. c. Lose-shift% as a function of η in R-W model. d. Lose-shift% as a function of α in DBM. In addition, we examined how poor, expert learners and individuals with a high lose-shift rate (LS, lose shift%> .5 and optimal choice% < 9/13, n = 51) differ in model parameters (Figure 7). Consistent with what we have shown (Fig 2c), those three different behavioral types had significantly different learning rate (one-way ANOVA, p = .000) and each condition is significant from each other (p = .000 for t test across conditions), in which poor learners had the lowest learning rate while subjects with high lose-shift rate had the highest learning rate (Fig 7a). Belief of stationarity from DBM also confirmed what we have shown (Fig 3c), that expert subjects had significantly higher belief of stationarity (one-way ANOVA, p = .003, and p = .004 for t test comparing to Poor subjects and p = .000 comparing to LS subjects). It also suggested that poor learners did not differ from LS subjects (p > .05), though DBM had a lower accuracy in predicting poor learners’ choices (Fig 5a). No significant difference of inverse decision parameter β was found between R-W and DBM for 7 expert and LS subjects (p > .05), but it was significantly lower in poor learners estimated in DBM (Supplementary Figure S3). a Compare_TD2_DBM_overall.m Poor Expert LS 1-α (DBM) η (RW) Figure 7 Compare_RW_DBM_overall.m 0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 Poor Expert LS Learning rate b , (DBM) 0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 Poor Expert LS Belief of stationarity Figure 7: Parameter estimation for different behavioral types. a. Learning rate in R-W model. b. Belief of stationarity in DBM. 5 Discussion In this paper we compared an R-W model and a Bayesian model in a visual search task across different volatility conditions, and examined parameter differences for different types of learning behavior. We have shown in simulation that both the learning rate η estimated from R-W and the belief of stochasticity 1 −α estimated from DBM have strong positive correlation with increasing volatility, and confirmed that they are highly correlated with behavioral data (Fig 4a and Fig5b). This suggests that both models are able to reflect an individual’s estimation of environmental volatility. We also have shown in simulation that R-W model can differentiate No Learning, Expert and WSLS behavioral types with (increasing) learning rate, and DBM can differentiate Expert and WSLS behavioral types with (increasing) belief of stochasticity, and confirmed this with behavioral data in a low volatility condition. A few other things to note here: Correlation between decision optimality and lose-shift rate. Here we have provided a modelbased explanation of using lose-shift strategy and how it is related to decision optimality. 1) R-W model suggests that, across different levels of environmental volatility, the frequency of using loseshift is positively correlated with learning rates (Fig 2b). However, decision optimality is NOT positively correlated with lose-shift rate across conditions. 2) DBM model suggests that, across different levels of environmental volatility, there is an inverted U shape relationship between the frequency of using lose-shift and one’s belief of stationarity (Fig 3b), and a close-to-linear relationship between decision optimality and the belief of stationarity in a low volatility environment (Fig 6b). Implications for model selection. We have shown that both models have comparable prediction accuracy for individuals with good performance, but R-W model is better in explaining poor learners’ choice. There are several possible reasons: 1) the Bayesian model assumed subjects would use the feedback information to update the posterior probability of target reward distribution. Thus for ’poor’ learners who did not use the feedback information, this assumption is no longer appropriate. 2) the R-W model assumed subjects would only update the chosen option’s value, thus error trials may have less influence (especially in the early stages, with low learning rate). That is, for 0 value option, it will remain 0 if not rewarded, and for the highest value option, it will remain being the highest value option even if not rewarded. Therefore, R-W model may capture poor learners’ search pattern better with a low learning rate. Future directions. For future work, we will modify current R-W model with a dynamic learning rate that will change based on value estimation, and modify current DBM model with a parameter that controls how much feedback information is used in updating posterior belief and a hyper-parameter that models the dynamic of α. Acknowledgements We thank Angela Yu for sharing the data in Yu et al. 2014, and for allowing us to use it in this paper. 8 References [1] Lee, M. D., Zhang, S., Munro, M., & Steyvers, M. (2011). Psychological models of human and optimal performance in bandit problems. Cognitive Systems Research, 12(2), 164-174. [2] Behrens, T. E., Woolrich, M. W., Walton, M. E., & Rushworth, M. F. (2007). Learning the value of information in an uncertain world. Nature neuroscience, 10(9), 1214-1221. [3] Mathys, C. D., Lomakina, E. I., Daunizeau, J., Iglesias, S., Brodersen, K. H., Friston, K. J., & Stephan, K. E. (2014). Uncertainty in perception and the Hierarchical Gaussian Filter. Front Hum Neurosci, 8. [4] Yu, A. J., & Huang, H. (2014). Maximizing masquerading as matching in human visual search choice behavior. Decision, 1(4), 275. [5] Rescorla, R. A., & Wagner, A. R. (1972). A theory of Pavlovian conditioning: Variations in the effectiveness of reinforcement and nonreinforcement. Classical conditioning II: Current research and theory, 2, 64-99. [6] Sutton, R. S., & Barto, A. G. (1998). Reinforcement learning: An introduction. MIT press. [7] Browning, M., Behrens, T. E., Jocham, G., O’Reilly, J. X., & Bishop, S. J. (2015). Anxious individuals have difficulty learning the causal statistics of aversive environments. Nature neuroscience, 18(4), 590-596. [8] Yu, A. J., & Cohen, J. D. (2009). Sequential effects: superstition or rational behavior?. In Advances in neural information processing systems (pp. 1873-1880). [9] Gershman, S. J. (2015). A Unifying Probabilistic View of Associative Learning. PLoS Comput Biol, 11(11), e1004567. [10] Blakely, E., Starin, S., & Poling, A. (1988). Human performance under sequences of fixed-ratio schedules: Effects of ratio size and magnitude of reinforcement. The Psychological Record, 38(1), 111. [11] Kahneman, D., & Frederick, S. (2002). Representativeness revisited: Attribute substitution in intuitive judgment. Heuristics and biases: The psychology of intuitive judgment, 49. [12] Worthy, D. A., & Maddox, W. T. (2014). A comparison model of reinforcement-learning and win-stay-loseshift decision-making processes: A tribute to WK Estes. Journal of mathematical psychology, 59, 41-49. [13] Bonawitz, E., Denison, S., Gopnik, A., & Griffiths, T. L. (2014). Win-Stay, Lose-Sample: A simple sequential algorithm for approximating Bayesian inference. Cognitive psychology, 74, 35-65. 9 | 2016 | 53 |
6,472 | Correlated-PCA: Principal Components’ Analysis when Data and Noise are Correlated Namrata Vaswani and Han Guo Iowa State University, Ames, IA, USA Email: {namrata,hanguo}@iastate.edu Abstract Given a matrix of observed data, Principal Components Analysis (PCA) computes a small number of orthogonal directions that contain most of its variability. Provably accurate solutions for PCA have been in use for a long time. However, to the best of our knowledge, all existing theoretical guarantees for it assume that the data and the corrupting noise are mutually independent, or at least uncorrelated. This is valid in practice often, but not always. In this paper, we study the PCA problem in the setting where the data and noise can be correlated. Such noise is often also referred to as “data-dependent noise”. We obtain a correctness result for the standard eigenvalue decomposition (EVD) based solution to PCA under simple assumptions on the data-noise correlation. We also develop and analyze a generalization of EVD, cluster-EVD, that improves upon EVD in certain regimes. 1 Introduction Principal Components Analysis (PCA) is among the most frequently used tools for dimension reduction. Given a matrix of data, it computes a small number of orthogonal directions that contain all (or most) of the variability of the data. The subspace spanned by these directions is the “principal subspace”. To use PCA for dimension reduction, one projects the observed data onto this subspace. The standard solution to PCA is to compute the reduced singular value decomposition (SVD) of the data matrix, or, equivalently, to compute the reduced eigenvalue decomposition (EVD) of the empirical covariance matrix of the data. If all eigenvalues are nonzero, a threshold is used and all eigenvectors with eigenvalues above the threshold are retained. This solution, which we henceforth refer to as simple EVD, or just EVD, has been used for many decades and is well-studied in literature, e.g., see [1] and references therein. However, to the best of our knowledge, all existing results for it assume that the true data and the corrupting noise in the observed data are independent, or, at least, uncorrelated. This is valid in practice often, but not always. Here, we study the PCA problem in the setting where the data and noise vectors may be correlated (correlated-PCA). Such noise is sometimes called “data-dependent” noise. Contributions. (1) Under a boundedness assumption on the true data vectors, and some other assumptions, for a fixed desired subspace error level, we show that the sample complexity of simpleEVD for correlated-PCA scales as f 2r2 log n where n is the data vector length, f is the condition number of the true data covariance matrix and r is its rank. Here “sample complexity” refers to the number of samples needed to get a small enough subspace recovery error with high probability (whp). The dependence on f 2 is problematic for datasets with large condition numbers, and, especially in the high dimensional setting where n is large. (2) To address this, we also develop and analyze a generalization of simple-EVD, called cluster-EVD. Under an eigenvalues’ “clustering” assumption, cluster-EVD weakens the dependence on f. To our best knowledge, the correlated-PCA problem has not been explicitly studied. We first encountered it while solving the dynamic robust PCA problem in the Recursive Projected Compressive Sensing (ReProCS) framework [2, 3, 4, 5]. The version of correlated-PCA studied here is motivated 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. by these works. Some other somewhat related recent works include [6, 7] that study stochastic optimization based techniques for PCA; and [8, 9, 10, 11] that study online PCA. Notation. We use the interval notation [a, b] to mean all of the integers between a and b, inclusive, and similarly for [a, b) etc. We use ∥· ∥to denote the l2 norm of a vector or the induced l2 norm of a matrix. For other lp norms, we use ∥· ∥p. For a set T , IT refers to an n × |T | matrix of columns of the identity matrix indexed by entries in T . For a matrix A, AT := AIT . A tall matrix with orthonormal columns is referred to as a basis matrix. For basis matrices ˆP and P , we quantify the subspace error (SE) between their range spaces using SE( ˆP , P ) := ∥(I −ˆP ˆP ′)P ∥. (1) 1.1 Correlated-PCA: Problem Definition We are given a time sequence of data vectors, yt, that satisfy yt = ℓt + wt, with wt = Mtℓt and ℓt = P at (2) where P is an n × r basis matrix with r ≪n. Here ℓt is the true data vector that lies in a low dimensional subspace of Rn, range(P ); at is its projection into this r-dimensional subspace; and wt is the data-dependent noise. We refer to Mt as the correlation / data-dependency matrix. The goal is to estimate range(P ). We make the following assumptions on ℓt and Mt. Assumption 1.1. The subspace projection coefficients, at, are zero mean, mutually independent and bounded random vectors (r.v.), with a diagonal covariance matrix Λ. Define λ−:= λmin(Λ), λ+ := λmax(Λ) and f := λ+ λ−. Since the at’s are bounded, we can also define a finite constant η := maxj=1,2,...r maxt (at)2 j λj . Thus, (at)2 j ≤ηλj. For most bounded distributions, η will be a small constant more than one, e.g., if the distribution of all entries of at is iid zero mean uniform, then η = 3. From Assumption 1.1, clearly, the ℓt’s are also zero mean, bounded, and mutually independent r.v.’s with a rank r covariance matrix Σ EVD = P ΛP ′. In the model, for simplicity, we assume Λ to be fixed. However, even if we replace Λ by Λt and define λ−= mint λmin(Λt) and λ+ = λmax(Λt), all our results will still hold. Assumption 1.2. Decompose Mt as Mt = M2,tM1,t. Assume that ∥M1,tP ∥≤q < 1, ∥M2,t∥≤1, (3) and, for any sequence of positive semi-definite Hermitian matrices, At, the following holds for a β < α,
1 α α X t=1 M2,tAtM2,t ′
≤β α max t∈[1,α] ∥At∥. (4) We will need the above to hold for all α ≥α0 and for all β ≤c0α with a c0 ≪1. We set α0 and c0 in Theorems 2.1 and 3.3; both will depend on q. Observe that, using (3), ∥wt∥ ∥ℓt∥≤q, and so q is an upper bound on the signal-to-noise ratio (SNR). To understand the assumption on M2,t, notice that, if we allow β = α, then (4) always holds and is not an assumption. Let B denote the matrix on the LHS of (4). One example situation when (4) holds with a β ≪α is if B is block-diagonal with blocks At. In this case, it holds with β = 1. In fact, it also holds with β = 1 if B is permutation-similar to a block diagonal matrix. The matrix B will be of this form if M2,t = ITt with all the sets Tt being mutually disjoint. More generally, if B is permutation-similar to a block-diagonal matrix with blocks given by the summation of At’s over at most β0 < α time instants, then (4) holds with β = β0. This will happen if M2,t = ITt with Tt = T [k] for at most β0 time instants and if sets T [k] are mutually disjoint for different k. Finally, the T [k]’s need not even be mutually disjoint. As long as they are such that B is a matrix with nonzero blocks on only the main diagonal and on a few diagonals near it, e.g., if it is block tri-diagonal, it can be shown that the above assumption holds. This example is generalized in Assumption 1.3 given below. 1.2 Examples of correlated-PCA problems One key example of correlated-PCA is the PCA with missing data (PCA-missing) problem. Let Tt denote the set of missing entries at time t. Suppose, we set the missing entries of yt to zero. Then, yt = ℓt −ITtITt ′ℓt. (5) 2 In this case M2,t = ITt and M1,t = −ITt ′. Thus, q is an upper bound on ∥ITt ′P ∥. Clearly, it will be small if the columns of P are dense vectors. For the reader familiar with low-rank matrix completion (MC), e.g., [12, 13], PCA-missing can also be solved by first solving the low-rank matrix completion problem to recover L, followed by PCA on the completed matrix. This would, of course, be much more expensive than directly solving PCA-missing and would need more assumptions. Another example where correlated-PCA occurs is that of robust PCA (low-rank + sparse formulation) [14, 15, 16] when the sparse component’s magnitude is correlated with ℓt. Let Tt denote the support set of wt and let xt be the |Tt|-length vector of its nonzero entries. If we assume linear dependency of xt on ℓt, we can write out yt as yt = ℓt + ITtxt = ℓt + ITtMs,tℓt. (6) Thus M2,t = ITt and M1,t = Ms,t and so q is an upper bound on ∥Ms,tP ∥. In the rest of the paper, we refer to this problem is “PCA with sparse data-dependent corruptions (PCA-SDDC)”. One key application where it occurs is in foreground-background separation for videos consisting of a slow changing background sequence (modeled as lying close to a low-dimensional subspace) and a sparse foreground image sequence consisting typically of one or more moving objects [14]. The PCA-SDDC problem is to estimate the background sequence’s subspace. In this case, ℓt is the background image at time t, Tt is the support set of the foreground image at t, and xt is the difference between foreground and background intensities on Tt. An alternative solution approach for PCA-SDDC is to use an RPCA solution such as principal components’ pursuit (PCP) [14, 15] or Alternating-Minimization (Alt-Min-RPCA) [17] to first recover the matrix L followed by PCA on L. However, as shown in Sec. 5, Table 1, this approach will be much slower; and it will work only if its required incoherence assumptions hold. For example, if the columns of P are sparse, it fails. For both problems above, a solution for PCA will work only when the corrupting noise wt is small compared to ℓt. A sufficient condition for this is that q is small. A third example where correlated-PCA and its generalization, correlated-PCA with partial subspace knowledge, occurs is in the subspace update step of Recursive Projected Compressive Sensing (ReProCS) for dynamic robust PCA [3, 5]. In all three of the above applications, the assumptions on the data-noise correlation matrix given in Assumption 1.2 hold if there are enough changes of a certain type in the set of missing or corrupted entries, Tt. One example where this is true is in case of a 1D object of length s or less that remains static for at most β frames at a time. When it moves, it moves by at least a certain fraction of s pixels. The following assumption is inspired by the object’s support. Assumption 1.3. Let l denote the number of times the set Tt changes in the interval [1, α] (or in any given interval of length α in case of dynamic robust PCA). So 0 ≤l ≤α −1. Let t0 := 1; let tk, with tk < tk+1, denote the time instants in this interval at which Tt changes; and let T [k] denote the distinct sets. In other words, Tt = T [k] for t ∈[tk, tk+1), for each k = 1, 2, . . . , l. Assume that the following hold with a β < α: 1. (tk+1 −tk) ≤˜β and |T [k]| ≤s; 2. ρ2 ˜β ≤β where ρ is the smallest positive integer so that, for any 0 ≤k ≤l, T [k] and T [k+ρ] are disjoint; 3. for any k1, k2 satisfying 0 ≤k1 < k2 ≤l, the sets (T [k1] \ T [k1+1]) and (T [k2] \ T [k2+1]) are disjoint. An implicit assumption for condition 3 to hold is that Pl k=0 |T [k] \ T [k+1]| ≤n. Observe that conditions 2 and 3 enforce an upper bound on the maximum support size s. To connect Assumption 1.3 with the moving object example given above, condition 1 holds if the object’s size is at most s and if it moves at least once every ˜β frames. Condition 2 holds, if, every time it moves, it moves in the same direction and by at least s ρ pixels. Condition 3 holds if, every time it moves, it moves in the same direction and by at most d0 ≥s ρ pixels, with d0α ≤n (or, more generally, the motion is such that, if the object were to move at each frame, and if it started at the top of the frame, it does not reach the bottom of the frame in a time interval of length α). The following lemma [4] shows that, with Assumption 1.3 on Tt, M2,t = ITt satisfies the assumption on M2,t given in Assumption 1.2. Its proof generalizes the discussion below Assumption 1.2. 3 Lemma 1.4. [[4], Lemmas 5.2 and 5.3] Assume that Assumption 1.3 holds. For any sequence of |Tt| × |Tt| symmetric positive-semi-definite matrices At, ∥ α X t=1 ITtAtITt ′∥≤(ρ2 ˜β) max t∈[1,α] ∥At∥≤β max t∈[1,α] ∥At∥ Thus, if ∥ITt ′P ∥≤q < 1, then the PCA-missing problem satisfies Assumption 1.2. If ∥Ms,tP ∥≤ q < 1, then the PCA-SDDC problem satisfies Assumption 1.2. Assumption 1.3 is one model on Tt that ensures that, if M2,t = ITt, the assumption on M2,t given in Assumption 1.2 holds. For its many generalizations, see Supplementary Material, Sec. 7, or [4]. As explained in [18], data-dependent noise also often occurs in molecular biology applications when the noise affects the measurement levels through the very same process as the interesting signal. 2 Simple EVD Simple EVD computes the top eigenvectors of the empirical covariance matrix, 1 α Pα t=1 ytyt′, of the observed data. The following can be shown. Theorem 2.1 (simple-EVD result). Let ˆP denote the matrix containing all the eigenvectors of 1 α Pα t=1 ytyt′ with eigenvalues above a threshold, λthresh, as its columns. Pick a ζ so that rζ ≤0.01. Suppose that yt’s satisfy (2) and the following hold. 1. Assumption 1.1 on ℓt holds. Define α0 := Cη2 r211 log n (rζ)2 max(f, qf, q2f)2, C := 32 0.012 . 2. Assumption 1.2 on Mt holds for any α ≥α0 and for any β satisfying β α ≤ 1 −rζ 2 2 min (rζ)2 4.1(qf)2 , (rζ) q2f 3. Set algorithm parameters λthresh = 0.95λ−and α ≥α0. Then, with probability at least 1 −6n−10, SE( ˆP , P ) ≤rζ. Proof: The proof involves a careful application of the sin θ theorem [19] to bound the subspace error, followed by using matrix Hoeffding [20] to obtain high probability bounds on each of the terms in the sin θ bound. It is given in the Supplementary Material, Section 8. Consider the lower bound on α. We refer to this as the “sample complexity”. Since q < 1, and η is a small constant (e.g., for the uniform distribution, η = 3), for a fixed error level, rζ, α0 simplifies to cf 2r2 log n. Notice that the dependence on n is logarithmic. It is possible to show that the sample complexity scales as log n because we assume that the ℓt’s are bounded r.v.s. As a result we can apply the matrix Hoeffding inequality [20] to bound the perturbation between the observed data’s empirical covariance matrix and that of the true data. The bounded r.v. assumption is actually a more practical one than the usual Gaussian assumption since most sources of data have finite power. By replacing matrix Hoeffding by Theorem 5.39 of [21] in places where one can apply a concentration of measure result to P t atat′/α (which is at r × r matrix), and by matrix Bernstein [20] elsewhere, it should be possible to further reduce the sample complexity to c max((qf)2r log n, f 2(r + log n)). It should also be possible remove the boundedness assumption and replace it by a Gaussian (or a sub-Gaussian) assumption, but, that would increase the sample complexity to c(qf)2n. Consider the upper bound on β/α. Clearly, the smaller term is the first one. This depends on 1/(qf)2. Thus, when f is large and q is not small enough, the bound required may be impractically small. As will be evident from the proof (see Remark 8.3 in Supplementary Material), we get this bound because wt is correlated with ℓt and this results in E[ℓtwt′] ̸= 0. If wt and ℓt were uncorrelated, qf would get replaced by λmax(Cov(wt)) λ− in the upper bound on β/α as well as in the sample complexity. Application to PCA-missing and PCA-SDDC. By Lemma 1.4, the following is immediate. 4 0 5 10 15 20 25 30 35 6 7 8 9 10 11 12 13 14 15 16 log of eigs of curtain video log of eigs of lake video log of eigs of waving−tree video Figure 1: Eigenvalue clusters of the three low-rankified videos. Corollary 2.2. Consider the PCA-missing model, (5), and assume that maxt ∥ITt ′P ∥≤q < 1; or consider the PCA-SDDC model, (6), and assume that maxt ∥Ms,tP ∥≤q < 1. Assume that everything in Theorem 2.1 holds except that we replace Assumption 1.2 by Assumption 1.3. Then, with probability at least 1 −6n−10, SE( ˆP , P ) ≤rζ. 3 Cluster-EVD To try to relax the strong dependence on f 2 of the result above, we develop a generalization of simple-EVD that we call cluster-EVD. This requires the clustering assumption. 3.1 Clustering assumption To state the assumption, define the following partition of the index set {1, 2, . . . r} based on the eigenvalues of Σ. Let λi denote its i-th largest eigenvalue. Definition 3.1 (g-condition-number partition of {1, 2, . . . r}). Define G1 = {1, 2, . . . r1} where r1 is the index for which λ1 λr1 ≤g and λ1 λr1+1 > g. In words, to define G1, start with the index of the first (largest) eigenvalue and keep adding indices of the smaller eigenvalues to the set until the ratio of the maximum to the minimum eigenvalue first exceeds g. For each k > 1, define Gk = {r∗+1, r∗+2, . . . , r∗+rk} where r∗= (Pk−1 i=1 ri), rk is the index for which λr∗+1 λr∗+rk ≤g and λr∗+1 λr∗+rk+1 > g. In words, to define Gk, start with the index of the (r∗+ 1)-th eigenvalue, and repeat the above procedure. Stop when λr∗+rk+1 = 0, i.e., when there are no more nonzero eigenvalues. Define ϑ = k as the number of sets in the partition. Thus {G1, G2, . . . , Gϑ} is the desired partition. Define G0 = [.], Gk := (P )Gk, λ+ k := maxi∈Gk λi (Λ), λ− k := mini∈Gk λi (Λ) and χ := max k=1,2,...,ϑ λ+ k+1 λ− k . χ quantifies the “distance” between consecutive sets of the above partition. Moreover, by definition, λ+ k λ− k ≤g. Clearly, g ≥1 and χ ≤1 always. We assume the following. Assumption 3.2. For a 1 ≤g+ < f and a 0 ≤χ+ < 1, assume that there exists a g satisfying 1 ≤g ≤g+ and a χ satisfying 0 ≤χ ≤χ+, for which we can define a g-condition-number partition of {1, 2, . . . r} that satisfies χ ≤χ+. The number of sets in the partition is ϑ. When g+ and χ+ are small, we say that the eigenvalues are “well-clustered” with “clusters”, Gk. This assumption can be understood as a generalization of the eigen-gap condition needed by the block power method, which is a fast algorithm for obtaining the k top eigenvectors of a matrix [22]. We expect it to hold for data that has variability across different scales. The large scale variations would result in the first (largest eigenvalues’) cluster and the smaller scale variations would form the later clusters. This would be true, for example, for video “textures” such as moving waters or waving trees in a forest. We tested this assumption on some such videos. We describe our conclusions here for three videos - “lake” (video of moving lake waters), “waving-tree” (video consisting of waving trees), and “curtain” (video of window curtains moving due to the wind). For each video, we first made it low-rank by keeping the eigenvectors corresponding to the smallest number of eigenvalues that contain at least 90% of the total energy and projecting the video onto this subspace. For the low-rankified lake video, f = 74 and Assumption 3.2 holds with ϑ = 6 clusters, g+ = 2.6 and χ+ = 0.7. For the waving-tree video, f = 180 and Assumption 3.2 holds with ϑ = 6, g+ = 9.4 and χ+ = 0.72. For the curtain video, f = 107 and the assumption holds ϑ = 3, g+ = 16.1 and χ+ = 0.5. We show the clusters of eigenvalues in Fig. 1. 5 Algorithm 1 Cluster-EVD Parameters: α, ˆg, λthresh. Set ˆG0 ←[.]. Set the flag Stop ←0. Set k ←1. Repeat 1. Let ˆGdet,k := [ ˆG0, ˆG1, . . . ˆGk−1] and let Ψk := (I −ˆGdet,k ˆGdet,k′). Notice that Ψ1 = I. Compute ˆDk = Ψk 1 α kα X t=(k−1)α+1 ytyt ′ Ψk 2. Find the k-th cluster, ˆGk: let ˆλi = λi( ˆDk); (a) find the index ˆrk for which ˆλ1 ˆλˆrk ≤ˆg and either ˆλ1 ˆλˆrk+1 > ˆg or ˆλˆrk+1 < λthresh; (b) set ˆGk = {ˆr∗+ 1, ˆr∗+ 2, . . . , ˆr∗+ ˆrk} where ˆr∗:= Pk−1 j=1 ˆrj; (c) if ˆλˆrk+1 < λthresh, update the flag Stop ←1 3. Compute ˆGk ←eigenvectors( ˆDk, ˆrk); increment k Until Stop == 1. Set ˆϑ ←k. Output ˆP ←[ ˆG1 · · · ˆG ˆϑ]. eigenvectors(M, r) returns a basis matrix for the span of the top r eigenvectors of M. 3.2 Cluster-EVD algorithm The cluster-EVD approach is summarized in Algorithm 1. I Its main idea is as follows. We start by computing the empirical covariance matrix of the first set of α observed data points, ˆD1 := 1 α Pα t=1 ytyt′. Let ˆλi denote its i-th largest eigenvalue. To estimate the first cluster, ˆG1, we start with the index of the first (largest) eigenvalue and keep adding indices of the smaller eigenvalues to it until the ratio of the maximum to the minimum eigenvalue exceeds ˆg or until the minimum eigenvalue goes below a “zero threshold”, λthresh. Then, we estimate the first cluster’s subspace, range(G1) by computing the top ˆr1 eigenvectors of ˆD1. To get the second cluster and its subspace, we project the next set of α yt’s orthogonal to ˆG1 followed by repeating the above procedure. This is repeated for each k > 1. The algorithm stops when ˆλˆrk+1 < λthresh. Algorithm 1 is related to, but significantly different from, the ones introduced in [3, 5] for the subspace deletion step of ReProCS. The one introduced in [3] assumed that the clusters were known to the algorithm (which is unrealistic). The one studied in [5] has an automatic cluster estimation approach, but, one that needs a larger lower bound on α compared to what Algorithm 1 needs. 3.3 Main result We give the performance guarantee for Algorithm 1 here. Its parameters are set as follows. We set ˆg to a value that is a little larger than g. This is needed to allow for the fact that ˆλi is not equal to the i-th eigenvalue of Λ but is within a small margin of it. For the same reason, we need to also use a nonzero “zeroing” threshold, λthresh, that is larger than zero but smaller than λ−. We set α large enough to ensure that SE( ˆP , P ) ≤rζ holds with a high enough probability. Theorem 3.3 (cluster-EVD result). Consider Algorithm 1. Pick a ζ so that r2ζ ≤ 0.0001, and r2ζf ≤0.01. Suppose that yt’s satisfy (2) and the following hold. 1. Assumption 1.1 and Assumption 3.2 on ℓt hold with χ+ satisfying χ+ ≤min(1 −rζ − 0.08 0.25, g+−0.0001 1.01g++0.0001 −0.0001). Define α0 := Cη2 r2(11 log n + log ϑ) (rζ)2 max(g+, qg+, q2f, q(rζ)f, (rζ)2f, q p fg+, (rζ) p fg+)2, C := 32 · 16 0.012 . 2. Assumption 1.2 on Mt holds with α ≥α0 and with β satisfying β α ≤ (1 −rζ −χ+) 2 2 min (rkζ)2 4.1(qg+)2 , (rkζ) q2f . 6 3. Set algorithm parameters ˆg = 1.01g+ + 0.0001, λthresh = 0.95λ−and α ≥α0. Then, with probability at least 1 −12n−10, SE( ˆP , P ) ≤rζ. Proof: The proof is given in Section 9 in Supplementary Material. We can also get corollaries for PCA-missing and PCA-SDDC for cluster-EVD. We have given one specific value for ˆg and λthresh in Theorem 3.3 for simplicity. One can, in fact, set ˆg to be anything that satisfies (12) given in Supplementary Material and one can set λthresh to be anything satisfying 5rζλ−≤λthresh ≤0.95λ−. Also, it should be possible to reduce the sample complexity of clusterEVD to c max(q2(g+)2r log n, (g+)2(r + log n)) using the approach explained in Sec. 2. 4 Discussion Comparing simple-EVD and cluster-EVD. Consider the lower bounds on α. In the cluster-EVD (c-EVD) result, Theorem 3.3, if q is small enough (e.g., if q ≤1/√f), and if (r2ζ)f ≤0.01, it is clear that the maximum in the max(., ., ., .) expression is achieved by (g+)2. Thus, in this regime, c-EVD needs α ≥C r2(11 log n+log ϑ) (rζ)2 g2 and its sample complexity is ϑα. In the EVD result (Theorem 2.1), g+ gets replaced by f and ϑ by 1, and so, its sample complexity, α ≥C r211 log n (rζ)2 f 2. In situations where the condition number f is very large but g+ is much smaller and ϑ is small (the clustering assumption holds well), the sample complexity of c-EVD will be much smaller than that of simple-EVD. However, notice that, the lower bound on α for simple-EVD holds for any q < 1 and for any ζ with rζ < 0.01 while the c-EVD lower bound given above holds only when q is small enough, e.g., q = O(1/√f), and ζ is small enough, e.g., rζ = O(1/f). This tighter bound on ζ is needed because the error of the k-th step of c-EVD depends on the errors of the previous steps times f. Secondly, the c-EVD result also needs χ+ and ϑ to be small (clustering assumption holds well), whereas, for simple-EVD, by definition, χ+ = 0 and ϑ = 1. Another thing to note is that the constants in both lower bounds are very large with the c-EVD one being even larger. To compare the upper bounds on β, assume that the same α is used by both, i.e., α = max(α0(EVD), α0(c-EVD)). As long as rk is large enough, χ+ is small enough, and g is small enough, the upper bound on β needed by the c-EVD result is significantly looser. For example, if χ+ = 0.2, ϑ = 2, rk = r/2, then c-EVD needs β ≤(0.5 · 0.79 · 0.5)2 (rζ)2 4.1q2g2 α while simple-EVD needs β ≤(0.5 · 0.99)2 (rζ)2 4.1q2f 2 α. If g = 3 but f = 100, clearly the c-EVD bound is looser. Comparison with other results for PCA-SDDC and PCA-missing. To our knowledge, there is no other result for correlated-PCA. Hence, we provide comparisons of the corollaries given above for the PCA-missing and PCA-SDDC special cases with works that also study these or related problems. An alternative solution for either PCA-missing or PCA-SDDC is to first recover the entire matrix L and then compute its subspace via SVD on the estimated L. For the PCA-missing problem, this can be done by using any of the low-rank matrix completion techniques, e.g., nuclear norm minimization (NNM) [13] or alternating minimization (Alt-Min-MC) [23]. Similarly, for PCA-SDDC, this can be done by solving any of the recent provably correct RPCA techniques such as principal components’ pursuit (PCP) [14, 15, 16] or alternating minimization (Alt-Min-RPCA) [17]. However, as explained earlier doing the above has two main disadvantages. The first is that it is much slower (see Sec. 5). The difference in speed is most dramatic when solving the matrix-sized convex programs such as NNM or PCP, but even the Alt-Min methods are slower. If we use the time complexity from [17], then finding the span of the top k singular vectors of an n × m matrix takes O(nmk) time. Thus, if ϑ is a constant, both simple-EVD and c-EVD need O(nαr) time, whereas, Alt-Min-RPCA needs O(nαr2) time per iteration [17]. The second disadvantage is that the above methods for MC or RPCA need more assumptions to provably correctly recover L. All the above methods need an incoherence assumption on both the left singular vectors, P , and the right singular vectors, V , of L. Of course, it is possible that, if one studies these methods with the goal of only recovering the column space of L correctly, the incoherence assumption on the right singular vectors is not needed. From simulation experiments (see Sec. 5), the incoherence of the left singular vectors is definitely needed. On the other hand, for the PCA-SDDC problem, simple-EVD or c-EVD do not even need the incoherence assumption on P . The disadvantage of both EVD and c-EVD, or in fact of any solution for the PCA problem, is that they work only when q is small enough (the corrupting noise is small compared to ℓt). 7 Mean Subspace Error (SE) Average Execution Time c-EVD EVD PCP A-M-RPCA c-EVD EVD PCP A-M-RPCA Expt 1 0.0908 0.0911 1.0000 1.0000 0.0549 0.0255 0.2361 0.0810 Expt 2 0.3626 0.3821 0.4970 0.4846 0.0613 0.0223 1.6784 5.5144 Table 1: Comparison of SE( ˆ P , P ) and execution time (in seconds). A-M-RPCA: Alt-Min-RPCA. Expt 1: simulated data, Expt 2: lake video with simulated foreground. 5 Numerical Experiments We use the PCA-SDDC problem as our case study example. We compare EVD and cluster-EVD (c-EVD) with PCP [15], solved using [24], and with Alt-Min-RPCA [17] (implemented using code from the authors’ webpage). For both PCP and Alt-Min-RPCA, ˆP is recovered as the top r eigenvectors of of the estimated L. To show the advantage of EVD or c-EVD, we let ℓt = P at with columns of P being sparse. These were chosen as the first r = 5 columns of the identity matrix. We generate at’s iid uniformly with zero mean and covariance matrix Λ = diag(100, 100, 100, 0.1, 0.1). Thus the condition number f = 1000. The clustering assumption holds with ϑ = 2, g+ = 1 and χ+ = 0.001. The noise wt is generated as wt = ITtMs,tℓt with Tt generated to satisfy Assumption 1.3 with s = 5, ρ = 2, and ˜β = 1; and the entries of Ms,t being iid N(0, q2) with q = 0.01. We used n = 500. EVD and c-EVD (Algorithm 1) were implemented with α = 300, λthresh = 0.095, ˆg = 3. 10000-time Monte Carlo averaged values of SE( ˆP , P ) and execution time are shown in the first row of Table 1. Since the columns of P are sparse, both PCP and Alt-Min-RPCA fail. Both have average SE close to one whereas the average SE of c-EVD and EVD is 0.0908 and 0.0911 respectively. Also, both EVD and c-EVD are much faster than the other two. We also did an experiment with the settings of this experiment, but with P dense. In this case, EVD and c-EVD errors were similar, but PCP and Alt-Min-RPCA errors were less than 10−5. For our second experiment, we used images of a low-rankified real video sequence as ℓt’s. We chose the escalator sequence from http://perception.i2r.a-star.edu.sg/bk_ model/bk_index.html since the video changes are only in the region where the escalator moves (and hence can be modeled as being sparse). We made it exactly low-rank by retaining its top 5 eigenvectors and projecting onto their subspace. This resulted in a data matrix L of size n × 2α with n = 20800 and α = 50, of rank r = 5. We overlaid a simulated moving foreground block on it. The intensity of the moving block was controlled to ensure that q is small. We used α = 50 for EVD and c-EVD. We let P be the eigenvectors of the low-rankified video with nonzero eigenvalues and computed SE( ˆP , P ). The errors and execution time are displayed in the second row of Table 1. Since n is very large, the difference in speed is most apparent in this case. Thus c-EVD outperforms PCP and AltMinRPCA when columns of P are sparse. It also outperforms EVD but the advantage in mean error is not as much as our theorems predict. One reason is that the constant in the required lower bounds on α is very large. It is hard to pick an α that is this large and still only O(log n) unless n is very large. Secondly, both guarantees are only sufficient conditions. 6 Conclusions and Future Work We studied the problem of PCA in noise that is correlated with the data (data-dependent noise). We obtained sample complexity bounds for the most commonly used PCA solution, simple EVD. We also developed and analyzed a generalization of EVD, called cluster-EVD, that has lower sample complexity under extra assumptions. We provided a detailed comparison of our results with those for other approaches to solving its example applications - PCA with missing data and PCA with sparse data-dependent corruptions. We used matrix Hoeffding [20] to obtain our results. As explained in Sec. 2, we can significantly improve the sample complexity bounds if this is replaced by [21, Theorem 5.39] and matrix Bernstein at appropriate places. We have obtained such a result in ongoing work [25]. Moreover, as done in [5] (for ReProCS), the mutual independence of ℓt’s can be easily replaced by a more practical assumption of ℓt’s following autoregressive model with almost no change to our assumptions. Thirdly, by generalizing the proof techniques developed here, we can also study the problem of correlatedPCA with partial subspace knowledge. The solution to the latter problem helps to greatly simplify the proof of correctness of ReProCS for online dynamic RPCA. The boundedness assumption on ℓt’s can be replaced by a Gaussian or a well-behaved sub-Gaussian assumption but this will increase the sample complexity to O(n). Finally, an open-ended question is how we relax Assumption 1.2 on Mt and still get results similar to Theorem 2.1 or Theorem 3.3. 8 References [1] B. Nadler, “Finite sample approximation results for principal component analysis: A matrix perturbation approach,” The Annals of Statistics, vol. 36, no. 6, 2008. [2] C. Qiu and N. Vaswani, “Real-time robust principal components’ pursuit,” in Allerton Conf. on Communication, Control, and Computing, 2010. [3] C. Qiu, N. Vaswani, B. Lois, and L. Hogben, “Recursive robust pca or recursive sparse recovery in large but structured noise,” IEEE Trans. Info. Th., pp. 5007–5039, August 2014. [4] B. Lois and N. Vaswani, “Online matrix completion and online robust pca,” in IEEE Intl. Symp. Info. Th. (ISIT), 2015. [5] J. Zhan, B. Lois, H. Guo, and N. Vaswani, “Online (and Offline) Robust PCA: Novel Algorithms and Performance Guarantees,” in Intnl. Conf. Artif. Intell. and Stat. (AISTATS), 2016. [6] R. Arora, A. Cotter, and N. Srebro, “Stochastic optimization of pca with capped msg,” in Adv. Neural Info. Proc. Sys. (NIPS), 2013, pp. 1815–1823. [7] O. Shamir, “A stochastic pca and svd algorithm with an exponential convergence rate,” arXiv:1409.2848, 2014. [8] C. Boutsidis, D. Garber, Z. Karnin, and E. Liberty, “Online principal components analysis,” in Proc. ACM-SIAM Symposium on Discrete Algorithms (SODA), 2015, pp. 887–901. [9] A. Balsubramani, S. Dasgupta, and Y. Freund, “The fast convergence of incremental pca,” in Adv. Neural Info. Proc. Sys. (NIPS), 2013, pp. 3174–3182. [10] Z. Karnin and E. Liberty, “Online pca with spectral bounds,” in Proce. Conference on Computational Learning Theory (COLT), 2015, pp. 505–509. [11] I. Mitliagkas, C. Caramanis, and P. Jain, “Memory limited, streaming pca,” in Adv. Neural Info. Proc. Sys. (NIPS), 2013, pp. 2886–2894. [12] M. Fazel, “Matrix rank minimization with applications,” PhD thesis, Stanford Univ, 2002. [13] E. J. Candes and B. Recht, “Exact matrix completion via convex optimization,” Found. of Comput. Math, , no. 9, pp. 717–772, 2008. [14] E. J. Cand`es, X. Li, Y. Ma, and J. Wright, “Robust principal component analysis?,” Journal of ACM, vol. 58, no. 3, 2011. [15] V. Chandrasekaran, S. Sanghavi, P. A. Parrilo, and A. S. Willsky, “Rank-sparsity incoherence for matrix decomposition,” SIAM Journal on Optimization, vol. 21, 2011. [16] D. Hsu, S.M. Kakade, and T. Zhang, “Robust matrix decomposition with sparse corruptions,” IEEE Trans. Info. Th., Nov. 2011. [17] P. Netrapalli, U N Niranjan, S. Sanghavi, A. Anandkumar, and P. Jain, “Non-convex robust pca,” in Neural Info. Proc. Sys. (NIPS), 2014. [18] Jussi Gillberg, Pekka Marttinen, Matti Pirinen, Antti J Kangas, Pasi Soininen, Mehreen Ali, Aki S Havulinna, Marjo-Riitta Marjo-Riitta J¨arvelin, Mika Ala-Korpela, and Samuel Kaski, “Multiple output regression with latent noise,” Journal of Machine Learning Research, 2016. [19] C. Davis and W. M. Kahan, “The rotation of eigenvectors by a perturbation. iii,” SIAM J. Numer. Anal., vol. 7, pp. 1–46, Mar. 1970. [20] J. A. Tropp, “User-friendly tail bounds for sums of random matrices,” Found. Comput. Math., vol. 12, no. 4, 2012. [21] R. Vershynin, “Introduction to the non-asymptotic analysis of random matrices,” Compressed sensing, pp. 210–268, 2012. [22] G. H. Golub and H. A. Van der Vorst, “Eigenvalue computation in the 20th century,” Journal of Computational and Applied Mathematics, vol. 123, no. 1, pp. 35–65, 2000. [23] P. Netrapalli, P. Jain, and S. Sanghavi, “Low-rank matrix completion using alternating minimization,” in Symposium on Theory of Computing (STOC), 2013. [24] Z. Lin, M. Chen, and Y. Ma, “Alternating direction algorithms for l1 problems in compressive sensing,” Tech. Rep., University of Illinois at Urbana-Champaign, November 2009. [25] N. Vaswani, “PCA in Data-Dependent Noise (Correlated-PCA): Improved Finite Sample Guarantees,” to be posted on arXiV, 2017. 9 | 2016 | 530 |
6,473 | On Explore-Then-Commit Strategies Aurélien Garivier∗ Institut de Mathématiques de Toulouse; UMR5219 Université de Toulouse; CNRS UPS IMT, F-31062 Toulouse Cedex 9, France aurelien.garivier@math.univ-toulouse.fr Emilie Kaufmann Univ. Lille, CNRS, Centrale Lille, Inria SequeL UMR 9189, CRIStAL - Centre de Recherche en Informatique Signal et Automatique de Lille F-59000 Lille, France emilie.kaufmann@univ-lille1.fr Tor Lattimore University of Alberta 116 St & 85 Ave, Edmonton, AB T6G 2R3, Canada tor.lattimore@gmail.com Abstract We study the problem of minimising regret in two-armed bandit problems with Gaussian rewards. Our objective is to use this simple setting to illustrate that strategies based on an exploration phase (up to a stopping time) followed by exploitation are necessarily suboptimal. The results hold regardless of whether or not the difference in means between the two arms is known. Besides the main message, we also refine existing deviation inequalities, which allow us to design fully sequential strategies with finite-time regret guarantees that are (a) asymptotically optimal as the horizon grows and (b) order-optimal in the minimax sense. Furthermore we provide empirical evidence that the theory also holds in practice and discuss extensions to non-gaussian and multiple-armed case. 1 Introduction It is now a very frequent issue for companies to optimise their daily profits by choosing between one of two possible website layouts. A natural approach is to start with a period of A/B Testing (exploration) during which the two versions are uniformly presented to users. Once the testing is complete, the company displays the version believed to generate the most profit for the rest of the month (exploitation). The time spent exploring may be chosen adaptively based on past observations, but could also be fixed in advance. Our contribution is to show that strategies of this form are much worse than if the company is allowed to dynamically select which website to display without restrictions for the whole month. Our analysis focusses on a simple sequential decision problem played over T time-steps. In time-step t ∈1, 2, . . . , T the agent chooses an action At ∈{1, 2} and receives a normally distributed reward ∗This work was partially supported by the CIMI (Centre International de Mathématiques et d’Informatique) Excellence program while Emilie Kaufmann visited Toulouse in November 2015. The authors acknowledge the support of the French Agence Nationale de la Recherche (ANR), under grants ANR-13-BS01-0005 (project SPADRO) and ANR-13-CORD-0020 (project ALICIA). 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. Zt ∼N(µAt, 1) where µ1, µ2 ∈R are the unknown mean rewards for actions 1 and 2 respectively. The goal is to find a strategy π (a way of choosing each action At based on past observation) that maximises the cumulative reward over T steps in expectation, or equivalently minimises the regret Rπ µ(T) = T max {µ1, µ2} −Eµ " T X t=1 µAt # . (1) This framework is known as the multi-armed bandit problem, which has many applications and has been studied for almost a century [Thompson, 1933]. Although this setting is now quite well understood, the purpose of this article is to show that strategies based on distinct phases of exploration and exploitation are necessarily suboptimal. This is an important message because exploration followed by exploitation is the most natural approach and is often implemented in applications (including the website optimisation problem described above). Moreover, strategies of this kind have been proposed in the literature for more complicated settings [Auer and Ortner, 2010, Perchet and Rigollet, 2013, Perchet et al., 2015]. Recent progress on optimal exploration policies (e.g., by Garivier and Kaufmann [2016]) could have suggested that well-tuned variants of two-phase strategies might be near-optimal. We show, on the contrary, that optimal strategies for multi-armed bandit problems must be fully-sequential, and in particular should mix exploration and exploitation. It is known since the work of Wald [1945] on simple hypothese testing that sequential procedures can lead to significant gains. Here, the superiority of fully sequential procedures is consistent with intuition: if one arm first appears to be better, but if subsequent observations are disappointing, the obligation to commit at some point can be restrictive. In this paper, we give a crisp and precise description of how restrictive it is: it leads to regret asympotically twice as large on average. The proof of this result combines some classical techniques of sequential analysis and of the bandit literature. We study two settings, one when the gap ∆= |µ1 −µ2| is known and the other when it is not. The most straight-forward strategy in the former case is to explore each action a fixed number of times n and subsequently exploit by choosing the action that appeared best while exploring. It is easy to calculate the optimal n and consequently show that this strategy suffers a regret of Rπ µ(T) ∼4 log(T)/∆. A more general approach is to use a so-called Explore-Then-Commit (ETC) strategy, following a nomenclature introduced by Perchet et al. [2015]. An ETC strategy explores each action alternately until some data-dependent stopping time and subsequently commits to a single action for the remaining time-steps. We show in Theorem 2 that by using a sequential probability ratio test (SPRT) it is possible to design an ETC strategy for which Rπ µ(T) ∼log(T)/∆, which improves on the above result by a factor of 4. We also prove a lower bound showing that no ETC strategy can improve on this result. Surprisingly it is possible to do even better by using a fully sequential strategy inspired by the UCB algorithm for multi-armed bandits [Katehakis and Robbins, 1995]. We design a new strategy for which Rπ µ(T) ∼log(T)/(2∆), which improves on the fixed-design strategy by a factor of 8 and on SPRT by a factor of 2. Again we prove a lower bound showing that no strategy can improve on this result. For the case where ∆is unknown, fixed-design strategies are hopeless because there is no reasonable tuning for the exploration budget n. However, it is possible to design an ETC strategy for unknown gaps. Our approach uses a modified fixed-budget best arm identification (BAI) algorithm in its exploration phase (see e.g., Even-Dar et al. [2006], Garivier and Kaufmann [2016]) and chooses the recommended arm for the remaining time-steps. In Theorem 5 we show that a strategy based on this idea satisfies Rπ µ(T) ∼4 log(T)/∆, which again we show is optimal within the class of ETC strategies. As before, strategies based on ETC are suboptimal by a factor of 2 relative to the optimal rates achieved by fully sequential strategies such as UCB, which satisfies Rπ µ(T) ∼2 log(T)/∆ [Katehakis and Robbins, 1995]. In a nutshell, strategies based on fixed-design or ETC are necessarily suboptimal. That this failure occurs even in the simple setting considered here is a strong indicator that they are suboptimal in more complicated settings. Our main contribution, presented in more details in Section 2, is to fully characterise the achievable asymptotic regret when ∆is either known or unknown and the strategies are either fixed-design, ETC or fully sequential. All upper bounds have explicit finite-time forms, which allow us to derive optimal minimax guarantees. For the lower bounds we give a novel and generic proof of all results. All proofs contain new, original ideas that we believe are fundamental to the understanding of sequential analysis. 2 2 Notation and Summary of Results We assume that the horizon T is known to the agent. The optimal action is a∗= arg max(µ1, µ2), its mean reward is µ∗= µa∗, and the gap between the means is ∆= |µ1 −µ2|. Let H = R2 be the set of all possible pairs of means, and H∆= µ ∈R2 : |µ1 −µ2| = ∆ . For i ∈{1, 2} and n ∈N let ˆµi,n be the empirical mean of the ith action based on the first n samples. Let At be the action chosen in time-step t and Ni(t) = Pt s=1 1 {As = i} be the number of times the ith action has been chosen after time-step t. We denote by ˆµi(t) = ˆµi,Ni(t) the empirical mean of the ith arm after time-step t. A strategy is denoted by π, which is a function from past actions/rewards to a distribution over the next actions. An ETC strategy is governed by a sampling rule (which determines which arm to sample at each step), a stopping rule (which specifies when to stop the exploration phase) and a decision rule indicating which arm is chosen in the exploitation phase. As we consider two-armed, Gaussian bandits with equal variances, we focus here on uniform sampling rules, which have been shown in Kaufmann et al. [2014] to be optimal in that setting. For this reason, we define an ETC strategy as a pair (τ, ˆa), where τ is an even stopping time with respect to the filtration (Ft = σ(Z1, . . . , Zt))t and ˆa ∈{1, 2} is Fτ-measurable. In all the ETC strategies presented in this paper, the stopping time τ depends on the horizon T (although this is not reflected in the notation). At time t, the action picked by the ETC strategy is At = 1 if t ≤τ and t is odd , 2 if t ≤τ and t is even , ˆa otherwise . The regret for strategy π, given in Eq. (1), depends on T and µ. Assuming, for example that µ1 = µ2 + ∆, then an ETC strategy π chooses the suboptimal arm N2(T) = τ∧T 2 + (T −τ)+1 {ˆa = 2} times, and the regret Rπ µ(T) = ∆Eµ[N2(T)] thus satisfies ∆Eµ[(τ ∧T)/2] ≤Rπ µ(T) ≤(∆/2)Eµ[τ ∧T] + ∆T Pµ(τ ≤T, ˆa ̸= a∗) . (2) We denote the set of all ETC strategies by ΠETC. A fixed-design strategy is and ETC strategy for which there exists an integer n such that τ = 2n almost surely, and the set of all such strategies is denoted by ΠDETC. The set of all strategies is denoted by ΠALL. For S ∈{H, H∆}, we are interested in strategies π that are uniformly efficient on S, in the sense that ∀µ ∈S, ∀α > 0, Rπ µ(T) = o(T α). (3) ΠALL ΠETC ΠDETC H 2 4 NA H∆ 1/2 1 4 We show in this paper that any uniformly efficient strategy in Π has a regret at least equal to CΠ S log(T)/|µ1 −µ2|(1 −oT (1)) for every parameter µ ∈S, where CΠ S is given in the adjacent table. Furthermore, we prove that these results are tight. In each case, we propose a uniformly efficient strategy matching this bound. In addition, we prove a tight and non-asymptotic regret bound which also implies, in particular, minimax rate-optimality. The paper is organised as follows. First we consider ETC and fixed-design strategies when ∆known and unknown (Section 3). We then analyse fully sequential strategies that interleave exploration and exploitation in an optimal way (Section 4). For known ∆we present a novel algorithm that exploits the additional information to improve the regret. For unknown ∆we briefly recall the well-known results, but also propose a new regret analysis of the UCB* algorithm, a variant of UCB that can be traced back to Lai [1987], for which we also obtain order-optimal minimax regret. Numerical experiments illustrate and empirically support our results in Section 5. We conclude with a short discussion on non-uniform exploration, and on models with more than 2 arms, possibly non Gaussian. All the proofs are given in the supplementary material. In particular, our simple, unified proof for all the lower bounds is given in Appendix A. 3 Explore-Then-Commit Strategies Fixed Design Strategies for Known Gaps. As a warm-up we start with the fixed-design ETC setting where ∆is known and where the agent chooses each action n times before committing for the remainder. 3 input: T and ∆ n := l 2W T 2∆4/(32π) /∆2m for k ∈{1, . . . , n} do choose A2k−1 = 1 and A2k = 2 end for ˆa := arg maxi ˆµi,n for t ∈{2n + 1, . . . , T} do choose At = ˆa end for Algorithm 1: FB-ETC algorithm The optimal decision rule is obviously ˆa = arg maxi ˆµi,n with ties broken arbitrarily. The formal description of the strategy is given in Algorithm 1, where W denotes the Lambert function implicitly defined for y > 0 by W(y) exp(W(y)) = y. We denote the regret associated to the choice of n by Rn µ(T). The following theorem is not especially remarkable except that the bound is sufficiently refined to show certain negative lower-order terms that would otherwise not be apparent. Theorem 1. Let µ ∈H∆, and let n = 2 ∆2 W T 2∆4 32π . Then Rn µ(T) ≤4 ∆log T∆2 4.46 −2 ∆log log T∆2 4 √ 2π + ∆ whenever T∆2 > 4 √ 2πe, and Rn µ(T) ≤T∆/2+∆otherwise. In all cases, Rn µ(T) ≤2.04 √ T +∆. Furthermore, for all ε > 0, T ≥1 and n ≤4(1 −ε) log(T)/∆2, Rn µ(T) ≥ 1 − 2 n∆2 1 −8 log(T) ∆2T ∆T ε 2 p π log(T) . As Rn µ(T) ≥n∆, this entails that inf 1≤n≤T Rn µ(T) ∼4 log(T)/∆. The proof of Theorem 1 is in Appendix B. Note that the "asymptotic lower bound" 4 log(T)/∆is actually not a lower bound, even up to an additive constant: Rn µ(T) −4 log(T)/∆→−∞when T →∞. Actually, the same phenomenon applies many other cases, and it should be no surprise that, in numerical experiments, some algorithm reach a regret smaller than Lai and Robbins asymptotic lower bound, as was already observed in several articles (see e.g. Garivier et al. [2016]). Also note that the term ∆at the end of the upper bound is necessary: if ∆is large, the problem is statistically so simple that one single observation is sufficient to identify the best arm; but that observation cannot be avoided. Explore-Then-Commit Strategies for Known Gaps. We now show the existence of ETC strategies that improve on the optimal fixed-design strategy. Surprisingly, the gain is significant. We describe an algorithm inspired by ideas from hypothesis testing and prove an upper bound on its regret that is minimax optimal and that asymptotically matches our lower bound. Let P be the law of X −Y , where X (resp. Y ) is a reward from arm 1 (resp. arm 2). As ∆is known, the exploration phase of an ETC algorithm can be viewed as a statistical test of the hypothesis H1 : (P = N(∆, 2)) against H2 : (P = N(−∆, 2)). The work of Wald [1945] shows that a significant gain in terms of expected number of samples can be obtained by using a sequential rather than a batch test. Indeed, for a batch test, a sample size of n ∼(4/∆2) log(1/δ) is necessary to guarantee that both type I and type II errors are upper bounded by δ. In contrast, when a random number of samples is permitted, there exists a sequential probability ratio test (SPRT) with the same guarantees that stops after a random number N of samples with expectation E[N] ∼log(1/δ)/∆2 under both H1 and H2. The SPRT stops when the absolute value of the log-likelihood ratio between H1 and H2 exceeds some threshold. Asymptotic upper bound on the expected number of samples used by a SPRT, as well as the (asymptotic) optimality of such procedures among the class of all sequential tests can be found in [Wald, 1945, Siegmund, 1985]. input: T and ∆ A1 = 1, A2 = 2, t := 2 while (t/2)∆|ˆµ1(t) −ˆµ2(t)| < log T∆2 do choose At+1 = 1 and At+2 = 2, t := t + 2 end while ˆa := arg maxi ˆµi(t) while t ≤T do choose At = ˆa, t := t + 1 end while Algorithm 2: SPRT ETC algorithm Algorithm 2 is an ETC strategy that explores each action alternately, halting when sufficient confidence is reached according to a SPRT. The threshold depends on the gap ∆and the horizon T corresponding to a risk of δ = 1/(T∆2). The exploration phase ends at the stopping time τ = inf n t = 2n : ˆµ1,n−ˆµ2,n ≥log(T∆2) n∆ o . If τ < T then the empirical best arm ˆa at time τ is played until time T. If T∆2 ≤1, then τ = 1 4 (one could even define τ = 0 and pick a random arm). The following theorem gives a non-asymptotic upper bound on the regret of the algorithm. The results rely on non-asymptotic upper bounds on the expectation of τ, which are interesting in their own right. Theorem 2. If T∆2 ≥1, then the regret of the SPRT-ETC algorithm is upper-bounded as RSPRT-ETC µ (T) ≤log(eT∆2) ∆ + 4 p log(T∆2) + 4 ∆ + ∆. Otherwise it is upper bounded by T∆/2+∆, and for all T and ∆the regret is less than 10 p T/e+∆. The proof of Theorem 2 is given in Appendix C. The following lower bound shows that no uniformly efficient ETC strategy can improve on the asymptotic regret of Algorithm 2. The proof is given in Section A together with the other lower bounds. Theorem 3. Let π be an ETC strategy that is uniformly efficient on H∆. Then for all µ ∈H∆, lim inf T →∞ Rπ µ(T) log(T) ≥1 ∆. Explore-Then-Commit Strategies for Unknown Gaps. When the gap is unknown it is not possible to tune a fixed-design strategy that achieves logarithmic regret. ETC strategies can enjoy logarithmic regret and these are now analysed. We start with the asymptotic lower bound. Theorem 4. Let π be a uniformly efficient ETC strategy on H. For all µ ∈H, if ∆= |µ1 −µ2| then lim inf T →∞ Rπ µ(T) log(T) ≥4 ∆. A simple idea for constructing an algorithm that matches the lower bound is to use a (fixed-confidence) best arm identification algorithm for the exploration phase. Given a risk parameter δ, a δ-PAC BAI algorithm consists of a sampling rule (At), a stopping rule τ and a recommendation rule ˆa which is Fτ measurable and satisfies, for all µ ∈H such that µ1 ̸= µ2, Pµ(ˆa = a∗) ≥1 −δ. In a bandit model with two Gaussian arms, Kaufmann et al. [2014] propose a δ-PAC algorithm using a uniform sampling rule and a stopping rule τδ that asymptotically attains the minimal sample complexity Eµ[τδ] ∼(8/∆2) log(1/δ). Using the regret decomposition (2), it is easy to show that the ETC algorithm using the stopping rule τδ for δ = 1/T matches the lower bound of Theorem 4. input: T(≥3) A1 = 1, A2 = 2, t := 2 while |ˆµ1(t) −ˆµ2(t)| < q 8 log(T/t) t do choose At+1 = 1 and At+2 = 2 t := t + 2 end while ˆa := arg maxi ˆµi(t) while t ≤T do choose At = ˆa t := t + 1 end while Algorithm 3: BAI-ETC algorithm Algorithm 3 is a slight variant of this optimal BAI algorithm, based on the stopping time τ = inf t = 2n : |ˆµ1,n −ˆµ2,n|> s 4 log T/(2n) n . The motivation for the difference (which comes from a more carefully tuned threshold featuring log(T/2n) in place of log(T)) is that the confidence level should depend on the unknown gap ∆, which determines the regret when a mis-identification occurs. The improvement only appears in the non-asymptotic regime where we are able to prove both asymptotic optimality and order-optimal minimax regret. The latter would not be possible using a fixed-confidence BAI strategy. The proof of this result can be found in Appendix D. The main difficulty is developing a sufficiently strong deviation bound, which we do in Appendix G, and that may be of independent interest. Note that a similar strategy was proposed and analysed by Lai et al. [1983], but in the continuous time framework and with asymptotic analysis only. Theorem 5. If T∆2 > 4e2, the regret of the BAI-ETC algorithm is upper bounded as RBAI-ETC µ (T) ≤ 4 log T ∆2 4 ∆ + 334 q log T ∆2 4 ∆ + 178 ∆+ 2∆. It is upper bounded by T∆otherwise, and by 32 √ T + 2∆in any case. 5 4 Fully Sequential Strategies for Known and Unknown Gaps In the previous section we saw that allowing a random stopping time leads to a factor of 4 improvement in terms of the asymptotic regret relative to the naive fixed-design strategy. We now turn our attention to fully sequential strategies when ∆is known and unknown. The latter case is the classic 2-armed bandit problem and is now quite well understood. Our modest contribution in that case is the first algorithm that is simultaneously asymptotically optimal and order optimal in the minimax sense. For the former case, we are not aware of any previous research where the gap is known except the line of work by Bubeck et al. [2013], Bubeck and Liu [2013], where different questions are treated. In both cases we see that fully sequential strategies improve on the best ETC strategies by a factor of 2. Known Gaps. We start by stating the lower bound (proved in Section A), which is a straightforward generalisation of Lai and Robbins’ lower bound. Theorem 6. Let π be a strategy that is uniformly efficient on H∆. Then for all µ ∈H∆, lim inf T →∞ Rπ µ(T) log T ≥ 1 2∆ We are not aware of any existing algorithm matching this lower bound, which motivates us to introduce a new strategy called ∆-UCB that exploits the knowledge of ∆to improve the performance of UCB. In each round the algorithm chooses the arm that has been played most often so far unless the other arm has an upper confidence bound that is close to ∆larger than the empirical estimate of the most played arm. Like ETC strategies, ∆-UCB is not anytime in the sense that it requires the knowledge of both the horizon T and the gap ∆. 1: input: T and ∆ 2: εT = ∆log−1 8 (e + T∆2)/4 3: for t ∈{1, . . . , T} do 4: let At,min := arg min i∈1,2 Ni(t −1) and At,max = 3 −At,min 5: if ˆµAt,min(t −1) + v u u t2 log T NAt,min(t−1) NAt,min(t −1) ≥ˆµAt,max(t −1) + ∆−2εT then 6: choose At = At,min 7: else 8: choose At = At,max 9: end if 10: end for Algorithm 4: ∆-UCB Theorem 7. If T(2∆−3εT )2 ≥2 and Tε2 T ≥e2, the regret of the ∆-UCB algorithm is upper bounded as R∆-UCB µ (T) ≤ log 2T∆2 2∆(1 −3εT /(2∆))2 + p π log (2T∆2) 2∆(1 −3εT /∆)2 + ∆ " 30e p log(ε2 T T) ε2 T + 80 ε2 T + 2 (2∆−3εT )2 # + 5∆. Moreover lim supT →∞R∆-UCB µ (T)/ log(T) ≤(2∆)−1 and ∀µ ∈H∆, R∆-UCB µ (T) ≤328 √ T + 5∆. The proof may be found in Appendix E. Unknown Gaps. In the classical bandit setting where ∆is unknown, UCB by Katehakis and Robbins [1995] is known to be asymptotically optimal: RUCB µ (T) ∼2 log(T)/∆, which matches the lower bound of Lai and Robbins [1985]. Non-asymptotic regret bounds are given for example by Auer et al. [2002], Cappé et al. [2013]. Unfortunately, UCB is not optimal in the minimax sense, which is so far only achieved by algorithms that are not asymptotically optimal [Audibert and Bubeck, 2009, Lattimore, 2015]. Here, with only two arms, we are able to show that Algorithm 5 below is 6 simultaneously minimax order-optimal and asymptotically optimal. The strategy is essentially the same as suggested by Lai [1987], but with a fractionally smaller confidence bound. The proof of Theorem 8 is given in Appendix F. Empirically the smaller confidence bonus used by UCB∗leads to a significant improvement relative to UCB. 1: input: T 2: for t ∈{1, . . . , T} do 3: At = arg max i∈{1,2} ˆµi(t −1) + s 2 Ni(t −1) log T Ni(t −1) 4: end for Algorithm 5: UCB∗ Theorem 8. For all ε ∈(0, ∆), if T(∆−ε)2 ≥2 and Tε2 ≥e2, the regret of the UCB∗strategy is upper bounded as RUCB∗ µ (T) ≤ 2 log T ∆2 2 ∆ 1 −ε ∆ 2 + 2 q π log T ∆2 2 ∆ 1 −ε ∆ 2 + ∆ 30e p log(ε2T) + 16e ε2 ! + 2 ∆ 1 −ε ∆ 2 + ∆. Moreover, lim supT →∞Rπ µ(T)/ log(T) = 2/∆and for all µ ∈H, Rπ µ(T) ≤33 √ T + ∆. Note that if there are K > 2 arms, then the strategy above is still asymptotically optimal, but suffers a minimax regret of Ω( p TK log(K)), which is a factor of p log(K) suboptimal. 5 Numerical Experiments We represent here the regret of the five strategies presented in this article on a bandit problem with ∆= 1/5, for different values of the horizon. The regret is estimated by 4.105 Monte-Carlo replications. In the legend, the estimated slopes of ∆Rπ(T) (in logarithmic scale) are indicated after the policy names. 50 100 200 500 1000 2000 5000 10000 20000 50000 0 20 40 60 80 100 FB−ETC : 3.65 BAI−ETC : 2.98 UCB : 1.59 SPRT−ETC : 1.03 D−UCB : 0.77 The experimental behavior of the algorithms reflects the theoretical results presented above: the regret asymptotically grows as the logarithm of the horizon, the experimental coefficients correspond approximately to theory, and the relative ordering of the policies is respected. However, it should be noted that for short horizons the hierarchy is not quite the same, and the growth rate is not logarithmic; this question is raised in Garivier et al. [2016]. In particular, on short horizons the Best-Arm Identification procedure performs very well with respect to the others, and starts to be beaten (even by the gap-aware strategies) only when T∆2 is much larger that 10. 7 6 Conclusion: Beyond Uniform Exploration, Two Arms and Gaussian distributions It is worth emphasising the impossibility of non-trivial lower bounds on the regret of ETC strategies using any possible (non-uniform) sampling rule. Indeed, using UCB as a sampling rule together with an a.s. infinite stopping rule defines an artificial but formally valid ETC strategy that achieves the best possible rate for general strategies. This strategy is not a faithful counter-example to our claim that ETC strategies are sub-optimal, because UCB is not a satisfying exploration rule. If exploration is the objective, then uniform sampling is known to be optimal in the two-armed Gaussian case [Kaufmann et al., 2014], which justifies the uniform sampling assumption. The use of ETC strategies for regret minimisation (e.g., as presented by Perchet and Rigollet [2013]) is certainly not limited to bandit models with 2 arms. The extension to multiple arms is based on the successive elimination idea in which a set of active arms is maintained with arms chosen according to a round robin within the active set. Arms are eliminated from the active set once their optimality becomes implausible and the exploration phase terminates when the active set contains only a single arm (an example is by Auer and Ortner [2010]). The Successive Elimination algorithm has been introduced by Even-Dar et al. [2006] for best-arm identification in the fixed-confidence setting. It was shown to be rate-optimal, and thus a good compromise for both minimizing regret and finding the best arm. If one looks more precisely at mutliplicative constants, however, Garivier and Kaufmann [2016] showed that it is suboptimal for the best arm identification task in almost all settings except two-armed Gaussian bandits. Regarding regret minimization, the present paper shows that it is sub-optimal by a factor 2 on every two-armed Gaussian problem. It is therefore interesting to investigate the performance in terms of regret of an ETC algorithm using an optimal BAI algorithm. This is actually possible not only for Gaussian distributions, but more generally for one-parameter exponential families, for which Garivier and Kaufmann [2016] propose the asymptotically optimal Track-and-Stop strategy. Denoting d(µ, µ′) = KL(νµ, νµ′) the Kullback-Leibler divergence between two distributions parameterised by µ and µ′, they provide results which can be adapted to obtain the following bound. Proposition 1. For µ such that µ1 > maxa̸=1 µa, the regret of the ETC strategy using Track-and-Stop exploration with risk 1/T satisfies lim sup T →∞ RTaS µ (T) log T ≤T ∗(µ) K X a=2 w∗ a(µ)(µ1 −µa) ! , where T ∗(µ) (resp. w∗(µ)) is the the maximum (resp. maximiser) of the optimisation problem max w∈ΣK inf a̸=1 w1d µ1, w1µ1 + waµa w1 + wa + wad µa, waµ1 + waµa w1 + wa , where ΣK is the set of probability distributions on {1, . . . , K}. In general, it is not easy to quantify the difference to the lower bound of Lai and Robbins lim inf T →∞ Rπ µ(T) log T ≥ K X a=2 µ1 −µa d(µa, µ1). Even for Gaussian distributions, there is no general closed-form formula for T ∗(µ) and w∗(µ) except when K = 2. However, we conjecture that the worst case is when µ1 and µ2 are much larger than the other means: then, the regret is almost the same as in the 2-arm case, and ETC strategies are suboptimal by a factor 2. On the other hand, the most favourable case (in terms of relative efficiency) seems to be when µ2 = · · · = µK: then w∗ 1(µ) = √ K −1 K −1 + √ K −1, w∗ 2(µ) = · · · = w∗ K(µ) = 1 K −1 + √ K −1 and T ∗= 2( √ K −1 + 1)2/∆2, leading to lim sup T →∞ RTaS µ (T) log(T) ≤ 1 + 1 √ K −1 2(K −1) ∆ , while Lai and Robbins’ lower bound yields 2(K −1)/∆. Thus, the difference grows with K as 2 √ K −1 log(T)/∆, but the relative difference decreases. 8 References Jean-Yves Audibert and Sébastien Bubeck. Minimax policies for adversarial and stochastic bandits. In Proceedings of Conference on Learning Theory (COLT), pages 217–226, 2009. Peter Auer and Ronald Ortner. UCB revisited: Improved regret bounds for the stochastic multi-armed bandit problem. Periodica Mathematica Hungarica, 61(1-2):55–65, 2010. Peter Auer, Nicoló Cesa-Bianchi, and Paul Fischer. Finite-time analysis of the multiarmed bandit problem. Machine Learning, 47:235–256, 2002. Sébastien Bubeck and Che-Yu Liu. Prior-free and prior-dependent regret bounds for thompson sampling. In Advances in Neural Information Processing Systems, pages 638–646, 2013. Sébastien Bubeck, Vianney Perchet, and Philippe Rigollet. Bounded regret in stochastic multi-armed bandits. In Proceedings of the 26th Conference On Learning Theory, pages 122–134, 2013. Olivier Cappé, Aurélien Garivier, Odalric-Ambrym Maillard, Rémi Munos, and Gilles Stoltz. Kullback–Leibler upper confidence bounds for optimal sequential allocation. The Annals of Statistics, 41(3):1516–1541, 2013. Eyal Even-Dar, Shie Mannor, and Yishay Mansour. Action Elimination and Stopping Conditions for the Multi-Armed Bandit and Reinforcement Learning Problems. Journal of Machine Learning Research, 7:1079–1105, 2006. Aurélien Garivier and Emilie Kaufmann. Optimal best arm identification with fixed confidence. In Proceedings of the 29th Conference On Learning Theory (to appear), 2016. Aurélien Garivier, Pierre Ménard, and Gilles Stoltz. Explore first, exploit next: The true shape of regret in bandit problems. arXiv preprint arXiv:1602.07182, 2016. Abdolhossein Hoorfar and Mehdi Hassani. Inequalities on the lambert w function and hyperpower function. J. Inequal. Pure and Appl. Math, 9(2):5–9, 2008. Michael N Katehakis and Herbert Robbins. Sequential choice from several populations. Proceedings of the National Academy of Sciences of the United States of America, 92(19):8584, 1995. Emilie Kaufmann, Olivier Cappé, and Aurélien Garivier. On the Complexity of A/B Testing. In Proceedings of the 27th Conference On Learning Theory, 2014. Tze Leung Lai. Adaptive treatment allocation and the multi-armed bandit problem. The Annals of Statistics, pages 1091–1114, 1987. Tze Leung Lai and Herbert Robbins. Asymptotically efficient adaptive allocation rules. Advances in applied mathematics, 6(1):4–22, 1985. Tze Leung Lai, Herbert Robbins, and David Siegmund. Sequential design of comparative clinical trials. In M. Haseeb Rizvi, Jagdish Rustagi, and David Siegmund, editors, Recent advances in statistics: papers in honor of Herman Chernoff on his sixtieth birthday, pages 51–68. Academic Press, 1983. Tor Lattimore. Optimally confident UCB: Improved regret for finite-armed bandits. Technical report, 2015. URL http://arxiv.org/abs/1507.07880. Peter Mörters and Yuval Peres. Brownian motion, volume 30. Cambridge University Press, 2010. Vianney Perchet and Philippe Rigollet. The multi-armed bandit with covariates. The Annals of Statistics, 2013. Vianney Perchet, Philippe Rigollet, Sylvain Chassang, and Eric Snowberg. Batched bandit problems. In Proceedings of the 28th Conference On Learning Theory, 2015. David Siegmund. Sequential Analysis. Springer-Verlag, 1985. William Thompson. On the likelihood that one unknown probability exceeds another in view of the evidence of two samples. Biometrika, 25(3/4):285–294, 1933. Abraham Wald. Sequential Tests of Statistical Hypotheses. Annals of Mathematical Statistics, 16(2): 117–186, 1945. 9 | 2016 | 531 |
6,474 | Adaptive Neural Compilation Rudy Bunel∗ Alban Desmaison∗ University of Oxford University of Oxford rudy@robots.ox.ac.uk alban@robots.ox.ac.uk Pushmeet Kohli Philip H.S. Torr M. Pawan Kumar Microsoft Research University of Oxford University of Oxford pkohli@microsoft.com philip.torr@eng.ox.ac.uk pawan@robots.ox.ac.uk Abstract This paper proposes an adaptive neural-compilation framework to address the problem of learning efficient programs. Traditional code optimisation strategies used in compilers are based on applying pre-specified set of transformations that make the code faster to execute without changing its semantics. In contrast, our work involves adapting programs to make them more efficient while considering correctness only on a target input distribution. Our approach is inspired by the recent works on differentiable representations of programs. We show that it is possible to compile programs written in a low-level language to a differentiable representation. We also show how programs in this representation can be optimised to make them efficient on a target input distribution. Experimental results demonstrate that our approach enables learning specifically-tuned algorithms for given data distributions with a high success rate. 1 Introduction Algorithm design often requires making simplifying assumptions about the input data. Consider, for instance, the computational problem of accessing an element in a linked list. Without the knowledge of the input data distribution, one can only specify an algorithm that runs in a time linear in the number of elements of the list. However, suppose all the linked lists that we encountered in practice were ordered in memory. Then it would be advantageous to design an algorithm specifically for this task as it can lead to a constant running time. Unfortunately, the input data distribution of a real world problem cannot be easily specified as in the above simple example. The best that one can hope for is to obtain samples drawn from the distribution. A natural question that arises from these observations: “How can we adapt a generic algorithm for a computational task using samples from an unknown input data distribution?” The process of finding the most efficient implementation of an algorithm has received considerable attention in the theoretical computer science and code optimisation community. Recently, Conditionally Correct Superoptimization [14] was proposed as a method for leveraging samples of the input data distribution to go beyond semantically equivalent optimisation and towards data-specific performance improvements. The underlying procedure is based on a stochastic search over the space of all possible programs. Additionally, they restrict their applications to reasonably small, loop-free programs, thereby limiting their impact in practice. In this work, we take inspiration from the recent wave of machine-learning frameworks for estimating programs. Using recurrent models, Graves et al. [2] introduced a fully differentiable representation of a program, enabling the use of gradient-based methods to learn a program from examples. Many other models that have been published recently [3, 5, 6, 8] build and improve on the early work by Graves ∗The first two authors contributed equally. 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. et al. [2]. Unfortunately, these models are usually complex to train and need to rely on methods such as curriculum learning or gradient noise to reach good solutions as shown by Neelakantan et al. [10]. Moreover, their interpretability is limited. The learnt model is too complex for the underlying algorithm to be recovered and transformed into a regular computer program. The main focus of the machine-learning community has thus far been on learning programs from scratch, with little emphasis on running time. However, for nearly all computational problems, it is feasible to design generic algorithms for the worst-case. We argue that a more pragmatic goal for the machine learning community is to design methods for adapting existing programs for specific input data distributions. To this end, we propose the Adaptive Neural Compiler (ANC). We design a compiler capable of mechanically converting algorithms to a differentiable representation, thereby providing adequate initialisation to the difficult problem of optimal program learning. We then present a method to improve this compiled program using data-driven optimisation, alleviating the need to perform a wide search over the set of all possible programs. We show experimentally that this framework is capable of adapting simple generic algorithms to perform better on given datasets. 2 Related Works The idea of compiling programs to neural networks has previously been explored in the literature. Siegelmann [15] described how to build a Neural Network that would perform the same operations as a given program. A compiler has been designed by Gruau et al. [4] targeting an extended version of Pascal. A complete implementation was achieved when Neto et al. [11] wrote a compiler for NETDEF, a language based on the Occam programming language. While these methods allow us to obtain an exact representation of a program as a neural network, they do not lend themselves to optimisation to improve the original program. Indeed, in their formulation, each elementary step of a program is expressed as a group of neurons with a precise topology, set of weights and biases, thereby rendering learning via gradient descent infeasible. Performing gradient descent in this parameter space would result in invalid operations and thus is unlikely to lead to any improvement. The recent work by Reed and de Freitas [12] on Neural Programmer-Interpreters (NPI) can also be seen as a way to compile any program into a neural network. It does so by learning a model that mimics the program. While more flexible than previous approaches, the NPI only learns to reproduce an existing program. Therefore it cannot be used to find a new and possibly better program. Another approach to this learning problem is the one taken by the code optimisation community. By exploring the space of all possible programs, either exhaustively [9] or in a stochastic manner [13], they search for programs having the same results but being more efficient. The work of Sharma et al. [14] broadens the space of acceptable improvements to data-specific optimisations as opposed to the provably equivalent transformations that were previously the only ones considered. However, this method is still reliant on non-gradient-based methods for efficient exploration of the space. By representing everything in a differentiable manner, we aim to obtain gradients to guide the exploration. Recently, Graves et al. [2] introduced a learnable representation of programs, called the Neural Turing Machine (NTM). The NTM uses an LSTM as a Controller, which outputs commands to be executed by a deterministic differentiable Machine. From examples of input/output sequences, they manage to learn a Controller such that the model becomes capable of performing simple algorithmic tasks. Extensions of this model have been proposed in [3, 5] where the memory tape was replaced by differentiable versions of stacks or lists. Kurach et al. [8] modified the NTM to introduce a notion of pointers making it more amenable to represent traditional programs. Parallel works have been using Reinforcement Learning techniques such as the REINFORCE algorithm [1, 16, 17] or Q-learning [18] to be able to work with non differentiable versions of the above mentioned models. All these models are trained only with a loss based on the difference between the output of the model and the expected output. This weak supervision results in learning becoming more difficult. For instance the Neural RAM [8] requires a high number of random restarts before converging to a correct solution [10], even when using the best hyperparameters obtained through a large grid search. In our work, we will first show that we can design a new neural compiler whose target will be a Controller-Machine model. This makes the compiled model amenable to learning from examples. Moreover, we can use it as initialisation for the learning procedure, allowing us to aim for the more complex task of finding an efficient algorithm. 2 Controller Machine Memory Controller Machine Memory R1 IR1 M1 stop stop R0 IR0 ... ... ... R2 IR2 M2 M0 MT (a) General view of the whole Model. Inst arg1 arg2 output side effect STOP 0 stop = 1 ZERO 0 INC a a+1 DEC a a-1 ADD a b a+b SUB a b a-b MIN a b min(a,b) MAX a b max(a,b) READ a mt a Memory access WRITE a b 0 mt a = b JEZ a b 0 IRt = b if a = 0 (b) Machine instructions. Figure 1: Model components. 3 Model Our model is composed of two parts: (i) a Controller, in charge of specifying what should be executed; and (ii) a Machine, following the commands of the Controller. We start by describing the global architecture of the model. For the sake of simplicity, the general description will present a non-differentiable version of the model. Section 3.2 will then explain the modifications required to make this model completely differentiable. A more detailed description of the model is provided in the supplementary material. 3.1 General Model We first define for each timestep t the memory tape that contains M integer values Mt = {mt 1, mt 2, . . . , mt M}, registers that contain R values Rt = {rt 1, rt 2, . . . , rt R} and the instruction register that contains a single value IRt. We also define a set of instructions that can be executed, whose main role is to perform computations using the registers. For example, add the values contained in two registers. We also define as a side effect any action that involves elements other than the input and output values of the instruction. Interaction with the memory is an example of such side effect. All the instructions, their computations and side effects are detailed in Figure 1b. As can be seen in Figure 1a the execution model takes as input an initial memory tape M0 and outputs a final memory tape MT after T steps. At each step t, the Controller uses the instruction register IRt to compute the command for the Machine. The command is a 4-tuple e, a, b, o. The first element e is the instruction that should be executed by the Machine, enumerated as an integer. The elements a and b specify which registers should be used as arguments for the given instruction. The last element o specifies in which register the output of the instruction should be written. For example, the command {ADD, 2, 3, 1} means that only the value of the first register should change, following rt+1 1 = ADD(rt 2, rt 3). Then the Machine will execute this command, updating the values of the memory, the registers and the instruction register. The Machine always performs two other operations apart from the required instruction. It outputs a stop flag that allows the model to decide when to stop the execution. It also increments the instruction register IRt by one at each iteration. 3.2 Differentiability The model presented above is a simple execution machine but it is not differentiable. In order to be able to train this model end-to-end from a loss defined over the final memory tape, we need to make every intermediate operation differentiable. To achieve this, we replace every discrete value in our model by a multinomial distribution over all the possible values that could have been taken. Moreover, each hard choice that would have been non-differentiable is replaced by a continuous soft choice. We will henceforth use bold letters to indicate the probabilistic version of a value. First, the memory tape Mt is replaced by an M × M matrix Mt, where Mt i,j corresponds to the probability of mt i taking the value j. The same change is applied to the registers Rt, replacing them with an R × M matrix Rt, where Rt i,j represents the probability of rt i taking the value j. Finally, the instruction register is also transformed, the same way as the other registers, from a single value IRt to a vector of size M noted IRt, where the i-th element represents its probability to take the value i. 3 The Machine does not contain any learnable parameter and will just execute a given command. To make it differentiable, the Machine now takes as input four probability distributions et, at, bt and ot, where et is a distribution over instructions, and at, bt and ot are distributions over registers. We compute the argument values arg1t and arg2t as convex combinations of delta-function probability distributions of the different registers values: arg1 t = R X i=1 at irt i arg2 t = R X i=1 bt irt i, (1) where at i and bt i are the i-th values of the vectors at and bt. Using these values, we can compute the output value of each instruction k using the following formula: ∀0 ≤c ≤M outt k,c = X 0≤i,j≤M arg1 t i · arg2 t j · 1[gk(i, j) = c mod M], (2) where gk is the function associated to the k-th instruction as presented in Table 1b, outt k,c is the probability for an instruction k to output the value c at the time-step t and arg1t i is the probability of the argument 1 having the value i at the time-step t. Since the executed instruction is controlled by the probability e, the output for all instructions will also be a convex combination: outt = PN k=1 et koutt k, where N is the number of instructions. This value is then stored into the registers by performing a soft-write parametrised by ot: the value stored in the i-th register at time t + 1 is rt+1 i = rt i(1 −ot i) + outtot i, allowing the choice of the output register to be differentiable. A special case is associated with the stop signal. When executing the model, we keep track of the probability that the program should have terminated before this iteration based on the probability associated at each iteration with the specific instruction that controls this flag. Once this probability goes over a threshold ηstop ∈(0, 1], the execution is halted. We applied the same techniques to make the side-effects differentiable, this is presented in the supplementary materials. The Controller is the only learnable part of our model. The first learnable part is the initial values for the registers R0 and for the instruction register IR0. The second learnable part is the parameters of the Controller which computes the required distributions using: et = We ∗IRt, at = Wa ∗IRt, bt = Wb ∗IRt, ot = Wo ∗IRt (3) where We is an N ×M matrix and Wa, Wb and Wo are R×M matrices. A representation of these matrices can be found in Figure 2c. The Controller as defined above is composed of four independent, fully-connected layers. In Section 4.3 we will see that this complexity is sufficient for our model to be able to represent any program. Henceforth, we will denote by θ = {R0, IR0, We, Wa, Wb, Wo} the set of learnable parameters. 4 Adaptative Neural Compiler We will now present the Adaptive Neural Compiler. Its goal is to find the best set of weights θ∗for a given dataset such that our model will perform the correct input/output mapping as efficiently as it can. We begin by describing our learning objective in details. The two subsequent sections will focus on making the optimisation of our learning objective computationally feasible. 4.1 Objective function Our goal is to solve a given algorithmic problem efficiently. The algorithmic problem is defined as a set of input/output pairs. We also have access to a generic program that is able to perform the required mapping. In our example of accessing elements in a linked list, the transformation would consist in writing down the desired value at the specified position in the tape. The program given to us would iteratively go through the elements of the linked list, find the desired value and write it down at the desired position. If there exists some bias that would allow this traversal to be faster, we expect the program to exploit it. Our approach to this problem is to construct a differentiable objective function that maps controller parameters to a loss. We define this loss based on the states of the memory tape and outputs of the Controller at each step of the execution. The precise mathematical formulation for each term of the loss is given in the supplementary materials. Here we present the motivation behind each of them. 4 Correctness We first want the final memory tape to match the expected output for a given input. Halting To prevent programs from taking an infinite amount of time without stopping, we define a maximum number of iterations Tmax after which the execution is halted. Moreover, we add a penalty if the Controller didn’t halt before this limit. Efficiency We penalise each iteration taken by the program where it does not stop. Confidence We finally make sure that if the Controller wants to stop, the current output is correct. If only the correctness term was considered, nothing would encourage the learnt algorithm to halt as soon as it finished. If only correctness and halting were considered, then the program may not halt as early as possible. Confidence enables the algorithm to better evaluate when to stop. The loss is a weighted sum of the four above-mentioned terms. We denote the loss of the i-th training sample, given parameters θ, as Li(θ). Our learning objective is then specified as: min θ X i Li(θ) s.t. θ ∈Θ, (4) where Θ is a set over the parameters such that the outputs of the Controller, the initial values of each register and of the instruction register are all probability distributions. The above optimisation is a highly non-convex problem. In the rest of this section, we will first present a small modification to the model that will remove the constraints to be able to use standard gradient descent-based methods. Moreover, a good initialisation is helpful to solve these non-convex problems. To alleviate this deficiency, we now introduce our Neural Compiler that will provide a good initialisation. 4.2 Reformulation In order to use gradient descent methods without having to project the parameters on Θ, we alter the formulation of the Controller. We use softmax layers to be able to learn learn unormalized scores that are then mapped to probability distributions. We add one after each linear layer of the Controller and for the initial values of the registers. This way, we transform the constrained-optimisation problem into an unconstrained one, allowing us to use standard gradient descent methods. As discussed in other works [10], this kind of model is hard to train and requires a high number of random restarts before converging to a good solution. We will now present a Neural Compiler that will provide good initialisations to help with this problem. 4.3 Neural Compiler The goal for the Neural Compiler is to convert an algorithm, written as an unambiguous program, to a set of parameters. These parameters, when put into the controller, will reproduce the exact steps of the algorithm. This is very similar to the problem framed by Reed and de Freitas [12], but we show here a way to accomplish it without any learning. The different steps of the compilation are illustrated in Figure 2. The first step is to go from the written version of the program to the equivalent list of low level instruction. This step can be seen as going from Figure 2a to Figure 2b. The illustrative example uses a fairly low-level language but traditional features of programming languages such as loops or if-statements can be supported using the JEZ instruction. The use of constants as arguments or as values is handled by introducing new registers that hold these values. The value required to be passed as target position to the JEZ instruction can be resolved at compile time. Having obtained this intermediate representation, generating the parameters is straightforward. As can be seen in Figure 2b, each line contains one instruction, the two input registers and the output register, and corresponds to a command that the Controller will have to output. If we ensure that IR is a Dirac-delta distribution on a given value, then the matrix-vector product is equivalent to selecting a row of the weight matrix. As IR is incremented at each iteration, the Controller outputs the rows of the matrix in order. We thus have a one-to-one mapping between the lines of the intermediate representation and the rows of the weight matrix. An example of these matrices can be found in Figure 2c. The weight matrix has 10 rows, corresponding to the number of lines of code of our intermediate representation. For example, on the first line of the matrix corresponding to the output (2civ), we see that the fifth element has value 1. This is linked to the first line of code where the output of the READ operation is stored into the fifth register. With this representation, we can 5 var head = 0; var nb_jump = 1; var out_write = 2; nb_jump = READ(nb_jump); out_write = READ(out_write); loop : head = READ(head); nb_jump = DEC(nb_jump); JEZ(nb_jump, end); JEZ(0, loop); end : head = INC(head); head = READ(head); WRITE(out_write, head); STOP(); (a) Input program Initial Registers: R1 = 6; R2 = 2; R3 = 0; R4 = 2; R5 = 1; R6 = 0; R7 = 0; Program: 0 : R5 = READ (R5, R7) 1 : R4 = READ (R4, R7) 2 : R6 = READ (R6, R7) 3 : R5 = DEC (R5, R7) 4 : R7 = JEZ (R5, R1) 5 : R3 = JEZ (R3, R2) 6 : R6 = INC (R6, R7) 7 : R6 = READ (R6, R7) 8 : R7 = WRITE(R4, R6) 9 : R7 = STOP (R7, R7) (b) Intermediary representation (i) Instr. (ii) Arg1 (iii) Arg2 (iv) Out (c) Weights Figure 2: Example of the compilation process. (2a) Program written to perform the ListK task. Given a pointer to the head of a linked list, an integer k, a target cell and a linked list, write in the target cell the k-th element of the list. (2b) Intermediary representation of the program. This corresponds to the instruction that a Random Access Machine would need to perform to execute the program. (2c) Representation of the weights that encodes the intermediary representation. Each row of the matrix correspond to one state/line. Initial value of the registers are also parameters of the model, omitted here. note that the number of parameters is linear in the number of lines of code in the original program and that the largest representable number in our Machine needs to be greater than the number of lines in our program. Moreover, any program written in a regular assembly language can be rewritten to use only our restricted set of instructions. This can be done firstly because all the conditionals of the assembly language can be expressed as a combination of arithmetic and JEZ instructions. Secondly because all the arithmetic operations can be represented as a combination of our simple arithmetic operations, loops and ifs statements. This means that any program that can run on a regular computer, can be first rewritten to use our restricted set of instructions and then compiled down to a set of weights for our model. Even though other models use LSTM as controller, we showed here that a Controller composed of simple linear functions is expressive enough. The advantage of this simpler model is that we can now easily interpret the weights of our model in a way that is not possible if we use a recurrent network as a controller. The most straightforward way to leverage the results of the compilation is to initialise the Controller with the weights obtained through compilation of the generic algorithm. To account for the extra softmax layer, we need to multiply the weights produced by the compiler by a large constant to output Dirac-delta distributions. Some results associated with this technique can be found in Section 5.1. However, if we initialise with exactly this sharp set of parameters, the training procedure is not able to move away from the initialisation as the gradients associated with the softmax in this region are very small. Instead, we initialise the controller with a non-ideal version of the generic algorithm. This means that the choice with the highest probability in the output of the Controller is correct, but the probability of other choices is not zero. As can be seen in Section 5.2, this allows the Controller to learn by gradient descent a new algorithm, different from the original one, that has a lower loss than the ideal version of the compiled program. 5 Experiments We performed two sets of experiments. The first shows the capability of the Neural Compiler to perfectly reproduce any given program. The second shows that our Neural Compiler can adapt and improve the performance of programs. We present results of data-specific optimisation being carried out and show decreases in runtime for all the algorithms and additionally, for some algorithms, show that the runtime is a different computational-complexity class altogether. All the code required to reproduce these experiments is available online 1. 1https://github.com/albanD/adaptive-neural-compilation 6 5.1 Compilation The compiler described in section 4.3 allows us to go from a program written using our instruction set to a set of weights Θ for our Controller. To illustrate this point, we implemented simple programs that can solve the tasks introduced by Kurach et al. [8] and a shortest path problem. One of these implementations can be found in Figure 2a, while the others are available in the supplementary materials. These programs are written in a specific language, and are transformed by the Neural Compiler into parameters for the model. As expected, the resulting models solve the original tasks exactly and can generalise to any input sequence. 5.2 ANC experiments In addition to being able to reproduce any given program as was done by Reed and de Freitas [12], we have the possibility of optimising the resulting program further. We exhibit this by compiling program down to our model and optimising their performance. The efficiency gain for these tasks come either from finding simpler, equivalent algorithms or by exploiting some bias in the data to either remove instructions or change the underlying algorithm. We identify three different levels of interpretability for our model: the first type corresponds to weights containing only Dirac-delta distributions, there is an exact one-to-one mapping between lines in the weight matrices and lines of assembly code. In the second type where all probabilities are Dirac-delta except the ones associated with the execution of the JEZ instruction, we can recover an exact algorithm that will use if statements to enumerate the different cases arising from this conditional jump. In the third type where any operation other than JEZ is executed in a soft way or use a soft argument, it is not possible to recover a program that will be as efficient as the learned one. We present here briefly the considered tasks and biases, and report the reader to the supplementary materials for a detailed encoding of the input/output tape. 1. Access: Given a value k and an array A, return A[k]. In the biased version, the value of k is always the same, so the address of the required element can be stored in a constant. This is similar to the optimisation known as constant folding. 2. Swap: Given an array A and two pointers p and q, swap the elements A[p] and A[q]. In the biased version, p and q are always the same so reading them can be avoided. 3. Increment: Given an array, increment all its element by 1. In the biased version, the array is of fixed size and the elements of the array have the same value so you do not need to read all of them when going through the array. 4. Listk: Given a pointer to the head of a linked list, a number k and a linked list, find the value of the k-th element. In the biased version, the linked list is organised in order in memory, as would be an array, so the address of the k-th value can be computed in constant time. This is the example developed in Figure 2. 5. Addition: Two values are written on the tape and should be summed. No data bias is introduced but the starting algorithm is non-efficient: it performs the addition as a series of increment operation. The more efficient operation would be to add the two numbers. 6. Sort: Given an array A, sort it. In the biased version, only the start of the array might be unsorted. Once the start has been arranged, the end of the array can be safely ignored. For each of these tasks, we perform a grid search on the loss parameters and on our hyper-parameters. Training is performed using Adam [7] and success rates are obtained by running the optimisation with 100 different random seeds. We consider that a program has been successfully optimised when two conditions are fulfilled. First, it needs to output the correct solution for all test cases presenting the same bias. Second, the average number of iterations taken to solve a problem must have decreased. Note that if we cared only about the first criterion, the methods presented in Section 5.1 would already provide a success rate of 100%, without requiring any training. The results are presented in Table 1. For each of these tasks, we manage to find faster algorithms. In the simple cases of Access and Swap, the optimal algorithms for the considered bias are obtained. They are found by incorporating heuristics to the algorithm and storing constants in the initial values of the registers. The learned programs for these tasks are always in the first case of interpretability, this means that we can recover the most efficient algorithm from the learned weights. 7 Table 1: Average number of iterations required to solve instances of the problems for the original program, the best learned program and the ideal algorithm for the biased dataset. We also include the success rate of reaching a more efficient algorithm across multiple random restarts. Access Increment Swap ListK Addition Sort Generic 6 40 10 18 20 38 Learned 4 16 6 11 9 18 Ideal 4 34 6 10 6 9.5 Success Rate 37 % 84% 27% 19% 12% 74% While ListK and Addition have lower success rates, improvements between the original and learned algorithms are still significant. Both were initialised with iterative algorithms with O(n) complexities. They managed to find constant time O(1) algorithms to solve the given problems, making the runtime independent of the input. Achieving this means that the equivalence between the two approaches has been identified, similar to how optimising compilers operate. Moreover, on the ListK task, some learned programs corresponds to the second type of interpretability. Indeed these programs use soft jumps to condition the execution on the value of k. Even though these program would not generalise to other values of k, some learned programs for this task achieve a type one interpretability and a study of the learned algorithm reveal that they can generalise to any value of k. Finally, the Increment task achieves an unexpected result. Indeed, it is able to outperform our best possible algorithm. By looking at the learned program, we can see that it is actually leveraging the possibility to perform soft writes over multiple elements of the memory at the same time to reduce its runtime. This is the only case where we see a learned program associated with the third type of interpretability. While our ideal algorithm would give a confidence of 1 on the output, this algorithm is unable to do so, but it has a high enough confidence of 0.9 to be considered a correct algorithm. In practice, for all but the most simple tasks, we observe that further optimisation is possible, as some useless instructions remain present. Some transformations of the controller are indeed difficult to achieve through the local changes operated by the gradient descent algorithm. An analysis of these failure modes of our algorithm can be found in the supplementary materials. This motivates us to envision the use of approaches other than gradient descent to address these issues. 6 Discussion The work presented here is a first step towards adaptive learning of programs. It opens up several interesting directions of future research. For exemple, the definition of efficiency that we considered in this paper is flexible. We chose to only look at the average number of operations executed to generate the output from the input. We leave the study of other potential measures such as Kolmogorov Complexity and sloc, to name a few, for future works. As shown in the experiment section, our current method is very good at finding efficient solutions for simple programs. For more complex programs, only a solution close to the initialisation can be found. Even though training heuristics could help with the tasks considered here, they would likely not scale up to real applications. Indeed, the main problem we identified is that the gradientdescent based optimisation is unable to explore the space of programs effectively, by performing only local transformations. In future work, we want to explore different optimisation methods. One approach would be to mix global and local exploration to improve the quality of the solutions. A more ambitious plan would be to leverage the structure of the problem and use techniques from combinatorial optimisation to try and solve the original discrete problem. Acknowledgments We would like to thank Siddharth Narayanaswamy and Diane Bouchacourt for helpful discussions and proofreading the paper. This work was supported by the EPSRC, Leverhulme Trust, Clarendon Fund and the ERC grant ERC-2012-AdG 321162-HELIOS, EPSRC/MURI grant ref EP/N019474/1, EPSRC grant EP/M013774/1, EPSRC Programme Grant Seebibyte EP/M013774/1 and Microsoft Research PhD Scolarship Program. 8 References [1] Marcin Andrychowicz and Karol Kurach. Learning efficient algorithms with hierarchical attentive memory. CoRR, 2016. [2] Alex Graves, Greg Wayne, and Ivo Danihelka. Neural turing machines. CoRR, 2014. [3] Edward Grefenstette, Karl Moritz Hermann, Mustafa Suleyman, and Phil Blunsom. Learning to transduce with unbounded memory. In NIPS, 2015. [4] Frédéric Gruau, Jean-Yves Ratajszczak, and Gilles Wiber. A neural compiler. Theoretical Computer Science, 1995. [5] Armand Joulin and Tomas Mikolov. Inferring algorithmic patterns with stack-augmented recurrent nets. In NIPS, 2015. [6] Łukasz Kaiser and Ilya Sutskever. Neural gpus learn algorithms. In ICLR, 2016. [7] Diederik Kingma and Jimmy Ba. Adam: A method for stochastic optimization. In ICLR, 2015. [8] Karol Kurach, Marcin Andrychowicz, and Ilya Sutskever. Neural random-access machines. In ICLR, 2016. [9] Henry Massalin. Superoptimizer: a look at the smallest program. In ACM SIGPLAN Notices, volume 22, pages 122–126. IEEE Computer Society Press, 1987. [10] Arvind Neelakantan, Luke Vilnis, Quoc V Le, Ilya Sutskever, Lukasz Kaiser, Karol Kurach, and James Martens. Adding gradient noise improves learning for very deep networks. In ICLR, 2016. [11] João Pedro Neto, Hava Siegelmann, and Félix Costa. Symbolic processing in neural networks. Journal of the Brazilian Computer Society, 2003. [12] Scott Reed and Nando de Freitas. Neural programmer-interpreters. In ICLR, 2016. [13] Eric Schkufza, Rahul Sharma, and Alex Aiken. Stochastic superoptimization. In ACM SIGARCH Computer Architecture News, 2013. [14] Rahul Sharma, Eric Schkufza, Berkeley Churchill, and Alex Aiken. Conditionally correct superoptimization. In OOPSLA, 2015. [15] Hava Siegelmann. Neural programming language. In AAAI, 1994. [16] Ronald Williams. Simple statistical gradient-following algorithms for connectionist reinforcement learning. Machine learning, 1992. [17] Wojciech Zaremba and Ilya Sutskever. Reinforcement learning neural turing machines. arXiv preprint arXiv:1505.00521, 2015. [18] Wojciech Zaremba, Tomas Mikolov, Armand Joulin, and Rob Fergus. Learning simple algorithms from examples. CoRR, 2015. 9 | 2016 | 532 |
6,475 | Graphical Time Warping for Joint Alignment of Multiple Curves Yizhi Wang Virginia Tech yzwang@vt.edu David J. Miller Pennsylvania State University djmiller@engr.psu.edu Kira Poskanzer University of California, San Francisco Kira.Poskanzer@ucsf.edu Yue Wang Virginia Tech yuewang@vt.edu Lin Tian University of California, Davis lintian@ucdavis.edu Guoqiang Yu Virginia Tech yug@vt.edu Abstract Dynamic time warping (DTW) is a fundamental technique in time series analysis for comparing one curve to another using a flexible time-warping function. However, it was designed to compare a single pair of curves. In many applications, such as in metabolomics and image series analysis, alignment is simultaneously needed for multiple pairs. Because the underlying warping functions are often related, independent application of DTW to each pair is a sub-optimal solution. Yet, it is largely unknown how to efficiently conduct a joint alignment with all warping functions simultaneously considered, since any given warping function is constrained by the others and dynamic programming cannot be applied. In this paper, we show that the joint alignment problem can be transformed into a network flow problem and thus can be exactly and efficiently solved by the max flow algorithm, with a guarantee of global optimality. We name the proposed approach graphical time warping (GTW), emphasizing the graphical nature of the solution and that the dependency structure of the warping functions can be represented by a graph. Modifications of DTW, such as windowing and weighting, are readily derivable within GTW. We also discuss optimal tuning of parameters and hyperparameters in GTW. We illustrate the power of GTW using both synthetic data and a real case study of an astrocyte calcium movie. 1 Introduction Time series, such as neural recordings, economic observations and biological imaging movies, are ubiquitous, containing rich information about the temporal patterns of physical quantities under certain conditions. Comparison of time series lies at the heart of many scientific questions. Due to the time distortions, direct comparison of time series using e.g. Euclidean distance is problematic. Dynamic time warping (DTW) is a powerful and popular technique for time series comparison using flexible warping functions. DTW has been successful for various tasks, including querying, classification, and clustering [1, 2, 3]. Although DTW is a mature approach, significant improvements have been proposed over the years, such as derivative DTW [4], weighted DTW [5], curve pairs with multiple dimensions [6], and extensions for large scale data mining [7]. However, DTW and all its variants consider the alignment of a single pair of time series, while in many applications we encounter the task of aligning multiple pairs simultaneously. One might apply DTW or its variants to each pair separately. However, very often, this is suboptimal because it ignores the dependency structure between the multiple warping functions. For example, when analyzing time lapse imaging data [8], we can consider the data as a collection of time series indexed by pixel. One 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. Figure 1: (a) Each node is a warping path between two curves xn and yn. Neighboring paths are assumed to be similar (A and B) while non-neighboring ones may be quite different (A and C). (b) DTW can be represented as a shortest path problem in a directed graph. Each edge originating from node (k1, k2) has a weight given by the dissimilarity (e.g. Euclidean distance) between xn(k1) and yn(k2). The path distance between the purple and green paths is defined as the area of the shaded parts. (c) Primal and dual graphs. The purple and gold edges are two infinite capacity reverse edges for the dual and primal graphs, respectively. Only two such edges are drawn for clarity. The dashed line shows the auxiliary edges used for transforming the primal graph to the dual graph, which are removed afterwards. (d) Flow chart for GTW. The corresponding figure for each step is annotated. potential task is to compute the warping function associated with every pixel with respect to a given reference time series, with the ultimate goal of identifying signal propagation patterns among pixels. Although different pixels may have different warping functions, we expect that the functions are more similar between adjacent pixels than between distant pixels. That is, we expect a certain degree of smoothness among spatially adjacent warping functions. Another example is profile alignment for liquid chromatography-mass spectrometry (LC-MS) data, which is used to measure expression levels of small biomolecules such as proteins and metabolites. Each profile can be considered as a time series indexed by the retention time [9]. Typically, all profiles in the data set must be aligned to a reference profile. Because the LC-MS data measures similar things against a common reference profile, we expect similar warping functions for all profiles. To the best of our knowledge, there is no existing approach that fundamentally generalizes DTW to jointly model multiple warping functions and align multiple curves, while retaining these advantageous properties of DTW: (1) computational efficiency and (2) a guarantee of global optimality. As we will discuss below, most existing efforts reuse DTW multiple times in a heuristic way. Interestingly, the necessity for and the challenge of a joint and integrated modeling approach come precisely from the two factors that contribute to the wide use of DTW. On one hand, the power of DTW is due to its flexibility in allowing a broad range of warping functions. As is well known in machine learning, an unavoidable consequence of flexibility is the problem of overfitting [10], and hence the estimated warping function is often unreliable. This problem becomes severe when the observed time series are very noisy and this is often the case, rather than the exception, for multiple curve alignment. On the other hand, the solution to DTW is extremely efficient and global optimality (with respect to the DTW objective function) is guaranteed, through the application of dynamic programming [11]. Unfortunately, when we consider joint modeling of multiple warping functions, dynamic programming is no longer applicable due to interactions between the different warping functions. The computational burden of such a joint modeling seems prohibitive, and the feasibility of obtaining the global optimum is far from obvious, because each warping function is coupled to all the rest, either directly or indirectly. Thus, we were fortuitous to find that the joint modeling can be solved very efficiently, with global optimality ensured. In this paper, we develop Graphical Time Warping (GTW) to jointly model multiple time warping functions in a unified framework. Given a set of warping function {Pn, n = 1, . . . , N} to be 2 optimized, a generic form of GTW can be expressed as follows: min {Pn,n=1,...,N} N X n=1 DTW_cost(Pn) + κ X E(m,n)∈Gstruct dissimilarity_cost(Pm, Pn), (1) where Pn is subject to the same constraints as in conventional DTW such as boundary conditions, continuity, and monotonicity [12]. Gstruct is a graph encoding the dependency structure among the warping functions. Each node in the graph represents one warping function, indexed by n, and E(m, n) ∈Gstruct denotes that there is an edge between nodes m and n in Gstruct, whose corresponding warping functions are expected to be similar, as encoded in the second term of the cost (1). DTW_cost is the conventional DTW path finding cost and dissimilarity_cost ensures the neighboring warping functions are similar. The graph Gstruct can be defined by users or induced from other sources, which provides great flexibility for encoding various types of problems. For example, to analyze time series imaging data, the graph can be induced by the pixel grid so that edges exist only between spatially neighboring pixels. Alternatively, when aligning multiple LC-MS profiles, the graph is fully connected, such that each profile has an edge with all other profiles. Since a warping function is a path in a two-dimensional grid from a given source to a given sink (as in Fig.1b), we propose to use the area bounded by two paths as the dissimilarity cost between them. Later, we will show how the optimization problem in Equation (1) equipped with this specific dissimilarity cost can be transformed into a network flow problem and solved by the max flow algorithm [13, 14]. As previously discussed, most DTW improvements have focused on the alignment of a single pair of curves. There are some heuristic efforts that deal with alignment of multiple curves. Chudova jointly performed clustering and time warping using a mixture model [15]; this assumes curves from the same cluster are generated by a single model. This is a suboptimal, restrictive “surrogate” for capturing the relationships between curves, and does not capture relationships as (user-)specified by a graph. Tsai et al. applied an MCMC strategy to align multiple LC-MS profiles with a single prior distribution imposed on all warping functions [9], but the approach is time-consuming and no finite-time convergence to the global optimum is guaranteed. Similarly, algorithms for aligning multiple DNA sequences are based on first clustering the sequences and then progressively aligning them [16, 17]. Most critically, all existing approaches assume special dependency structures, e.g. all nodes (curves) are equally dependent, and do not promise a globally optimal solution, while GTW works with any given dependency structure and finds the globally optimal solution efficiently. Interestingly, the max flow algorithm has long been suggested as an alternative to DTW [13] by researchers in the network flow community. As an example, Uchida extended DTW to the nonMarkovian case and solved it by the max flow algorithm [18]. Max flow formulations have also been developed to solve image segmentation [14], stereo matching [19] and shape matching problems [20]. But researchers in the time series analysis community have paid little attention to the max flow approach, perhaps because dynamic programming is much more efficient than the max flow algorithm and is sufficient for conventional DTW problems. 2 Problem Formulation The task is to jointly align N pairs of curves (xn, yn), 1 ≤n ≤N. For the sake of clarity, but without loss of generality, we assume all curves have the same length K and each curve is indexed by an integer from 1 to N. To rigorously formulate the problem, we have the following definitions. Definition 1 – valid warping function. A valid warping function for the nth pair of curves is a set of integer pairs Pn = {(kn,x, kn,y)} such that the following conditions are satisfied: (a) boundary conditions: (1, 1) ∈Pn and (K, K) ∈Pn; (b) continuity and monotonicity conditions: if (kn,x, kn,y) ∈Pn, then (kn,x −1, kn,y) ∈Pn or (kn,x, kn,y −1) ∈Pn or (kn,x −1, kn,y −1) ∈Pn. Definition 2 – alignment cost. For any given valid warping function Pn and its corresponding pair of curves (xn, yn), the associated alignment cost is defined as follows: cost(Pn) = X (k1,k2)∈Pn g(xn[k1] −yn[k2])), (2) where g(·) is any nonnegative function. 3 Figure 2: (a) GTW graph for two neighboring pairs. Only two (bidirectional) edges (green) are drawn for clarity. The orange background represents the (single pair) primal graphs. The blue foreground represents the dual graphs. (b) A neighborhood structure used for simulation. In the center is a 10 by 10 grid for 100 pairs, with e.g. a close spatial neighborhood defined around each grid point. The warping paths for the three blue squares are shown. The short red and green lines indicate when time shifts occur. They are at different positions along the three paths. The warping paths for spatially close pairs should be similar. Definition 3 – neighboring warping functions. Suppose the dependency structure for a set of N valid warping functions is given by the graph Gstruct = {Vs, Es}, where Vs is the set of nodes, with each node corresponding to a warping function, and Es is the set of undirected edges between nodes. If there is an edge between the mth and nth nodes, we call Pm and Pn neighbors, denoted by (m, n) ∈Neib. Definition 4 – distance between two valid warping functions. We define the distance between two valid warping functions dist(Pm, Pn) as the area of the region bounded by the two paths as shown in Fig.1b. When we jointly align multiple pairs of curves, our goal is to minimize both the overall alignment cost and the distance between neighboring warping functions. Mathematically, denoting VP the set of valid warping function and κ1 the hyperparameter, we want to solve the following optimization problem: min P f(P) = min P ={Pn∈VP |1≤n≤N} N X n=1 cost(Pn) + κ1 X (m,n)∈Neib dist(Pm, Pn) (3) 3 Methods In this section, we first construct a graph based on Equation (3); then we prove that Equation (3) can be solved via the well-known max flow problem in the graph; finally we provide a practical algorithm. 3.1 Graph construction Definition 5 – directed planar graph for a single pair of curves. For each pair of curves, consistent with the cost function (2), there is an induced directed planar graph [21], Gn := {Vn, En}, 1 ≤n ≤ N, where Vn and En are the nodes and directed edges, respectively. An example is shown in Fig.1b. Definition 6 – dual graph. Define G′ n := {V ′ n, E′ n} as the dual graph of the directed planar graph Gn, where nodes V ′ n are all faces of Gn, and for each e ∈En, we have a new edge e′ ∈E′ n connecting the faces from the right side of e to the left side. This edge is directed (with positive direction by convention). The edge weights are the same as for the primal graph Gn. An example is shown in Fig.1c. In contrast to conventional dual graph theory, one critical innovation here is that besides the positive edge we add in one more edge with reverse direction in the dual graph corresponding to each edge in 4 the primal graph. The weight for the reversed edge is set to infinity. This design is critical: otherwise, as demonstrated in Fig.3c, we cannot get an equivalent simpler problem. Definition 7 – GTW graph. The GTW graph Ggtw := {Vgtw, Egtw} is defined as the integrated graph of all dual graphs {G′ n|1 ≤n ≤N} with the integration guided by the neighborhood of warping functions, such that Vgtw = {V ′ n|1 ≤n ≤N} and Egtw = {E′ n|1 ≤n ≤N} ∪ {(V ′ m,i, V ′ n,i)|(m, n) ∈Neib}. All newly introduced edges (V ′ m,i, V ′ n,i) are bi-directional with capacity κ2 (whereas all other edges have capacity proportional to the distance between two curves, measured at a pair of time points, i.e. g(xn(k1) −yn(k2). An example is shown in Fig.2a. 3.2 Equivalent problem We claim that the GTW problem as stated in Equation (3) is equivalent to the minimum cut problem on the GTW graph Ggtw if we set κ2 = 2κ1. 3.3 Proof of equivalence For brevity, more proofs of lemmas can be found in the supplementary material. Definition 8 – labeling of graph. L is a labeling of graph G if it assigns each node in G a binary label. L can induce a cut set C = {(i, j)|L(i) ̸= L(j), (i, j) ∈EG}.The corresponding cut (or flow) is cut(L) = cut(C) = P (i,j)∈C weight(i, j), where weight(i, j) is the weight on the edge between nodes i and j. Based on its construction, a labeling L for the graph Ggtw can be written as L = {Ln|1 ≤n ≤N}, where Ln is a labeling for the dual graph G′ n. So we can express the minimum cut problem for the graph Ggtw as: min L g(L) = min L:={Ln|1≤n≤N} N X n=1 cut(Ln) + κ2 X (m,n)∈Neib cut(Lm, Ln), (4) where cut(Ln) is the cut of all edges for G′ n and cut(Lm, Ln) is the number of the cut edges between two neighboring dual graphs G′ m and G′ n. Denote Lmf as the labeling induced by applying the max flow algorithm on Ggtw, where for each node v, Lmf(v) = 0 if distres(v, s) < ∞and Lmf(v) = 1 if distres(v, s) = ∞, where distres(i, j) is the distance between nodes i and j on the residual graph Gext,res given by the maximum flow algorithm and s and t are the source and sink nodes of Ggtw, respectively. Denote S = {v|Lmf(v) = 0} and T = {v|Lmf(v) = 1}. We further denote Lmf,n as the component corresponding to G′ n. Similarly, Sn and Tn are subsets of S and T, respectively. Obviously, by the max-flow min-cut theorem, the resulting cut set Cmf has the smallest cut. Cmf,n is the cut set restricted to the graph G′ n. Lemma 1 Given labeling Lmf,n ∈Lmf, Sn forms a single connected area within graph G′ n. That is, ∀i ∈Sn, there is a path with nodes {i, j, k, . . . , s} ⊂Sn from i to s. Similarly, Tn also forms a single connected area. In other words, after applying the max flow algorithm on Ggtw, members of group Sn do not completely surround members of group Tn, or vice versa. Definition 9 – directed cut set. Cut set C is a directed cut set if ∀(i, j) ∈C, either i ∈S and j ∈T or cap(i, j) = ∞, i ∈T and j ∈S. As will be seen, this definition ensures that the cut set includes only the edges e′ that correspond to edges in the primal graph Gn, instead of the reverse edges introduced when building the dual graph G′ n, which give the wrong path direction. Lemma 2 Cmf,n is a directed cut set. From Lemma 1 and 2, we can build the link between the first term of f (Equation (3)) and g (Equation (4)). Lemma 3 For any directed cut set Cn, 1 ≤n ≤N for Ggtw, there is a valid warping function Pn, 1 ≤n ≤N for Gn, 1 ≤n ≤N so that cut(Cn) = cost(Pn), and vice versa. Lemma 4 For two neighboring pairs (xm, ym) and (xn, yn), dist(Pn, Pm) = 0.5|Cm,n|, where we denote Cm,n := {(V ′ m,i, V ′ n,i)|V ′ m,i ∈S, V ′ n,i ∈T or V ′ m,i ∈T, V ′ n,i ∈S}. 5 Lemma 4 states that the distance between two paths in the primal graph (Fig.1b) is the same as the number of neighborhood cuts between those two pairs, up to a constant scaling factor. Lemma 5 Let P be a set of valid warping functions for {Gn|1 ≤n ≤N} and let L be the labeling in Ggtw that corresponds to directed cuts. If κ2 = 2κ1, given P, we can find a corresponding L with f(P) = g(L) and given L, we can find a corresponding P so that g(L) = f(P). Proof. First we show each P gives an L. As each path Pn can be transformed to a directed cut Cn (Lemma 3), which by definition is also a cut, it gives a valid labeling Ln and cost(Pn) = cut(Ln) by definition. And dist(Pm, Pn) = 0.5 × cut(Lm, Ln) by Lemma 4. Then, with κ2 = 2κ1, we find L = {Ln|1 ≤n ≤N} such that f(P) = g(L). Conversely, given L = {Ln|1 ≤n ≤N} corresponding to directed cuts Cn, Cn can be transformed back to a valid path Pn with the same cost (Lemma 3). For the cut between Lm and Ln, we still have cut(Lm, Ln) = 2 × dist(Pm, Pn) using Lemma 4. Thus we find a set P = {Pn|1 ≤n ≤N} with the same cost as L. Theorem 1 If Lmf is a labeling induced by the maximum flow algorithm on Ggtw, then the corresponding P minimizes f(P). Proof. Assume the max flow algorithm gives us a labeling L, which corresponds to path P and by Lemma 5 the relationship f(P) = g(L) holds. Here f is the primal cost function and g is the dual cost function. Assume we have another labeling L′ ̸= L and it corresponds to another path P ′; then also by Lemma 5 f(P ′) = g(L′) holds. Suppose path P ′ is better than path P, i.e. f(P ′) < f(P). This implies g(L′) < g(L), which contradicts the assumption that L is the labeling from the max flow algorithm. Thus, there is no better path in terms of f() than that associated with the result of the max flow algorithm. From Theorem 1 we know that after the max flow algorithm and labeling finishes, we can get a single path Pn for each pair (xn, yn), which solves the primal form optimization problem. Since the labeling sometimes may not be unique, different labelings may have the same cut. Correspondingly, different paths in the primal graph may have the same (jointly minimum) cost. Corollary 1 If κ1 = κ2 = 0, L that minimizes g(L) corresponds to the P = {Pn|1 ≤n ≤N} where Pn is the solution of the single pair DTW problem for (xn, yn). 3.4 Flowchart of GTW algorithm Once the equivalence is established, a practical algorithm is readily available, as shown in the flowchart of Fig.1d. Assuming the hyperparameter (κ1) is fixed, one first constructs a primal graph separately for each alignment task, then converts each primal graph to its dual form, and finally adds in edges to the set of dual graphs to obtain the GTW graph. Once we get the GTW graph, we can apply any maximum flow algorithm to the graph, leading to the minimum cut set Cmf. For each sub cut-set Cmf,n corresponding to the nth dual graph G′ n, we convert the cut edges back to edges in the primal graph Gn. The resulting edges will be connected as a warping path and hence lead to a warping function. The set of resultant warping functions are the solution to our GTW problem. A working example is given in the Supplementary. Note also that, as indicated in Fig.1d, this algorithm can be iteratively applied, with parameter (and hyperparameter) re-estimation performed at each iteration. The primary parameter is the noise variance (which can easily be generalized to a separate noise variance parameter for each pair of curves, when appropriate). In addition to the major hyperparameter κ1 in Equation (3), we may use other hyperparameters to incorporate prior knowledge such as favoring a diagonal warping direction, which actually results in an extension of DTW even for a single pair of curves. In the Supplement, we show that the hyperparameters can be tuned, along with parameters, via either cross validation or approximately consistent with maximum likelihood estimation. In addition, as a heuristic rule of thumb, we can choose κ1 = aσ2, where σ2 is the noise variance and a ∈(1, 10). 4 Experimental results We used synthetic and real data to compare the performance of GTW and DTW. For the synthetic data, we evaluate the performance by the estimation error for the warping path Pn. For real data, we examine the spatial delay pattern relative to a reference curve. We also illustrate the impact of the capacity of the reverse edges. More experiments can be found in the Supplement. 6 Figure 3: (a) The curves before (blue, xn) and after (red, yn) warping in the simulation. The green dashed squares indicate where the warping occurs. (b) Performance comparison of GTW and DTW for 100 simulations under different additive noise variances. Both cases include the off-diagonal weights β (see section 4.1). Error bars indicate standard deviation. (c) The impact of reverse capacity. Left: a pair of curves from an astrocyte imaging movie. Only times 81 to 100 are shown. The right three figures are the warping paths with different reverse capacities. Pos_cap is the capacity for corresponding edges from the primal graph. Red dashed circles indicate where the DTW constraints are violated. (d) Estimated propagation patterns on the astrocyte image. Left: original movie from times 6 to 8. The yellow dot is the position of the reference curve. Middle: the delay pattern of pixels relative to the reference curve, estimated by GTW. Right: results for DTW. 4.1 Experiment on synthetic data We generated N = 100 pairs of curves (xn, yn). Each pair is linked by a warping function Wn so that yn = Wn(xn). Curve xn is a time series composed of low pass filtered Gaussian noise and yn is generated by applying Wn on xn (Fig.3a). Noise is also added to both xn and yn. In this simulation the pairs are in a 10 × 10 four connected grid; thus the ground-truth warping paths for neighboring pairs are similar (Fig.2b). The warping path of the pair at location (1, 1) has a one time-point shift from 21 to 30 and another one from 71 to 80. The pair at location (10, 10) has a one time point shift from 30 to 39 and another from 62 to 71. The warping function for pairs between these locations are smoothly interpolated. We ran the simulation 100 times and added uncorrelated Gaussian noises to xn and yn. All hyperparameters were initialized to 0; the noise variance was initialized to 0.01. In addition, the distance of the path from the diagonal line was penalized via a hyperparameter β = √ d/σ2, where d is the distance of a point in the path to the diagonal. When the parameter and hyperparameter changes were all less than 0.001, we stopped the algorithm. Convergence usually occurred within 10 iterations. The estimated path was compared with the ground truth one and we define the normalized error as errnorm = 1 (K −1)N K−1 X k=1 N X n=1 S ˆ Pn(k, k + 1) −SPn(k, k + 1) (5) Here S ˆ Pn(k, k + 1) is the area under the path ˆPn between times k and k + 1. GTW improves the accuracy in estimating warping functions. As shown in Fig.3b, GTW outperforms DTW even when the noise level is small or moderate. Moreover, while DTW degrades with increasing noise, GTW maintains a much smaller change in its normalized error for increasing noise. 7 Infinite capacity reverse edges are critical. In Fig.3c we illustrate the importance of introducing infinite capacity reverse edges when we construct the dual graph G′ n for each primal graph Gn. This ensures the cut found by the maximum flow algorithm is a directed cut, which is linked to a path in the primal graph that satisfies the constraints of DTW. If the reverse edge is not added, the max flow algorithm acts as if there is a reverse edge with zero weight. Alternatively, we can add in a reverse edge with the same weight as for the positive direction. However, in both cases as shown in the right two subplots of Fig.3c, DTW’s monotonicity and continuity constraints are violated almost everywhere, since what we obtain by max flow in this case is no longer a directed cut and the path in the primal graph is no longer a valid warping function. 4.2 Application to time-lapse astrocyte calcium imaging data We applied GTW to estimate the propagation patterns of astrocyte calcium fluorescent imaging data [22, 8]. The movie was obtained from a neuro-astrocyte co-cultured Down syndrome cell line. It contains 100 time points and rich types of propagation are observed during the time course. Here we focused on a selected region. The movie between time instants 6 and 8 is shown in the left column of Fig.3d. At time 6, the activity occurs at the center part and it spreads out over the subsequent time points. At time 8, the active area is the largest. Since the movie was taken while the cells were under drug treatment conditions, the properties of these calcium waves are important features of interest. Here we focused on one segmented area and identified the propagation pattern within it. We extracted the curve for one pixel as the reference curve x (Fig.3c, left) and all other pixels are yn. So now x1 = x2 = · · · = xN = x, which is a special case of GTW. All parameters and hyperparameters were initialized in the same way as previously and both methods included an off-diagonal cost β. From the estimated warping path, we extracted the delay relative to the reference curve, which is defined as the largest discrepancy from the diagonal line at a given time point (Fig.3d, middle and right columns). GTW gives cleaner patterns of delay compared to DTW, which produces noisier results. 5 Discussion While GTW can be applied to time series data analysis tasks like classification and clustering to obtain a smoothed distance measure, it could be even more powerful for mining the relationships between warping functions. Their differences could be classified or clustered, and explained by other features (or factors) for those curve pairs. This may bring further insights and interpretability to the solution. As a two-layer network for time series, GTW is a general framework for analyzing the pattern of warping functions. First, the time series can be flexibly organized into pairs with DTW constraints. One curve can participate in multiple pairings and even play different roles (either as a reference or as a test curve). Partial matching, direction preference and weighting of DTW can be readily incorporated. In addition, GTW allows the test curve and the reference curve to have different lengths. Second, the construction of graphs from pairs adds another layer of flexibility. For spatio-temporal data or video analysis, physical locations or pixels naturally guide the choice of graph edges. Otherwise, we can avoid using a fully connected graph by utilizing any auxiliary information on each pair of curves to build the graph. For example, features related to each subject (e.g., clinical features) can be used to enforce a sparse graph structure. 6 Conclusion In this paper, we developed graphical time warping (GTW) to impose a flexible dependency structure among warping functions to jointly align multiple pairs of curves. After formulating the original cost function, the single pair time warping term is transformed into its dual form and pairwise costs are added. We proved the equivalence of this dual form and the primal form by the properties of the dual-directed graph as well as the specific structure of the primal single pair shortest path graph. Windowing, partial matching, direction, and off-diagonal costs can also be incorporated in the model, which makes GTW flexible for various applications of time warping. Iterative unsupervised parameter estimation and inference by max flow are shown to be effective and efficient in our experiments. Simulation results and a case study of astrocyte propagation demonstrate the effectiveness of our approach. 8 References [1] D. J. Berndt and J. Clifford, “Using Dynamic Time Warping to Find Patterns in Time Series,” in Proceedings of the 3rd International Conference on Knowledge Discovery and Data Mining, AAAIWS’94, (Seattle, WA), pp. 359–370, AAAI Press, 1994. [2] T.-c. Fu, “A review on time series data mining,” Engineering Applications of Artificial Intelligence, vol. 24, pp. 164–181, Feb. 2011. [3] T. Warren Liao, “Clustering of time series data—a survey,” Pattern Recognition, vol. 38, pp. 1857–1874, Nov. 2005. [4] E. Keogh and M. Pazzani, “Derivative Dynamic Time Warping,” in Proceedings of the 2001 SIAM International Conference on Data Mining, Proceedings, pp. 1–11, Society for Industrial and Applied Mathematics, Apr. 2001. [5] Y.-S. Jeong, M. K. Jeong, and O. A. Omitaomu, “Weighted dynamic time warping for time series classification,” Pattern Recognition, vol. 44, pp. 2231–2240, Sept. 2011. [6] M. Shokoohi-Yekta, J. Wang, and E. Keogh, “On the Non-Trivial Generalization of Dynamic Time Warping to the Multi-Dimensional Case,” in Proceedings of the 2015 SIAM International Conference on Data Mining, pp. 289–297, Society for Industrial and Applied Mathematics, June 2015. [7] T. Rakthanmanon, B. Campana, A. Mueen, G. Batista, B. Westover, Q. Zhu, J. Zakaria, and E. Keogh, “Searching and mining trillions of time series subsequences under dynamic time warping,” in Proceedings of the 18th ACM SIGKDD, pp. 262–270, ACM, 2012. [8] A. Volterra, N. Liaudet, and I. Savtchouk, “Astrocyte Ca2+ signalling: an unexpected complexity,” Nat Rev Neurosci, vol. 15, pp. 327–335, May 2014. [9] T.-H. Tsai, M. G. Tadesse, C. Di Poto, L. K. Pannell, Y. Mechref, Y. Wang, and H. W. Ressom, “Multiprofile Bayesian alignment model for LC-MS data analysis with integration of internal standards,” Bioinformatics, vol. 29, pp. 2774–2780, Nov. 2013. [10] J. Friedman, T. Hastie, and R. Tibshirani, The elements of statistical learning, vol. 1. Springer series in statistics Springer, Berlin, 2001. [11] P. F. Felzenszwalb and R. Zabih, “Dynamic Programming and Graph Algorithms in Computer Vision,” IEEE Trans. Pattern Anal. Mach. Intell., vol. 33, pp. 721–740, Apr. 2011. [12] E. Keogh and C. A. Ratanamahatana, “Exact indexing of dynamic time warping,” Knowl Inf Syst, vol. 7, pp. 358–386, May 2004. [13] R. Ahuja, T. Magnanti, and J. Orlin, Network Flows: Theory, Algorithms, and Applications. Prentice Hall, Feb. 1993. [14] Y. Boykov and V. Kolmogorov, “An experimental comparison of min-cut/max- flow algorithms for energy minimization in vision,” IEEE Transactions on Pattern Analysis and Machine Intelligence, vol. 26, pp. 1124–1137, Sept. 2004. [15] D. Chudova, S. Gaffney, and P. Smyth, “Probabilistic models for joint clustering and time-warping of multidimensional curves,” in Proceedings of the Nineteenth conference on Uncertainty in Artificial Intelligence, pp. 134–141, Morgan Kaufmann Publishers Inc., 2002. [16] P. Hogeweg and B. Hesper, “The alignment of sets of sequences and the construction of phyletic trees: an integrated method,” Journal of molecular evolution, vol. 20, no. 2, pp. 175–186, 1984. [17] F. Sievers, A. Wilm, D. Dineen, T. J. Gibson, K. Karplus, W. Li, R. Lopez, H. McWilliam, M. Remmert, J. Söding, and others, “Fast, scalable generation of high-quality protein multiple sequence alignments using Clustal Omega,” Molecular systems biology, vol. 7, no. 1, p. 539, 2011. [18] S. Uchida, M. Fukutomi, K. Ogawara, and Y. Feng, “Non-Markovian dynamic time warping,” in 2012 21st International Conference on Pattern Recognition (ICPR), pp. 2294–2297, Nov. 2012. [19] H. Ishikawa and D. Geiger, “Occlusions, discontinuities, and epipolar lines in stereo,” in Computer Vision — ECCV’98, Lecture Notes in Computer Science, pp. 232–248, Springer Berlin Heidelberg, June 1998. DOI: 10.1007/BFb0055670. [20] F. R. Schmidt, E. Töppe, D. Cremers, and Y. Boykov, “Efficient Shape Matching Via Graph Cuts,” in Energy Minimization Methods in Computer Vision and Pattern Recognition, no. 4679 in Lecture Notes in Computer Science, pp. 39–54, Springer Berlin Heidelberg, Aug. 2007. [21] B. Korte, J. Vygen, B. Korte, and J. Vygen, Combinatorial optimization, vol. 2. Springer, 2012. [22] Y. Wang, G. Shi, D. J. Miller, Y. Wang, G. Broussard, Y. Wang, L. Tian, and G. Yu, “FASP: A machine learning approach to functional astrocyte phenotyping from time-lapse calcium imaging data,” in 2016 IEEE 13th International Symposium on Biomedical Imaging (ISBI), pp. 351–354, Apr. 2016. 9 | 2016 | 533 |
6,476 | PerforatedCNNs: Acceleration through Elimination of Redundant Convolutions Michael Figurnov1,2, Aijan Ibraimova4, Dmitry Vetrov1,3, and Pushmeet Kohli5 1National Research University Higher School of Economics 2Lomonosov Moscow State University 3Yandex 4Skolkovo Institute of Science and Technology 5Microsoft Research michael@figurnov.ru, aijan.ibraimova@gmail.com, vetrovd@yandex.ru, pkohli@microsoft.com Abstract We propose a novel approach to reduce the computational cost of evaluation of convolutional neural networks, a factor that has hindered their deployment in lowpower devices such as mobile phones. Inspired by the loop perforation technique from source code optimization, we speed up the bottleneck convolutional layers by skipping their evaluation in some of the spatial positions. We propose and analyze several strategies of choosing these positions. We demonstrate that perforation can accelerate modern convolutional networks such as AlexNet and VGG-16 by a factor of 2× - 4×. Additionally, we show that perforation is complementary to the recently proposed acceleration method of Zhang et al. [28]. 1 Introduction The last few years have seen convolutional neural networks (CNNs) emerge as an indispensable tool for computer vision. However, modern CNNs have a high computational cost of evaluation, with convolutional layers usually taking up over 80% of the time. For instance, VGG-16 network [25] for the problem of object recognition requires 1.5 · 1010 floating point multiplications per image. These computational requirements hinder the deployment of such networks on systems without GPUs and in scenarios where power consumption is a major concern, such as mobile devices. The problem of trading accuracy of computations for speed is well-known within the software engineering community. One of the most prominent methods for this problem is loop perforation [18, 19, 24]. In a nutshell, this technique isolates loops in the code that are not critical for the execution, and then reduces their computational cost by skipping some iterations. More recently, researchers have considered problem-dependent perforation strategies that exploit the structure of the problem [23]. Inspired by the general principle of perforation, we propose to reduce the computational cost of CNN evaluation by exploiting the spatial redundancy of the network. Modern CNNs, such as AlexNet, exploit this redundancy through the use of strides in the convolutional layers. However, using the convolutional strides changes the architecture of the network (intermediate representations size and the number of weights in the first fully-connected layer), which might be undesirable. Instead of using strides, we argue for the use of interpolation (perforation) of responses in the convolutional layer. A key element of this approach is the choice of the perforation mask, which defines the output positions to evaluate exactly. We propose several approaches to select the perforation masks and a method of choosing a combination of perforation masks for different layers. To restore the network accuracy, we perform fine-tuning of the perforated network. Our experiments show that this method can reduce the evaluation time of modern CNN architectures proposed in the literature by a factor of 2× - 4× with a small decrease in accuracy. 2 Related Work Reducing the computational cost of CNN evaluation is an active area of research, with both highly optimized implementations and approximate methods investigated. 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. 𝑑"𝑆 𝑋%𝑌′ tensor U data matrix M 𝑌 𝑋 𝑑 𝑑 𝑆 𝑆 im2row kernel K tensor V × = 𝑇 𝑌′ X′ 𝑇 𝑑"𝑆 𝑇 1 1 Figure 1: Reduction of convolutional layer evaluation to matrix multiplication. Our idea is to leave only a subset of rows (defined by a perforation mask) in the data matrix M and to interpolate the missing output values. Implementations that exploit the parallelism available in computational architectures like GPUs (cuda-convnet2 [13], CuDNN [3]) have allowed to significantly reduce the evaluation time of CNNs. Since CuDNN internally reduces the computation of convolutional layers to the matrix-by-matrix multiplication (without explicitly materializing the data matrix), our approach can potentially be incorporated into this library. In a similar vein, the use of FPFGAs [22] leads to better tradeoffs between speed and power consumption. Several papers [5, 9] showed that CNNs may be efficiently evaluated using low precision arithmetic, which is important for FPFGA implementations. Most approximate methods of decreasing the CNN computational cost exploit the redundancies of the convolutional kernel using low-rank tensor decompositions [6, 10, 16, 28]. In most cases, a convolutional layer is replaced by several convolutional layers applied sequentially, which have a much lower total computational cost. We show that the combination of perforation with the method of Zhang et al. [28] improves upon both approaches. For spatially sparse inputs, it is possible to exploit this sparsity to speed up evaluation and training [8]. While this approach is similar to ours in the spirit, we do not rely on spatially sparse inputs. Instead, we sparsely sample the outputs of a convolutional layer and interpolate the remaining values. In a recent work, Lebedev and Lempitsky [15] also decrease the CNN computational cost by reducing the size of the data matrix. The difference is that their approach reduces the convolutional kernel’s support while our approach decreases the number of spatial positions in which the convolutions are evaluated. The two methods are complementary. Several papers have demonstrated that it is possible to compress the parameters of the fully-connected layers (where most CNN parameters reside) with a marginal error increase [4, 21, 27]. Since our method does not directly modify the fully-connected layers, it is possible to combine these methods with our approach and obtain a fast and small CNN. 3 PerforatedCNNs The section provides a detailed description of our approach. Before proceeding further, we introduce the notation that will be used in the rest of the paper. Notation. A convolutional layer takes as input a tensor U of size X × Y × S and outputs a tensor V of size X′ × Y ′ × T, X′ = X −d + 1, Y ′ = Y −d + 1. The first two dimensions are spatial (height and width), and the third dimension is the number of channels (for example, for an RGB input image S = 3). The set of T convolution kernels K is given by a tensor of size d × d × S × T. For simplicity of notation, we assume unit stride, no zero-padding and skip the biases. The convolutional layer output may be defined as follows: V (x, y, t) = d X i=1 d X j=1 S X s=1 K(i, j, s, t)U(x + i −1, y + j −1, s) (1) Additionally, we define the set of all spatial indices (positions) of the output Ω= {1, . . . , X′} × {1, . . . , Y ′}. Perforation mask I ⊆Ωis the set of indices in which the outputs are calculated exactly. Denote N = |I| the number of positions to be calculated exactly, and r = 1 −N |Ω| the perforation rate. Reduction to matrix multiplication. To achieve high computational performance, many deep learning frameworks, including Caffe [12] and MatConvNet [26], reduce the computation of convolutional 2 layers to the heavily-optimized matrix-by-matrix multiplication routine of basic linear algebra packages. This process, sometimes referred to as lowering, is illustrated in fig. 1. First, a data matrix M of size X′Y ′ × d2S is constructed using im2row function. The rows of M are elements of patches of input tensor U of size d × d × S. Then, M is multiplied by the kernel tensor K reshaped into size d2S × T. The resulting matrix of size X′Y ′ × T is the output tensor V , up to a reshape. For a more detailed exposition, see [26]. 3.1 Perforated convolutional layer In this section we present the perforated convolutional layer. In a small fraction of spatial positions, the outputs of the proposed layer are equal to the outputs of a usual convolutional layer. The remaining values are interpolated using the nearest neighbor from this set of positions. We evaluate other interpolation strategies in appendix A. The perforated convolutional layer is a generalization of the standard convolutional layer. When the perforation mask is equal to all the output spatial positions, the perforated convolutional layer’s output equals the conventional convolutional layer’s output. Formally, let I ⊆Ωbe the perforation mask of spatial output to be calculated exactly (the constraint that the masks are shared for all channels of the output is required for the reduction to matrix multiplication). The function ℓ(x, y) : Ω→I returns the index of the nearest neighbor in I according to Euclidean distance (with ties broken randomly): ℓ(x, y) = (ℓ1(x, y), ℓ2(x, y)) = arg min (x′,y′)∈I p (x −x′)2 + (y −y′)2. (2) Note that the function ℓ(x, y) may be calculated in advance and cached. The perforated convolutional layer output ˆV is defined as follows: ˆV (x, y, t) = V (ℓ1(x, y), ℓ2(x, y), t), (3) where V (x, y, t) is the output of the usual convolutional layer, defined by (1). Since ℓ(x, y) = (x, y) for (x, y) ∈I, the outputs in the spatial positions I are calculated exactly. The values in other positions are interpolated using the value of the nearest neighbor. To evaluate a perforated convolutional layer, we only need to calculate the values V (x, y, t) for (x, y) ∈I, which can be done efficiently by reduction to matrix multiplication. In this case, the data matrix M contains just N = |I| rows, instead of the original X′Y ′ = |Ω| rows. Perforation is not limited to this implementation of a convolutional layer, and can be combined with other implementations that support strided convolutions, such as the direct convolution approach of cuda-convnet2 [13]. In our implementation, we only store the output values V (x, y, t) for (x, y) ∈I. The interpolation is performed implicitly by masking the reads of the following pooling or convolutional layer. For example, when accelerating conv3 layer of AlexNet, the interpolation cost is transferred to conv4 layer. We observe no slowdown of the conv4 layer when using GPU, and a 0-3% slowdown when using CPU. This design choice has several advantages. Firstly, the memory size required to store the activations is reduced by a factor of 1 1−r. Secondly, the following non-linearity layers and 1 × 1 convolutional layers are also sped up since they are applied to a smaller number of elements. 3.2 Perforation masks We propose several ways of generating the perforation masks, or choosing N points from Ω. We visualize the perforation masks I as binary matrices with black squares in the positions of the set I. We only consider the perforation masks that are independent of the input object and leave exploration of input-dependent perforation masks to the future work. Uniform perforation mask is just N points chosen randomly without replacement from the set Ω. However, as can be seen from fig. 2a, for N ≪|Ω|, the points tend to cluster. This is undesirable because a more scattered set I would reduce the average distance to the set I. Grid perforation mask is a set of points I = {a(1), . . . , a(Kx)} × {b(1), . . . , b(Ky)}, see fig. 2b. We choose the values of a(i), b(i) using the pseudorandom integer sequence generation scheme of [7]. Pooling structure mask exploits the structure of the overlaps of pooling operators. Denote by A(x, y) the number of times an output of the convolutional layer is used in the pooling operators. The grid-like pattern as in fig. 2d is caused by a pooling of size 3 × 3 with stride 2 (such parameters are used e.g. in Network in Network and AlexNet). The pooling structure mask is obtained by picking top-N positions with the highest values of A(x, y), with ties broken randomly, see fig. 2c. 3 (a) Uniform (b) Grid (c) Pooling structure 1 2 3 4 (d) Weights A(x, y) Figure 2: Perforation masks, AlexNet conv2, r = 80.25%. Best viewed in color. 0 0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.05 0.1 0.15 0.2 0.25 0.3 0 0.05 0.1 0.15 0.2 0.25 0.3 0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 (a) B(x, y), original network 0 0.05 0.1 0.15 0.2 0.25 0.3 0.35 0.4 (b) B(x, y), perforated network (c) Impact mask, r = 90% Figure 3: Top: ImageNet images and corresponding values of impact G(x, y; V ) for AlexNet conv2. Bottom: average impacts and impact perforation mask for AlexNet conv2. Best viewed in color. Impact mask estimates the impact of perforation of each position on the CNN loss function, and then removes the least important positions. Denote by L(V ) the loss function of the CNN (such as negative log-likelihood) as a function of the considered convolutional layer outputs V . Next, suppose V ′ is obtained from V by replacing one element (x0, y0, t0) with a neutral value zero. We estimate the impact of a position as a first-order Taylor approximation of the magnitude of change of L(V ): |L(V ′) −L(V )| ≈ X X x=1 Y X y=1 T X t=1 ∂L(V ) ∂V (x, y, t)(V ′(x, y, t) −V (x, y, t)) = ∂L(V ) ∂V (x0, y0, t0)V (x0, y0, t0) . (4) The value ∂L(V ) ∂V (x0,y0,t0) may be obtained using backpropagation. In the case of a perforated convolutional layer, we calculate the derivatives with respect to the convolutional layer output V (not the interpolated output ˆV ). This makes the impact of the previously perforated positions zero and sums the impact of the non-perforated positions over all the outputs which share the value. Since we are interested in the total impact of a spatial position (x, y) ∈Ω, we take a sum over all the channels and average this estimate of impacts over the training dataset: G(x, y; V ) = T X t=1 ∂L(V ) ∂V (x, y, t)V (x, y, t) (5) B(x, y) = EV ∼training set G(x, y; V ) (6) Finally, the impact mask is formed by taking the top-N positions with the highest values of B(x, y). Examples of the values of G(x, y; V ), B(x, y) and impact mask are shown on fig. 3. Note that the regions of the high value of G(x, y; V ) usually contain the most salient features of the image. The averaged weights B(x, y) tend to be higher in the center since ImageNet’s images usually contain a centered object. Additionally, a grid-like structure of pooling structure mask is automatically inferred. 4 Network Dataset Error CPU time GPU time Mem. Mult. # conv NIN CIFAR-10 top-1 10.4% 4.6 ms 0.8 ms 5.1 MB 2.2 · 108 3 AlexNet ImageNet top-5 19.6% 16.7 ms 2.0 ms 6.6 MB 0.5 · 109 5 VGG-16 top-5 10.1% 300 ms 29 ms 110 MB 1.5 · 1010 13 Table 1: Details of the CNNs used for the experimental evaluation. Timings, memory consumption and number of multiplications are normalized by the batch size. Memory consumption is the memory required to store activations (intermediate results) of the network during the forward pass. CPU speedup (times) 1 2 3 4 5 6 Top-5 error increase (%) 0 2 4 6 8 10 Uniform Grid Pooling structure Impact (a) conv2, CPU GPU speedup (times) 1 2 3 4 5 6 Top-5 error increase (%) 0 2 4 6 8 10 (b) conv2, GPU CPU speedup (times) 1 2 3 4 5 6 Top-5 error increase (%) 0 2 4 6 8 10 Uniform Grid Impact (c) conv3, CPU GPU speedup (times) 1 2 3 4 5 6 Top-5 error increase (%) 0 2 4 6 8 10 (d) conv3, GPU Figure 4: Acceleration of a single layer of AlexNet for different mask types without fine-tuning. Values are averaged over 5 runs. Since perforation of a layer changes the impacts of all the layers, in the experiments we iterate between increasing the perforation rate of a layer and recalculation of impacts. We find that this improves results by co-adapting the perforation masks of different convolutional layers. 3.3 Choosing the perforation configurations For whole network acceleration, it is important to find a combination of per-layer perforation rates that would achieve high speedup with low error increase. To do this, we employ a simple greedy strategy. We use a single perforation mask type and a fixed range of increasing perforation rates. Denote by t the evaluation time of the accelerated network and by e the objective (we use negative log-likelihood for a subset of training images). Let t0 and e0 be the respective values for the non-accelerated network. At each iteration, we try to increase the perforation rate for each layer and choose the layer for which this results in the minimal value of the cost function e−e0 t0−t . 4 Experiments We use three convolutional neural networks of increasing size and computational complexity: Network in Network [17], AlexNet [14] and VGG-16 [25], see table 1. In all networks, we attempt to perforate all the convolutional layers, except for the 1 × 1 convolutional layers of NIN. We perform timings on a computer with a quad-core Intel Core i5-4460 CPU, 16 GB RAM and a nVidia Geforce GTX 980 GPU. The batch size used for timings is 128 for NIN, 256 for AlexNet and 16 for VGG-16. The networks are obtained from Caffe Model Zoo. For AlexNet, the Caffe reimplementation is used which is slightly different from the original architecture (pooling and normalization layers are swapped). We use a fork of MatConvNet framework for all experiments, except for fine-tuning of AlexNet and VGG-16, for which we use a fork of Caffe. The source code is available at https://github.com/mfigurnov/perforated-cnn-matconvnet, https://github.com/mfigurnov/perforated-cnn-caffe. We begin our experiments by comparing the proposed perforation masks in a common benchmark setting: acceleration of a single AlexNet layer. Then, we compare whole-network acceleration with the best-performing masks to baselines such as decrease of input images size and an increase of strides. We proceed to show that perforation scales to large networks by presenting the wholenetwork acceleration results for AlexNet and VGG-16. Finally, we demonstrate that perforation is complementary to the recently proposed acceleration method of Zhang et al. [28]. 5 Method CPU time ↓ Error ↑(%) Impact, r = 3 4, 3 × 3 filters 9.1× +1 Impact, r = 5 6 5.3× +1.4 Impact, r = 4 5 4.2× +0.9 Lebedev and Lempitsky [15] 20× top-1 +1.1 Lebedev and Lempitsky [15] 9× top-1 +0.3 Jaderberg et al. [10] 6.6× +1 Lebedev et al. [16] 4.5× +1 Denton et al. [6] 2.7× +1 Table 2: Acceleration of AlexNet’s conv2. Top: our results after fine-tuning, bottom: previously published results. Result of [10] provided by [16]. The experiment with reduced spatial size of the kernel (3 × 3, instead of 5 × 5) suggests that perforation is complementary to the “brain damage” method of [15] which also reduces the spatial support of the kernel. 4.1 Single layer results We explore the speedup-error trade-off of the proposed perforation masks on the two bottleneck convolutional layers of AlexNet, conv2 and conv3, see fig. 4. The pooling structure perforation mask is only applicable to the conv2 because it is directly followed by a max-pooling, whereas the conv3 is followed by another convolutional layer. We see that impact perforation mask works best for the conv2 layer while grid mask performs very well for conv3. The standard deviation of results is small for all the perforation masks, except the uniform mask for high speedups (where the grid mask outperforms it). The results are similar for both CPU and GPU, showing the applicability of our method for both platforms. Note that if we consider the best perforation mask for each speedup value, then we see that the conv2 layer is easier to accelerate than the conv3 layer. We observe this pattern in other experiments: layers immediately followed by a max-pooling are easier to accelerate than the layers followed by a convolutional layer. Additional results for NIN network are presented in appendix B. We compare our results after fine-tuning to the previously published results on the acceleration of AlexNet’s conv2 in table 2. Motivated by the results of [15] that the spatial support of conv2 convolutional kernel may be reduced with a small error increase, we reduce the kernel’s spatial size from 5 × 5 to 3 × 3 and apply the impact perforation mask. This leads to the 9.1× acceleration for 1% top-5 error increase. Using the more sophisticated method of [15] to reduce the spatial support may lead to further improvements. 4.2 Baselines We compare PerforatedCNNs with the baseline methods of decreasing the computational cost of CNNs by exploiting the spatial redundancy. Unlike perforation, these methods decrease the size of the activations (intermediate outputs) of the CNN. For a network with fully-connected (FC) layers, this would change the number of CNN parameters in the first FC layer, effectively modifying the architecture. To avoid this, we use CIFAR-10 NIN network, which replaces FC layers with global average pooling (mean-pooling over all spatial positions in the last layer). We consider the following baseline methods. Resize. The input image is downscaled with the aspect ratio preserved. Stride. The strides of the convolutional layers are increased, making the activations spatially smaller. Fractional stride. Motivated by fractional max-pooling [7], we introduce a more flexible modification of strides which evaluates convolutions on a non-regular grid (with a varying step size), providing a more fine-grained control over the activations size and speedup. We use grid perforation mask generation scheme to choose the output positions to evaluate. We compare these strategies to perforation of all the layers with the two types of masks which performed best in the previous section: grid and impact. Note that “grid” is, in fact, equivalent to fractional strides, but with missing values being interpolated. All the methods, except resize, require a parameter value per convolutional layer, leading to a large number of possible configurations. We use the original network to explore this space of configurations. For impact, we use the greedy algorithm. For stride, we evaluate all possible combinations of parameters. For grid and fractional strides, for each layer we consider the set of rates 1 3, 1 2, . . . , 8 9, 9 10 (for fractional strides this is the fraction of convolutions calculated), and evaluate all combinations of such rates. Then, for each method, we build a Pareto-optimal front of parameters 6 CPU speedup (times) 1 2 3 4 Top-1 error (%) 10 20 30 40 50 60 Resize Stride Frac. stride Grid Impact (a) Original network CPU speedup (times) 1 2 3 4 Top-1 error (%) 10.5 11 11.5 12 12.5 13 13.5 14 14.5 15 (b) After retraining Figure 5: Comparison of whole network perforation (grid and impact mask) with baseline strategies (resizing the input images, increasing the strides of convolutional layers) for acceleration of CIFAR-10 NIN network. which produced smallest error increase for a given CPU speedup. Finally, we train the network weights “from scratch” (starting from a random initialization) for the Pareto-optimal configurations with accelerations close to 2×, 3×, 4×. For fractional strides, we use fine-tuning, since it performs significantly better than training from scratch. The results are displayed on fig. 5. Impact perforation is the best strategy both for the original network and after training the network from scratch. Grid perforation is slightly worse. Convolutional strides are used in many CNNs, such as AlexNet, to decrease the computational cost of training and evaluation. Our results show that if changing the intermediate representations size and training the network from scratch is an option, then it is indeed a good strategy. Although more general, fractional strides perform poorly compared to strides, most likely because they “downsample” the outputs of a convolutional layer non-uniformly, making them hard to process by the next convolutional layer. 4.3 Whole network results We evaluate the effect of perforation of all the convolutional layers of three CNN models. To tune the perforation rates, we employ the greedy method described in section 3.3. We use twenty perforation rates: 1 3, 1 2, 2 3, . . . , 18 19, 19 20. For NIN and AlexNet we use the impact perforation mask. For VGG-16 we use the grid perforation mask as we find that it considerably simplifies fine-tuning. Using more than one type of perforation masks does not improve the results. Obtaining the perforation rates configuration takes about one day for the largest network we considered, VGG-16. In order to decrease the error of the accelerated network, we tune the network’s weights. We do not observe any problems with backpropagation, such as exploding/vanishing gradients. The results are presented in table 3. Perforation damages the network performance significantly, but network weights tuning restores most of the accuracy. All the considered networks may be accelerated by a factor of two on both CPU and GPU, with under 2.6% increase of error. Theoretical speedups (reduction of the number of multiplications) are usually close to the empirical ones. Additionally, the memory required to store network activations is significantly reduced by storing only the non-perforated output values. 4.4 Combining acceleration methods A promising way to achieve high speedups with low error increase is to combine multiple acceleration methods. For this to succeed, the methods should exploit different types of redundancy in the network. In this section, we verify that perforation can be combined with the inter-channel redundancy elimination approach of [28] to achieve improved speedup-error ratios. We reimplement the linear asymmetric method of [28]. It decomposes a convolutional layer with a (d × d × S × T) kernel (height-width-input channels-output channels) into a sequence of two layers, (d × d × S × T ′) →(1 × 1 × T ′ × T), T ′ < T. The second layer is typically very fast, so the overall speedup is roughly T T ′ . When decomposing a perforated convolutional layer, we transfer the perforation mask to the first obtained layer. We first apply perforation to the network and fine-tune it, as in the previous section. Then, we apply the inter-channel redundancy elimination method to this network. Finally, we perform the second round of fine-tuning with a much lower learning rate of 1e-9, due to exploding gradients. All the methods are tested at the theoretical speedup level of 4×. When the two methods are combined, the acceleration rate for each method is taken to be roughly equal. The results are presented in the table 7 Network Device Speedup Mult. ↓Mem. ↓Error ↑(%) Tuned error ↑(%) NIN CPU 2.2× 2.5× 2.0× +1.5 +0.4 3.1× 4.4× 3.5× +5.5 +1.9 4.2× 6.6× 4.4× +8.3 +2.9 GPU 2.1× 3.6× 3.3× +4.5 +1.6 3.0× 10.1× 5.7× +18.2 +5.6 3.5× 19.1× 9.2× +37.4 +12.4 AlexNet CPU 2.0× 2.1× 1.8× +10.7 +2.3 3.0× 3.5× 2.6× +28.0 +6.1 3.6× 4.4× 2.9× +60.7 +9.9 GPU 2.0× 2.0× 1.7× +8.5 +2.0 3.0× 2.6× 2.0× +16.4 +3.2 4.1× 3.4× 2.4× +28.1 +6.2 VGG-16 CPU 2.0× 1.8× 1.5× +15.6 +1.1 3.0× 2.9× 1.8× +54.3 +3.7 4.0× 4.0× 2.5× +71.6 +5.5 GPU 2.0× 1.9× 1.7× +23.1 +2.5 3.0× 2.8× 2.4× +65.0 +6.8 4.0× 4.7× 3.4× +76.5 +7.3 Table 3: Full network acceleration results. Arrows indicate increase or decrease in the metric. Speedup is the wall-clock acceleration. Mult. is a reduction of the number of multiplications in convolutional layers (theoretical speedup). Mem. is a reduction of memory required to store the network activations. Tuned error is the error after training from scratch (NIN) or fine-tuning (AlexNet, VGG16) of the accelerated network’s weights. Perforation Asymm. [28] Mult. ↓Mem. ↓Error ↑(%) Tuned error ↑(%) 4.0× 4.0× 2.5× +71.6 +5.5 3.9× 3.9× 0.93× +6.7 +2.0 1.8× 2.2× 4.0× 1.4× +2.9 +1.6 Table 4: Acceleration of VGG-16, 4× theoretical speedup. First row is the proposed method, the second row is our reimplementation of linear asymmetric method of Zhang et al. [28], the third row is the combined method. Perforation is complementary to the acceleration method of Zhang et al. 4. While the decomposition method outperforms perforation, the combined method is better than both of the components. 5 Conclusion We have presented PerforatedCNNs which exploit redundancy of intermediate representations of modern CNNs to reduce the evaluation time and memory consumption. Perforation requires only a minor modification of the convolution layer and obtains speedups close to theoretical ones on both CPU and GPU. Compared to the baselines, PerforatedCNNs achieve lower error, are more flexible and do not change the architecture of a CNN (number of parameters in the fully-connected layers and the size of the intermediate representations). Retaining the architecture allows to easily plug in PerforatedCNNs into the existing computer vision pipelines and only perform fine-tuning of the network, instead of complete retraining. Additionally, perforation can be combined with acceleration methods which exploit other types of network redundancy to achieve further speedups. In future, we plan to explore the connection between PerforatedCNNs and visual attention by considering input-dependent perforation masks that can focus on the salient parts of the input. Unlike recent works on visual attention [1, 11, 20] which consider rectangular crops of an image, PerforatedCNNs can process non-rectangular and even disjoint salient parts of the image by choosing appropriate perforation masks in the convolutional layers. Acknowledgments. We would like to thank Alexander Kirillov and Dmitry Kropotov for helpful discussions, and Yandex for providing computational resources for this project. This work was supported by RFBR project No. 15-31-20596 (mol-a-ved) and by Microsoft: Moscow State University Joint Research Center (RPD 1053945). 8 References [1] J. Ba, R. Salakhutdinov, R. Grosse, and B. Frey, “Learning wake-sleep recurrent attention models,” NIPS, 2015. [2] T. Chen, “Matrix shadow library,” https://github.com/dmlc/mshadow, 2015. [3] S. Chetlur, C. Woolley, P. Vandermersch, J. Cohen, J. Tran, B. Catanzaro, and E. Shelhamer, “cuDNN: Efficient primitives for deep learning,” arXiv, 2014. [4] M. D. Collins and P. Kohli, “Memory bounded deep convolutional networks,” arXiv, 2014. [5] M. Courbariaux, Y. Bengio, and J. David, “Low precision arithmetic for deep learning,” ICLR, 2015. [6] E. L. Denton, W. Zaremba, J. Bruna, Y. LeCun, and R. Fergus, “Exploiting linear structure within convolutional networks for efficient evaluation,” NIPS, 2014. [7] B. Graham, “Fractional max-pooling,” arXiv, 2014. [8] ——, “Spatially-sparse convolutional neural networks,” arXiv, 2014. [9] S. Gupta, A. Agrawal, K. Gopalakrishnan, and P. Narayanan, “Deep learning with limited numerical precision,” ICML, 2015. [10] M. Jaderberg, A. Vedaldi, and A. Zisserman, “Speeding up convolutional neural networks with low rank expansions,” BMVC, 2014. [11] M. Jaderberg, K. Simonyan, A. Zisserman et al., “Spatial transformer networks,” NIPS, 2015. [12] Y. Jia, E. Shelhamer, J. Donahue, S. Karayev, J. Long, R. Girshick, S. Guadarrama, and T. Darrell, “Caffe: Convolutional architecture for fast feature embedding,” ACM ICM, 2014. [13] A. Krizhevsky, “cuda–convnet2,” https://github.com/akrizhevsky/cuda-convnet2/, 2014. [14] A. Krizhevsky, I. Sutskever, and G. E. Hinton, “Imagenet classification with deep convolutional neural networks,” NIPS, 2012. [15] V. Lebedev and V. Lempitsky, “Fast convnets using group-wise brain damage,” CVPR, 2016. [16] V. Lebedev, Y. Ganin, M. Rakhuba, I. Oseledets, and V. Lempitsky, “Speeding-up convolutional neural networks using fine-tuned CP-decomposition,” ICLR, 2015. [17] M. Lin, Q. Chen, and S. Yan, “Network in network,” ICLR, 2014. [18] S. Misailovic, S. Sidiroglou, H. Hoffmann, and M. Rinard, “Quality of service profiling,” ICSE, 2010. [19] S. Misailovic, D. M. Roy, and M. C. Rinard, “Probabilistically accurate program transformations,” Static Analysis, 2011. [20] V. Mnih, N. Heess, A. Graves et al., “Recurrent models of visual attention,” NIPS, 2014. [21] A. Novikov, D. Podoprikhin, A. Osokin, and D. Vetrov, “Tensorizing neural networks,” NIPS, 2015. [22] K. Ovtcharov, O. Ruwase, J.-Y. Kim, J. Fowers, K. Strauss, and E. S. Chung, “Accelerating deep convolutional neural networks using specialized hardware,” Microsoft Research Whitepaper, 2015. [23] M. Samadi, D. A. Jamshidi, J. Lee, and S. Mahlke, “Paraprox: Pattern-based approximation for data parallel applications,” ASPLOS, 2014. [24] S. Sidiroglou-Douskos, S. Misailovic, H. Hoffmann, and M. Rinard, “Managing performance vs. accuracy trade-offs with loop perforation,” ACM SIGSOFT, 2011. [25] K. Simonyan and A. Zisserman, “Very deep convolutional networks for large-scale image recognition,” ICLR, 2015. [26] A. Vedaldi and K. Lenc, “MatConvNet – convolutional neural networks for MATLAB,” arXiv, 2014. [27] Z. Yang, M. Moczulski, M. Denil, N. de Freitas, A. J. Smola, L. Song, and Z. Wang, “Deep fried convnets,” ICCV, 2015. [28] X. Zhang, J. Zou, K. He, and J. Sun, “Accelerating very deep convolutional networks for classification and detection,” arXiv, 2015. 9 | 2016 | 534 |
6,477 | DeepMath - Deep Sequence Models for Premise Selection Alexander A. Alemi ∗ Google Inc. alemi@google.com François Chollet ∗ Google Inc. fchollet@google.com Niklas Een ∗ Google Inc. een@google.com Geoffrey Irving ∗ Google Inc. geoffreyi@google.com Christian Szegedy ∗ Google Inc. szegedy@google.com Josef Urban ∗† Czech Technical University in Prague josef.urban@gmail.com Abstract We study the effectiveness of neural sequence models for premise selection in automated theorem proving, one of the main bottlenecks in the formalization of mathematics. We propose a two stage approach for this task that yields good results for the premise selection task on the Mizar corpus while avoiding the handengineered features of existing state-of-the-art models. To our knowledge, this is the first time deep learning has been applied to theorem proving on a large scale. 1 Introduction Mathematics underpins all scientific disciplines. Machine learning itself rests on measure and probability theory, calculus, linear algebra, functional analysis, and information theory. Complex mathematics underlies computer chips, transit systems, communication systems, and financial infrastructure – thus the correctness of many of these systems can be reduced to mathematical proofs. Unfortunately, these correctness proofs are often impractical to produce without automation, and present-day computers have only limited ability to assist humans in developing mathematical proofs and formally verifying human proofs. There are two main bottlenecks: (1) lack of automated methods for semantic or formal parsing of informal mathematical texts (autoformalization), and (2) lack of strong automated reasoning methods to fill in the gaps in already formalized human-written proofs. The two bottlenecks are related. Strong automated reasoning can act as a semantic filter for autoformalization, and successful autoformalization would provide a large corpus of computer-understandable facts, proofs, and theory developments. Such a corpus would serve as both background knowledge to fill in gaps in human-level proofs and as a training set to guide automated reasoning. Such guidance is crucial: exhaustive deductive reasoning tools such as today’s resolution/superposition automated theorem provers (ATPs) quickly hit combinatorial explosion, and are unusable when reasoning with a very large number of facts without careful selection [4]. In this work, we focus on the latter bottleneck. We develop deep neural networks that learn from a large repository of manually formalized computer-understandable proofs. We learn the task that is essential for making today’s ATPs usable over large formal corpora: the selection of a limited number of most relevant facts for proving a new conjecture. This is known as premise selection. The main contributions of this work are: ∗Authors listed alphabetically. All contributions are considered equal. †Supported by ERC Consolidator grant nr. 649043 AI4REASON. 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. • A demonstration for the first time that neural network models are useful for aiding in large scale automated logical reasoning without the need for hand-engineered features. • The comparison of various network architectures (including convolutional, recurrent and hybrid models) and their effect on premise selection performance. • A method of semantic-aware “definition”-embeddings for function symbols that improves the generalization of formulas with symbols occurring infrequently. This model outperforms previous approaches. • Analysis showing that neural network based premise selection methods are complementary to those with hand-engineered features: ensembling with previous results produce superior results. 2 Formalization and Theorem Proving In the last two decades, large corpora of complex mathematical knowledge have been formalized: encoded in complete detail so that computers can fully understand the semantics of complicated mathematical objects. The process of writing such formal and verifiable theorems, definitions, proofs, and theories is called Interactive Theorem Proving (ITP). The ITP field dates back to 1960s [16] and the Automath system by N.G. de Bruijn [9]. ITP systems include HOL (Light) [15], Isabelle [37], Mizar [13], Coq [7], and ACL2 [23]. The development of ITP has been intertwined with the development of its cousin field of Automated Theorem Proving (ATP) [31], where proofs of conjectures are attempted fully automatically. Unlike ATP systems, ITP systems allow human-assisted formalization and proving of theorems that are often beyond the capabilities of the fully automated systems. Large ITP libraries include the Mizar Mathematical Library (MML) with over 50,000 lemmas, and the core Isabelle, HOL, Coq, and ACL2 libraries with thousands of lemmas. These core libraries are a basis for large projects in formalized mathematics and software and hardware verification. Examples in mathematics include the HOL Light proof of the Kepler conjecture (Flyspeck project) [14], the Coq proofs of the Feit-Thompson theorem [12] and Four Color theorem [11], and the verification of most of the Compendium of Continuous Lattices in Mizar [2]. ITP verification of the seL4 kernel [25] and CompCert compiler [27] show comparable progress in large scale software verification. While these large projects mark a coming of age of formalization, ITP remains labor-intensive. For example, Flyspeck took about 20 person-years, with twice as much for Feit-Thompson. Behind this cost are our two bottlenecks: lack of tools for autoformalization and strong proof automation. Recently the field of Automated Reasoning in Large Theories (ARLT) [35] has developed, including AI/ATP/ITP (AITP) systems called hammers that assist ITP formalization [4]. Hammers analyze the full set of theorems and proofs in the ITP libraries, estimate the relevance of each theorem, and apply optimized translations from the ITP logic to simpler ATP formalism. Then they attack new conjectures using the most promising combinations of existing theorems and ATP search strategies. Recent evaluations have proved 40% of all Mizar and Flyspeck theorems fully automatically [20, 21]. However, there is significant room for improvement: with perfect premise selection (a perfect choice of library facts) ATPs can prove at least 56% of Mizar and Flyspeck instead of today’s 40% [4]. In the next section we explain the premise selection task and the experimental setting for measuring such improvements. 3 Premise Selection, Experimental Setting and Previous Results Given a formal corpus of facts and proofs expressed in an ATP-compatible format, our task is Definition (Premise selection problem). Given a large set of premises P, an ATP system A with given resource limits, and a new conjecture C, predict those premises from P that will most likely lead to an automatically constructed proof of C by A. We use the Mizar Mathematical Library (MML) version 4.181.11473 as the formal corpus and E prover [32] version 1.9 as the underlying ATP system. The following list exemplifies a small non3ftp://mizar.uwb.edu.pl/pub/system/i386-linux/mizar-7.13.01_4.181. 1147-i386-linux.tar 2 :: t99_jordan: Jordan curve theorem in Mizar for C being Simple_closed_curve holds C is Jordan; :: Translation to first order logic fof(t99_jordan, axiom, (! [A] : ( (v1_topreal2(A) & m1_subset_1(A, k1_zfmisc_1(u1_struct_0(k15_euclid(2))))) => v1_jordan1(A)) ) ). Figure 1: (top) The final statement of the Mizar formalization of the Jordan curve theorem. (bottom) The translation to first-order logic, using name mangling to ensure uniqueness across the entire corpus. (a) Length in chars. (b) Length in words. (c) Word occurrences. (d) Dependencies. Figure 2: Histograms of statement lengths, occurrences of each word, and statement dependencies in the Mizar corpus translated to first order logic. The wide length distribution poses difficulties for RNN models and batching, and many rarely occurring words make it important to take definitions of words into account. representative sample of topics and theorems that are included in the Mizar Mathematical Library: Cauchy-Riemann Differential Equations of Complex Functions, Characterization and Existence of Gröbner Bases, Maximum Network Flow Algorithm by Ford and Fulkerson, Gödel’s Completeness Theorem, Brouwer Fixed Point Theorem, Arrow’s Impossibility Theorem Borsuk-Ulam Theorem, Dickson’s Lemma, Sylow Theorems, Hahn Banach Theorem, The Law of Quadratic Reciprocity, Pepin’s Primality Test for Public-Key Cryptography, Ramsey’s Theorem. This version of MML was used for the latest AITP evaluation reported in [21]. There are 57,917 proved Mizar theorems and unnamed top-level lemmas in this MML organized into 1,147 articles. This set is chronologically ordered by the order of articles in MML and by the order of theorems in the articles. Proofs of later theorems can only refer to earlier theorems. This ordering also applies to 88,783 other Mizar formulas (encoding the type system and other automation known to Mizar) used in the problems. The formulas have been translated into first-order logic formulas by the MPTP system [34] (see Figure 1). Our goal is to automatically prove as many theorems as possible, using at each step all previous theorems and proofs. We can learn from both human proofs and ATP proofs, but previous experiments [26, 20] show that learning only from the ATP proofs is preferable to including human proofs if the set of ATP proofs is sufficiently large. Since for 32,524 (56.2%) of the 57,917 theorems an ATP proof was previously found by a combination of manual and learning-based premise selection [21], we use only these ATP proofs for training. The 40% success rate from [21] used a portfolio of 14 AITP methods using different learners, ATPs, and numbers of premises. The best single method proved 27.3% of the theorems. Only fast and simple learners such as k-nearest-neighbors, naive Bayes, and their ensembles were used, based on hand-crafted features such as the set of (normalized) sub-terms and symbols in each formula. 4 Motivation for the use of Deep Learning Strong premise selection requires models capable of reasoning over mathematical statements, here encoded as variable-length strings of first-order logic. In natural language processing, deep neural networks have proven useful in language modeling [28], text classification [8], sentence pair scoring [3], conversation modeling [36], and question answering [33]. These results have demonstrated the ability of deep networks to extract useful representations from sequential inputs without hand-tuned feature engineering. Neural networks can also mimic some higher-level reasoning on simple algorithmic tasks [38, 18]. 3 Axiom first order logic sequence CNN/RNN Sequence model Conjecture first order logic sequence CNN/RNN Sequence model Concatenate embeddings Fully connected layer with 1024 outputs Fully connected layer with 1 output Logistic loss ! [ A , B ] : ( g t a ... Wx+b Wx+b Wx+b Wx+b Wx+b Ux+c Ux+c Ux+c Maximum Figure 3: (left) Our network structure. The input sequences are either character-level (section 5.1) or word-level (section 5.2). We use separate models to embed conjecture and axiom, and a logistic layer to predict whether the axiom is useful for proving the conjecture. (right) A convolutional model. The Mizar data set is also an interesting case study in neural network sequence tasks, as it differs from natural language problems in several ways. It is highly structured with a simple context free grammar – the interesting task occurs only after parsing. The distribution of lengths is wide, ranging from 5 to 84,299 characters with mean 304.5, and from 2 to 21,251 tokens with mean 107.4 (see Figure 2). Fully recurrent models would have to back-propagate through 100s to 1000s of characters or 100s of tokens to embed a whole statement. Finally, there are many rare words – 60.3% of the words occur fewer than 10 times – motivating the definition-aware embeddings in section 5.2. 5 Overview of our approach The full premise selection task takes a conjecture and a set of axioms and chooses a subset of axioms to pass to the ATP. We simplify from subset selection to pairwise relevance by predicting the probability that a given axiom is useful for proving a given conjecture. This approach depends on a relatively sparse dependency graph. Our general architecture is shown in Figure 3(left): the conjecture and axiom sequences are separately embedded into fixed length real vectors, then concatenated and passed to a third network with two fully connected layers and logistic loss. During training time, the two embedding networks and the joined predictor path are trained jointly. As discussed in section 3, we train our models on premise selection data generated by a combination of various methods, including k-nearest-neighbor search on hand-engineered similarity metrics. We start with a first stage of character-level models, and then build second and later stages of word-level models on top of the results of earlier stages. 5.1 Stage 1: Character-level models We begin by avoiding special purpose engineering by treating formulas on the character-level using an 80 dimensional one-hot encoding of the character sequence. These sequences are passed to a weight shared network for variable length input. For the embedding computation, we have explored the following architectures: 1. Pure recurrent LSTM [17] and GRU [6] networks. 2. A pure multi-layer convolutional network with various numbers of convolutional layers (with strides) followed by a global temporal max-pooling reduction (see Figure 3(right)). 3. A recurrent-convolutional network, that uses convolutional layers to produce a shorter sequence which is processed by a LSTM. The exact architectures used are specified in the experimental section. It is computationally prohibitive to compute a large number of (conjecture, axiom) pairs due to the costly embedding phase. Fortunately, our architecture allows caching the embeddings for conjectures and axioms and evaluating the shared portion of the network for a given pair. This makes it practical to consider all pairs during evaluation. 5.2 Stage 2: Word-level models The character-level models are limited to word and structure similarity within the axiom or conjecture being embedded. However, many of the symbols occurring in a formula are defined by formulas 4 earlier in the corpus, and we can use the axiom-embeddings of those symbols to improve model performance. Since Mizar is based on first-order set theory, definitions of symbols can be either explicit or implicit. An explicit definition of x sets x = e for some expression e, while an implicit definition states a property of the defined object, such as defining a function f(x) by ∀x.f(f(x)) = g(x). To avoid manually encoding the structure of implicit definitions, we embed the entire statement defining a symbol f, and then use the stage 1 axiom-embedding corresponding to the whole statement as a word-level embeddings. Ideally, we would train a single network that embeds statements by recursively expanding and embedding the definitions of the defined symbols. Unfortunately, this recursion would dramatically increase the cost of training since the definition chains can be quite deep. For example, Mizar defines real numbers in terms of non-negative reals, which are defined as Dedekind cuts of non-negative rationals, which are defined as ratios of naturals, etc. As an inexpensive alternative, we reuse the axiom embeddings computed by a previously trained character-level model, mapping each defined symbol to the axiom embedding of its defining statement. Other tokens such as brackets and operators are mapped to fixed pseudo-random vectors of the same dimension. Since we embed one token at a time ignoring the grammatical structure, our approach does not require a parser: a trivial lexer is implemented in a few lines of Python. With word-level embeddings, we use the same architectures with shorter input sequence to produce axiom and conjecture embeddings for ranking the (conjecture, axiom) pairs. Iterating this approach by using the resulting, stronger axiom embeddings as word embeddings multiple times for additional stages did not yield measurable gains. 6 Experiments 6.1 Experimental Setup For training and evaluation we use a subset of 32,524 out of 57,917 theorems that are known to be provable by an ATP given the right set of premises. We split off a random 10% of these (3,124 statements) for testing and validation. Also, we held out 400 statements from the 3,124 for monitoring training progress, as well as for model and checkpoint selection. Final evaluation was done on the remaining 2,724 conjectures. Note that we only held out conjectures, but we trained on all statements as axioms. This is comparable to our k-NN baseline which is also trained on all statements as axioms. The randomized selection of the training and testing sets may also lead to learning from future proofs: a proof Pj of theorem Tj written after theorem Ti may guide the premise selection for Ti. However, previous k-NN experiments show similar performance between a full 10-fold cross-validation and incremental evaluation as long as chronologically preceding formulas participate in proofs of only later theorems. 6.2 Metrics For each conjecture, our models output a ranking of possible premises. Our primary metric is the number of conjectures proved from the top-k premises, where k = 16, 32, . . . , 1024. This metric can accommodate alternative proofs but is computationally expensive. Therefore we additionally measure the ranking quality using the average maximum relative rank of the testing premise set. Formally, average max relative rank is aMRR = mean C max P ∈Ptest(C) rank(P, Pavail(C)) |Pavail(C)| where C ranges over conjectures, Pavail(C) is the set of premises available to prove C, Ptest(C) is the set of premises for conjecture C from the test set, and rank(P, Pavail(C)) is the rank of premise P among the set Pavail(C) according to the model. The motivation for aMRR is that conjectures are easier to prove if all their dependencies occur early in the ranking. Since it is too expensive to rank all axioms for a conjecture during continuous evaluation, we approximate our objective. For our holdout set of 400 conjectures, we select all true dependencies Ptest(C) and 128 fixed random false dependencies from Pavail(C)−Ptest(C) and compute the average max relative rank in this ordering. Note that aMRR is nonzero even if all true dependencies are ordered before false dependencies; the best possible value is 0.051. 5 Figure 4: Specification of the different embedder networks. 6.3 Network Architectures All our neural network models use the general architecture from Fig 3: a classifier on top of the concatenated embeddings of an axiom and a conjecture. The same classifier architecture was used for all models: a fully-connected neural network with one hidden layer of size 1024. For each model, the axiom and conjecture embedding networks have the same architecture without sharing weights. The details of the embedding networks are shown in Fig 4. 6.4 Network Training The neural networks were trained using asynchronous distributed stochastic gradient descent using the Adam optimizer [24] with up to 20 parallel NVIDIA K-80 GPU workers per model. We used the TensorFlow framework [1] and the Keras library [5]. The weights were initialized using [10]. Polyak averaging with 0.9999 decay was used for producing the evaluation weights [30]. The character level models were trained with maximum sequence length 2048 characters, where the word-level (and definition embedding) based models had a maximum sequence length of 500 words. For good performance, especially for low cutoff thresholds, it was critical to employ negative mining during training. A side process was continuously evaluating many (conjecture, axiom) pairs. For each conjecture, we pick the lowest scoring statements that have higher score than the lowest scoring true positive. A queue of previously mined negatives is maintained for producing a mixture of examples in which the ratio of mined instances is about 25% and the rest are randomly selected premises. Negative mining was crucial for good quality: at the top-16 cutoff, the number of proved theorems on the test set has doubled. For the union of proof attempts over all cutoff thresholds, the ratio of successful proofs has increased from 61.3% to 66.4% for the best neural model. 6.5 Experimental Results Our best selection pipeline uses a stage-1 character-level convolutional neural network model to produce word-level embeddings for the second stage. The baseline uses distance-weighted kNN [19, 21] with handcrafted semantic features [22]. For all conjectures in our holdout set, we consider all the chronologically preceding statements (lemmas, definitions and axioms) as premise 6 (a) Training accuracy for different character-level models without hard negative mining. Recurrent models seem underperform, while pure convolutional models yield the best results. For each architecture, we trained three models with different random initialization seeds. Only the best runs are shown on this graph; we did not see much variance between runs on the same architecture. (b) Test average max relative rank for different models without hard negative mining. The best is a word-level CNN using definition embeddings from a character-level 2-layer CNN. An identical wordembedding model with random starting embedding overfits after only 250,000 iterations and underperforms the best character-level model. candidates. In the DeepMath case, premises were ordered by their logistic scores. E prover was applied to the top-k of the premise-candidates for each of the cutoffs k ∈(16, 32, . . . , 1024) until a proof is found or k = 1024 fails. Table 1 reports the number of theorems proved with a cutoff value at most the k in the leftmost column. For E prover, we used auto strategy with a soft time limit of 90 seconds, a hard time limit of 120 seconds, a memory limit of 4 GB, and a processed clauses limit of 500,000. Our most successful models employ simple convolutional networks followed by max pooling (as opposed to recurrent networks like LSTM/GRU), and the two stage definition-based def-CNN outperforms the naïve word-CNN word embedding significantly. In the latter the word embeddings were learned in a single pass; in the former they are fixed from the stage-1 character-level model. For each architecture (cf. Figure 4) two convolutional layers perform best. Although our models differ significantly from each other, they differ even more from the k-NN baseline based on hand-crafted features. The right column of Table 1 shows the result if we average the prediction score of the stage-1 model with that of the definition based stage-2 model. We also experimented with character-based RNN models using shorter sequences: these lagged behind our long-sequence CNN models but performed significantly better than those RNNs trained on longer sequences. This suggest that RNNs could be improved by more sophisticated optimization techniques such as curriculum learning. Cutoff k-NN Baseline (%) char-CNN (%) word-CNN (%) def-CNN-LSTM (%) def-CNN (%) def+char-CNN (%) 16 674 (24.6) 687 (25.1) 709 (25.9) 644 (23.5) 734 (26.8) 835 (30.5) 32 1081 (39.4) 1028 (37.5) 1063 (38.8) 924 (33.7) 1093 (39.9) 1218 (44.4) 64 1399 (51) 1295 (47.2) 1355 (49.4) 1196 (43.6) 1381 (50.4) 1470 (53.6) 128 1612 (58.8) 1534 (55.9) 1552 (56.6) 1401 (51.1) 1617 (59) 1695 (61.8) 256 1709 (62.3) 1656 (60.4) 1635 (59.6) 1519 (55.4) 1708 (62.3) 1780 (64.9) 512 1762 (64.3) 1711 (62.4) 1712 (62.4) 1593 (58.1) 1780 (64.9) 1830 (66.7) 1024 1786 (65.1) 1762 (64.3) 1755 (64) 1647 (60.1) 1822 (66.4) 1862 (67.9) Table 1: Results of ATP premise selection experiments with hard negative mining on a test set of 2,742 theorems. Each entry is the number (%) of theorems proved by E prover using that particular model to rank the premises. The union of def-CNN and char-CNN proves 69.8% of the test set, while the union of the def-CNN and k-NN proves 74.25%. This means that the neural network predictions are more complementary to the k-NN predictions than to other neural models. The union of all methods proves 2218 theorems (80.9%) and just the neural models prove 2151 (78.4%). 7 Conclusions In this work we provide evidence that even simple neural models can compete with hand-engineered features for premise selection, helping to find many new proofs. This translates to real gains in 7 (a) Jaccard similarities between proved sets of conjectures across models. Each of the neural network model prediction are more like each other than those of the k-NN baseline. Model Test min average relative rank char-CNN 0.0585 word-CNN 0.06 def-CNN-LSTM 0.0605 def-CNN 0.0575 (b) Best sustained test results obtained by the above models. Lower values are better. This was monitored continuously during training on a holdout set with 400 theorems, using all true positive premises and 128 randomly selected negatives. In this setup, the lowest attainable max average relative rank with perfect predictions is 0.051. automatic theorem proving. Despite these encouraging results, our models are relatively shallow networks with inherent limitations to representational power and are incapable of capturing high level properties of mathematical statements. We believe theorem proving is a challenging and important domain for deep learning methods, and that more sophisticated optimization techniques and training methodologies will prove more useful than in less structured domains. 8 Acknowledgments We would like to thank Cezary Kaliszyk for providing us with an improved baseline model. Also many thanks go to the Google Brain team for their generous help with the training infrastructure. We would like to thank Quoc Le for useful discussions on the topic and to Sergio Guadarrama for his help with TensorFlow-slim. References [1] M. Abadi, A. Agarwal, P. Barham, E. Brevdo, Z. Chen, C. Citro, G. S. Corrado, A. Davis, J. Dean, M. Devin, S. Ghemawat, I. Goodfellow, A. Harp, G. Irving, M. Isard, Y. Jia, R. Jozefowicz, L. Kaiser, M. Kudlur, J. Levenberg, D. Mané, R. Monga, S. Moore, D. Murray, C. Olah, M. Schuster, J. Shlens, B. Steiner, I. Sutskever, K. Talwar, P. Tucker, V. Vanhoucke, V. Vasudevan, F. Viégas, O. Vinyals, P. Warden, M. Wattenberg, M. Wicke, Y. Yu, and X. Zheng. TensorFlow: Large-scale machine learning on heterogeneous systems, 2015. Software available from tensorflow.org. [2] G. Bancerek and P. Rudnicki. A Compendium of Continuous Lattices in MIZAR. J. Autom. Reasoning, 29(3-4):189–224, 2002. [3] P. Baudiš, J. Pichl, T. Vyskoˇcil, and J. Šedivý. Sentence pair scoring: Towards unified framework for text comprehension. arXiv preprint arXiv:1603.06127, 2016. [4] J. C. Blanchette, C. Kaliszyk, L. C. Paulson, and J. Urban. Hammering towards QED. J. Formalized Reasoning, 9(1):101–148, 2016. [5] F. Chollet. Keras. https://github.com/fchollet/keras, 2015. [6] J. Chung, C. Gulcehre, K. Cho, and Y. Bengio. Gated feedback recurrent neural networks. arXiv preprint arXiv:1502.02367, 2015. [7] The Coq Proof Assistant. http://coq.inria.fr. [8] A. M. Dai and Q. V. Le. Semi-supervised sequence learning. In Advances in Neural Information Processing Systems, pages 3061–3069, 2015. [9] N. de Bruijn. The mathematical language AUTOMATH, its usage, and some of its extensions. In M. Laudet, editor, Proceedings of the Symposium on Automatic Demonstration, pages 29–61, Versailles, France, Dec. 1968. Springer-Verlag LNM 125. [10] X. Glorot and Y. Bengio. Understanding the difficulty of training deep feedforward neural networks. In International conference on artificial intelligence and statistics, pages 249–256, 2010. [11] G. Gonthier. The four colour theorem: Engineering of a formal proof. In D. Kapur, editor, Computer Mathematics, 8th Asian Symposium, ASCM 2007, Singapore, December 15-17, 2007. Revised and Invited Papers, volume 5081 of Lecture Notes in Computer Science, page 333. Springer, 2007. 8 [12] G. Gonthier, A. Asperti, J. Avigad, Y. Bertot, C. Cohen, F. Garillot, S. L. Roux, A. Mahboubi, R. O’Connor, S. O. Biha, I. Pasca, L. Rideau, A. Solovyev, E. Tassi, and L. Théry. A machine-checked proof of the Odd Order Theorem. In S. Blazy, C. Paulin-Mohring, and D. Pichardie, editors, ITP, volume 7998 of LNCS, pages 163–179. Springer, 2013. [13] A. Grabowski, A. Korniłowicz, and A. Naumowicz. Mizar in a nutshell. J. Formalized Reasoning, 3(2):153–245, 2010. [14] T. C. Hales, M. Adams, G. Bauer, D. T. Dang, J. Harrison, T. L. Hoang, C. Kaliszyk, V. Magron, S. McLaughlin, T. T. Nguyen, T. Q. Nguyen, T. Nipkow, S. Obua, J. Pleso, J. Rute, A. Solovyev, A. H. T. Ta, T. N. Tran, D. T. Trieu, J. Urban, K. K. Vu, and R. Zumkeller. A formal proof of the Kepler conjecture. CoRR, abs/1501.02155, 2015. [15] J. Harrison. HOL Light: A tutorial introduction. In M. K. Srivas and A. J. Camilleri, editors, FMCAD, volume 1166 of LNCS, pages 265–269. Springer, 1996. [16] J. Harrison, J. Urban, and F. Wiedijk. History of interactive theorem proving. In J. H. Siekmann, editor, Computational Logic, volume 9 of Handbook of the History of Logic, pages 135 – 214. North-Holland, 2014. [17] S. Hochreiter and J. Schmidhuber. Long short-term memory. Neural computation, 9(8):1735–1780, 1997. [18] Ł. Kaiser and I. Sutskever. Neural gpus learn algorithms. arXiv preprint arXiv:1511.08228, 2015. [19] C. Kaliszyk and J. Urban. Stronger automation for Flyspeck by feature weighting and strategy evolution. In J. C. Blanchette and J. Urban, editors, PxTP 2013, volume 14 of EPiC Series, pages 87–95. EasyChair, 2013. [20] C. Kaliszyk and J. Urban. Learning-assisted automated reasoning with Flyspeck. J. Autom. Reasoning, 53(2):173–213, 2014. [21] C. Kaliszyk and J. Urban. MizAR 40 for Mizar 40. J. Autom. Reasoning, 55(3):245–256, 2015. [22] C. Kaliszyk, J. Urban, and J. Vyskocil. Efficient semantic features for automated reasoning over large theories. In Q. Yang and M. Wooldridge, editors, Proceedings of the Twenty-Fourth International Joint Conference on Artificial Intelligence, IJCAI 2015, Buenos Aires, Argentina, July 25-31, 2015, pages 3084–3090. AAAI Press, 2015. [23] M. Kaufmann and J. S. Moore. An ACL2 tutorial. In Mohamed et al. [29], pages 17–21. [24] D. Kingma and J. Ba. Adam: A method for stochastic optimization. arXiv preprint arXiv:1412.6980, 2014. [25] G. Klein, J. Andronick, K. Elphinstone, G. Heiser, D. Cock, P. Derrin, D. Elkaduwe, K. Engelhardt, R. Kolanski, M. Norrish, T. Sewell, H. Tuch, and S. Winwood. seL4: formal verification of an operatingsystem kernel. Commun. ACM, 53(6):107–115, 2010. [26] D. Kuehlwein and J. Urban. Learning from multiple proofs: First experiments. In P. Fontaine, R. A. Schmidt, and S. Schulz, editors, PAAR-2012, volume 21 of EPiC Series, pages 82–94. EasyChair, 2013. [27] X. Leroy. Formal verification of a realistic compiler. Commun. ACM, 52(7):107–115, 2009. [28] T. Mikolov, M. Karafiát, L. Burget, J. Cernock`y, and S. Khudanpur. Recurrent neural network based language model. In INTERSPEECH, volume 2, page 3, 2010. [29] O. A. Mohamed, C. A. Muñoz, and S. Tahar, editors. Theorem Proving in Higher Order Logics, 21st International Conference, TPHOLs 2008, Montreal, Canada, August 18-21, 2008. Proceedings, volume 5170 of LNCS. Springer, 2008. [30] B. T. Polyak and A. B. Juditsky. Acceleration of stochastic approximation by averaging. SIAM Journal on Control and Optimization, 30(4):838–855, 1992. [31] J. A. Robinson and A. Voronkov, editors. Handbook of Automated Reasoning (in 2 volumes). Elsevier and MIT Press, 2001. [32] S. Schulz. E - A Brainiac Theorem Prover. AI Commun., 15(2-3):111–126, 2002. [33] S. Sukhbaatar, J. Weston, R. Fergus, et al. End-to-end memory networks. In Advances in Neural Information Processing Systems, pages 2431–2439, 2015. [34] J. Urban. MPTP 0.2: Design, implementation, and initial experiments. JAR, 37(1-2):21–43, 2006. [35] J. Urban and J. Vyskoˇcil. Theorem proving in large formal mathematics as an emerging AI field. In M. P. Bonacina and M. E. Stickel, editors, Automated Reasoning and Mathematics: Essays in Memory of William McCune, volume 7788 of LNAI, pages 240–257. Springer, 2013. [36] O. Vinyals and Q. Le. A neural conversational model. arXiv preprint arXiv:1506.05869, 2015. [37] M. Wenzel, L. C. Paulson, and T. Nipkow. The Isabelle framework. In Mohamed et al. [29], pages 33–38. [38] W. Zaremba and I. Sutskever. Learning to execute. arXiv preprint arXiv:1410.4615, 2014. 9 | 2016 | 535 |
6,478 | A Pseudo-Bayesian Algorithm for Robust PCA Tae-Hyun Oh1 Yasuyuki Matsushita2 In So Kweon1 David Wipf3∗ 1Electrical Engineering, KAIST, Daejeon, South Korea 2Multimedia Engineering, Osaka University, Osaka, Japan 3Microsoft Research, Beijing, China thoh.kaist.ac.kr@gmail.com yasumat@ist.osaka-u.ac.jp iskweon@kaist.ac.kr davidwip@microsoft.com Abstract Commonly used in many applications, robust PCA represents an algorithmic attempt to reduce the sensitivity of classical PCA to outliers. The basic idea is to learn a decomposition of some data matrix of interest into low rank and sparse components, the latter representing unwanted outliers. Although the resulting problem is typically NP-hard, convex relaxations provide a computationally-expedient alternative with theoretical support. However, in practical regimes performance guarantees break down and a variety of non-convex alternatives, including Bayesian-inspired models, have been proposed to boost estimation quality. Unfortunately though, without additional a priori knowledge none of these methods can significantly expand the critical operational range such that exact principal subspace recovery is possible. Into this mix we propose a novel pseudo-Bayesian algorithm that explicitly compensates for design weaknesses in many existing non-convex approaches leading to state-of-the-art performance with a sound analytical foundation. 1 Introduction It is now well-established that principal component analysis (PCA) is quite sensitive to outliers, with even a single corrupted data element carrying the potential of grossly biasing the recovered principal subspace. This is particularly true in many relevant applications that rely heavily on lowdimensional representations [8, 13, 27, 33, 22]. Mathematically, such outliers can be described by the measurement model Y = Z + E, where Y ∈Rn×m is an observed data matrix, Z = AB⊤is a low-rank component with principal subspace equal to span[A], and E is a matrix of unknown sparse corruptions with arbitrary amplitudes. Ideally, we would like to remove the effects of E, which would then allow regular PCA to be applied to Z for obtaining principal components devoid of unwanted bias. For this purpose, robust PCA (RPCA) algorithms have recently been motivated by the optimization problem minZ,E max(n, m) · rank[Z] + ∥E∥0 s.t. Y = Z + E, (1) where ∥· ∥0 denotes the ℓ0 matrix norm (meaning the number of nonzero matrix elements) and the max(n, m) multiplier ensures that both rank and sparsity terms scale between 0 and nm, reflecting a priori agnosticism about their relative contributions to Y. The basic idea is that if {Z∗, E∗} minimizes (1), then Z∗is likely to represent the original uncorrupted data. As a point of reference, if we somehow knew a priori which elements of E were zero (i.e., no gross corruptions), then (1) could be effectively reduced to the much simpler matrix completion (MC) problem [5] minZ rank[Z] s.t. yij = zij, ∀(i, j) ∈Ω, (2) where Ωdenotes the set of indices corresponding with zero-valued elements in E. A major challenge with RPCA is that an accurate estimate of the support set Ωcan be elusive. ∗This work was done while the first author was an intern at Microsoft Research, Beijing. The first and third authors were supported by the NRF of Korea grant funded by the Korea government, MSIP (No. 2010-0028680). The second author was partly supported by JSPS KAKENHI Grant Number JP16H01732. 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. Unfortunately, solving (1) is non-convex, discontinuous, and NP-hard in general. Therefore, the convex surrogate referred to as principal component pursuit (PCP) minZ,E p max(n, m) · ∥Z∥∗+ ∥E∥1 s.t. Y = Z + E (3) is often adopted, where ∥· ∥∗denotes the nuclear norm and ∥· ∥1 is the ℓ1 matrix norm. These represent the tightest convex relaxations of the rank and ℓ0 norm functions respectively. Several theoretical results quantify technical conditions whereby the solutions of (1) and (3) are actually equivalent [4, 6]. However, these conditions are highly restrictive and do not provably hold in practical situations of interest such as face clustering [10], motion segmentation [10], high dynamic range imaging [22] or background subtraction [4]. Moreover, both the nuclear and ℓ1 norms are sensitive to data variances, often over-shrinking large singular values of Z or coefficients in E [11]. All of this motivates stronger approaches to approximating (1). In Section 2 we review existing alternatives, including both non-convex and probabilistic approaches; however, we argue that none of these can significantly outperform PCP in terms of principal subspace recovery in important, representative experimental settings devoid of prior knowledge (e.g., true signal distributions, outlier locations, rank, etc.). We then derive a new pseudo-Bayesian algorithm in Section 3 that has been tailored to conform with principled overarching design criteria. By ‘pseudo’, we mean an algorithm inspired by Bayesian modeling conventions, but with special modifications that deviate from the original probabilistic script for reasons related to estimation quality and computational efficiency. Next, Section 4 examines relevant theoretical properties, explicitly accounting for all approximations involved, while Section 5 provides empirical validations. Proofs and other technical details are deferred to [23]. Our high-level contributions can be summarized as follows: - We derive a new pseudo-Bayesian RPCA algorithm with efficient ADMM subroutine. - While provable recovery guarantees are absent for non-convex RPCA algorithms, we nonetheless quantify how our pseudo-Bayesian design choices lead to a desirable energy landscape. In particular, we show that although any outlier support pattern will represent an inescapable local minima of (1) (or a broad class of functions that mimic (1)), our proposal can simultaneously retain the correct global optimum while eradicating at least some of the suboptimal minima associated with incorrect outlier location estimates. - We empirically demonstrate improved performance over state-of-the-art algorithms (including PCP) in terms of standard phase transition plots with a dramatically expanded success region. Quite surprisingly, our algorithm can even outperform convex matrix completion (MC) despite the fact that the latter is provided with perfect knowledge of which entries are not corrupted, suggesting that robust outlier support pattern estimation is indeed directly facilitated by our model. 2 Recent Work The vast majority of algorithms for solving (1) either implicitly or explicitly attempt to solve a problem of the form minZ,E f1(Z) + P i,j f2(eij) s.t. Y = Z + E, (4) where f1 and f2 are penalty functions that favor minimal rank and sparsity respectively. When f1 is the nuclear norm (scaled appropriately) and f2(e)=|e|, then (4) reduces to (3). Methods differ however by replacing f1 and f2 with non-convex alternatives, such as generalized Huber functions [7] or Schatten ℓp quasi-norms with p < 1 [18, 19]. When applied to the singular values of Z and elements of E respectively, these selections enact stronger enforcement of minimal rank and sparsity. If prior knowledge of the true rank of Z is available, a truncated nuclear norm approach (TNN-RPCA) has also been proposed [24]. Further divergences follow from the spectrum of optimization schemes applied to different objectives, such as the alternating directions method of multipliers (ADMM) algorithm [3] or iteratively reweighted least squares (IRLS) [18]. With all of these methods, we may consider relaxing the strict equality constraint to the regularized form minZ,E 1 λ∥Y −Z −E∥2 F + f1(Z) + P i,j f2(eij), (5) where λ > 0 is a trade-off parameter. This has inspired a number of competing Bayesian formulations, which typically proceed as follows. Let p(Y|Z, E) ∝ exp −1 2λ∥Y −Z −E∥2 F (6) 2 define a likelihood function, where λ represents a non-negative variance parameter assumed to be known.2 Hierarchical prior distributions are then assigned to Z and E to encourage minimal rank and strong sparsity, respectively. For the latter, the most common choice is the Gaussian scale-mixture (GSM) defined hierarchically by p(E|Γ) = Q i,j p(eij|γij), p(eij|γij) ∝exp h − e2 ij 2γij i , with hyper prior p(γ−1 ij ) ∝γ1−a ij exp[ −b γij ], (7) where Γ is a matrix of non-negative variances and a, b≥0 are fixed parameters. Note that when these values are small, the resulting distribution over each eij (obtained by marginalizing over the respective γij) is heavy-tailed with a sharp peak at zero, the defining characteristics of sparse priors. For the prior on Z, Bayesian methods have somewhat broader distinctions. In particular, a number of methods explicitly assume that Z=AB⊤and specify GSM priors on A and B [1, 9, 15, 30]. For example, variational Bayesian RPCA (VB-RPCA) [1] assumes p(A|θ)∝exp −tr Adiag[θ]−1A⊤ , where θ is a non-negative variance vector. An equivalent prior is used for p(B|θ) with a shared value of θ. This model also applies the prior p(θ) = Q i p(θi) with p(θi) defined for consistency with p(γ−1 ij ) in (7). Low rank solutions are favored via the same mechanism as described above for sparsity, but only the sparse variance prior is applied to columns of A and B, effectively pruning them from the model if the associated θi is small. Given the above, the joint distribution is p(Y, A, B, E, Γ, θ) = p(Y|A, B, E)p(E|Γ)p(A|θ)p(B|θ)p(Γ)p(θ). (8) Full Bayesian inference with this is intractable, hence a common variational Bayesian (VB) meanfield approximation is applied [1, 2]. The basic idea is to obtain a tractable approximate factorial posterior distribution by solving minq(Φ) KL [q(Φ)||p(A, B, E, Γ, θ|Y)] , (9) where q(Φ) ≜q(A)q(B)q(E)q(Γ)q(θ), each q represents an arbitrary probability distribution, and KL[·||·] denotes the Kullback-Leibler divergence between two distributions. This can be accomplished via coordinate descent minimization over each respective q distribution while holding the others fixed. Final estimates of Z and E are obtained by the means of q(A), q(B), and q(E) upon convergence. A related hierarchical model is used in [9, 30], but MCMC sampling techniques are used for full Bayesian inference RPCA (FB-RPCA) at the expense of considerable computational complexity and multiple tuning parameters. An alternative empirical Bayesian algorithm (EB-RPCA) is described in [31]. In addition to the likelihood function (6) and prior from (7), this method assumes a direct Gaussian prior on Z given by p(Z|Ψ) ∝exp −1 2tr Z⊤Ψ−1Z , (10) where Ψ is a symmetric and positive definite matrix.3 Inference is accomplished via an empirical Bayesian approach [20]. The basic idea is to marginalize out the unknown Z and E and solve maxΨ,Γ RR p(Y|Z, E)p(Z|Ψ)p(E|Γ)dZdE (11) using an EM-like algorithm. Once we have an optimal {Ψ∗, Γ∗}, we then compute the posterior mean of p(Z, E|Y, Ψ∗, Γ∗) which is available in closed-form. Finally, a recent class of methods has been derived around the concept of approximate message passing, AMP-RPCA [26], which applies Gaussian priors to the factors A and B and infers posterior estimates by loopy belief propagation [21]. In our experiments (see [23]) we found AMP-RPCA to be quite sensitive to data deviating from these distributions. 3 A New Pseudo-Bayesian Algorithm As it turns out, it is quite difficult to derive a fully Bayesian model, or some tight variational/empirical approximation, that leads to an efficient algorithm capable of consistently outperforming the original convex PCP, at least in the absence of additional, exploitable prior knowledge. It is here that we adopt 2Actually many methods attempt to learn this parameter from data, but we avoid this consideration for simplicity. As well, for subtle reasons such learning is sometimes not even identifiable in the strict statistical sense. 3Note that in [31] this method is motivated from an entirely different variational perspective anchored in convex analysis; however, the cost function that ultimately emerges is equivalent to what follows with these priors. 3 a pseudo-Bayesian approach, by which we mean that a Bayesian-inspired cost function will be altered using manipulations that, although not consistent with any original Bayesian model, nonetheless produce desirable attributes relevant to blindly solving (1). In some sense however, we view this as a strength, because the final model analysis presented later in Section 4 does not rely on any presumed validity of the underlying prior assumptions, but rather on explicit properties of the objective that emerges, including all assumptions and approximation involved. Basic Model: We begin with the same likelihood function from (6), noting that in the limit as λ →0 this will enforce the constraint set from (1). We also adopt the same prior on E given by (7) above and used in [1] and [31], but we need not assume any additional hyperprior on Γ. In contrast, for the prior on Z our method diverges, and we define the Gaussian p(Z|Ψr, Ψc) ∝exp h −1 2⃗z⊤(Ψr ⊗I + I ⊗Ψc)−1 ⃗z i , (12) where ⃗z≜vec[Z] is the column-wise vectorization of Z, ⊗denotes the Kronecker product, and Ψc∈Rn×n and Ψr∈Rm×m are positive semi-definite, symmetric matrices.4 Here Ψc can be viewed as applying a column-wise covariance factor, and Ψr a row-wise one. Note that if Ψr=0, then this prior collapses to (10); however, by including Ψr we can retain symmetry in our model, or invariance to inference using either Y or Y⊤. Related priors can also be used to improve the performance of affine rank minimization problems [34]. We apply the empirical Bayesian procedure from (11); the resulting convolution of Gaussians integral [2] can be computed in closed-form. After applying −2 log[·] transformation, this is equivalent to minimizing L(Ψr, Ψc, Γ) = ⃗y⊤Σ−1 y ⃗y + log |Σy|, where Σy ≜Ψr ⊗I + I ⊗Ψc + ¯Γ + λI, (13) and ¯Γ ≜diag[⃗γ]. Note that for even reasonably sized problems Σy ∈Rnm×nm will be huge, and consequently we will require certain approximations to produce affordable update rules. Fortunately this can be accomplished while simultaneously retaining a principled objective function capable of outperforming existing methods. Pseudo-Bayesian Objective: We first modify (13) to give L(Ψr, Ψc, Γ) = ⃗y⊤Σ−1 y ⃗y + P j log Ψc + 1 2Γ·j + λ 2 I + P i log Ψr + 1 2Γi· + λ 2 I , (14) where Γ·j≜diag[γ·j] and γ·j represents the j-th column of Γ. Similarly we define Γi·≜diag[γi·] with γi· the i-th row of Γ. This new cost is nothing more than (13) but with the log | · | term split in half producing a lower bound by Jensen’s inequality; the Kronecker product can naturally be dissolved under these conditions. Additionally, (14) represents a departure from our original Bayesian model in that there is no longer any direct empirical Bayesian or VB formulation that would lead to (14). Note that although this modification cannot be justified on strictly probabilistic terms, we will see shortly that it nonetheless still represents a viable cost function in the abstract sense, and lends itself to increased computational efficiency. The latter is an immediate effect of the drastically reduced dimensionality of the matrices inside the determinant. Henceforth (14) will represent the cost function that we seek to minimize; relevant properties will be handled in Section 4. We emphasize that all subsequent analysis is based directly upon (14), and therefore already accounts for the approximation step in advancing from (13). This is unlike other Bayesian model justifications relying on the legitimacy of the original full model, and yet then adopt various approximations that may completely change the problem. Update Rules: Common to many empirical Bayesian and VB approaches, our basic optimization strategy involves iteratively optimizing upper bounds on (14) in the spirit of majorizationminimization [12]. At a high level, our goal will be to apply bounds which separate Ψc, Ψr, and Γ into terms of the general form log |X| + tr[AX−1], the reason being that this expression has a simple global minimum over X given by X=A. Therefore the strategy will be to update the bound (parameterized by some matrix A), and then update the parameters of interest X. Using standard conjugate duality relationships and variational bounding techniques [14][Chapter 4], it follows after some linear algebra that 4Technically the Kronecker sum Ψr⊗I + I⊗Ψc must be positive definite for the inverse in (12) to be defined. However, we can accommodate the semi-definite case using the following convention. Without loss of generality assume that Ψr⊗I + I⊗Ψc = RR⊤for some matrix R. We then qualify that p(Z|Ψr, Ψc) = 0 if ⃗z /∈span[R], and p(Z|Ψr, Ψc) ∝exp[−1 2⃗z⊤(R⊤)†R†⃗z] otherwise. 4 ⃗y⊤Σ−1 y ⃗y ≤ 1 λ∥Y −Z −E∥2 F + P i,j e2 ij γij + ⃗z⊤(Ψr ⊗I + I ⊗Ψc)−1 ⃗z (15) for all Z and E. For fixed values of Ψr, Ψc, and Γ we optimize this quadratic bound to obtain revised estimates for Z and E, noting that exact equality in (15) is possible via the closed-form solution ⃗z = (Ψr ⊗I + I ⊗Ψc) Σ−1 y ⃗y, ⃗e = ¯ΓΣ−1 y ⃗y. (16) In large practical problems, (16) may become expensive to compute directly because of the high dimensional inverse involved. However, we may still find the optimum efficiently by an ADMM procedure described in [23]. We can also further bound the righthand side of (15) using Jensen’s inequality as ⃗z⊤(Ψr ⊗I + I ⊗Ψc)−1 ⃗z ≤tr h Z⊤ZΨ−1 r + ZZ⊤Ψ−1 c i . (17) Along with (15) this implies that for fixed values of Z and E we can obtain an upper bound which only depends on Ψr, Ψc, and Γ in a decoupled or separable fashion. For the log | · | terms in (14), we also derive convenient upper bounds using determinant identities and a first-order approximation, the goal being to find a representation that plays well with the previous decoupled bound for optimization purposes. Again using conjugate duality relationships, we can form the bound log Ψc + 1 2Γ·j + λ 2 I ≡ log |Ψc| + log |Γ·j| + log |W(Ψc, Γ·j)| ≤ log |Ψc| + log |Γ·j| + tr h (∇j Ψ−1 c )⊤Ψ−1 c i + (∇c Γ−1 ·j )⊤γ−1 ·j +C, (18) where the inverse γ−1 ·j is understood to apply element-wise, and W(Ψc, Γ·j) is defined as W(Ψc, Γ·j) ≜1 2λ 2I √ 2I √ 2I I + Ψ−1 c 0 0 Γ−1 ·j . (19) Additionally, C is a standard constant, which accompanies the first-order approximation to guarantee that the upper bound is tangent to the underlying cost function; however, its exact value is irrelevant for optimization purposes. Finally, the requisite gradients are defined as ∇c Γ−1 ·j ≜∂W (Ψc,Γ·j) ∂Γ−1 ·j = diag[Γ·j −1 2Γ·j(Sj c)−1Γ·j], ∇j Ψ−1 c ≜∂W (Ψc,Γ·j) ∂Ψ −1 c = Ψc −Ψc(Sj c)−1Ψc, (20) where Sj c ≜Ψc + 1 2Γ·j + λ 2 I. Analogous bounds can be derived for the log Ψr + 1 2Γi· + λ 2 I terms in (14). These bounds are principally useful because all Ψc, Ψr, Γ·j, and Γi· factors have been decoupled. Consequently, with Z, E, and all the relevant gradients fixed, we can separately combine Ψc-, Ψr-, and Γ-dependent terms from the bounds and then optimize independently. For example, combining terms from (17) and (18) involving Ψc for all j, this requires solving min Ψc m log |Ψc| + tr hP j(∇j Ψ−1 c )⊤Ψ−1 c + ZZ⊤Ψ−1 c i . (21) Analogous cost functions emerge for Ψr and Γ. All three problems have closed-form optimal solutions given by Ψc = 1 m hP j ∇j ⊤ Ψ−1 c + ZZ⊤i , Ψr = 1 n hP i ∇i ⊤ Ψ−1 r + Z⊤Z i , ⃗γ = ⃗z2 + ⃗uc + ⃗ur, (22) where the squaring operator is applied element-wise to ⃗z, ⃗uc ≜[∇c Γ−1 ·1 ; . . . ; ∇c Γ−1 ·m], and analogously for ⃗ur. One interesting aspect of (22) is that it forces Ψc ⪰ 1 mZZ⊤and Ψr ⪰ 1 nZ⊤Z, thus maintaining a balancing symmetry and preventing one or the other from possibly converging towards zero. This is another desirable consequence of using the bound in (17). To finalize then, the proposed pipeline, which we henceforth refer to as pseudo-Bayesian RPCA (PB-RPCA), involves the steps shown under Algorithm 1 in [23]. These can be implemented in such a way that the complexity is linear in max(n, m) and cubic in min(n, m). 5 4 Analysis of the PB-RPCA Objective On the surface it may appear that the PB-RPCA objective (14) represents a rather circuitous route to solving (1), with no obvious advantage over the convex PCP relaxation from (3), or any other approach for that matter. However quite surprisingly, we prove in [23] that by simply replacing the log | · | matrix operators in (14) with tr[·], the resulting function collapses exactly to convex PCP. So what at first appear as distant cousins are actually quite closely related objectives. Of course our work is still in front of us to explain why log | · |, and therefore the PB-RPCA objective by association, might display any particular advantage. This leads us to considerations of relative concavity, non-separability, and symmetry as described below in turn. Relative Concavity: Although both log | · | and tr[·] are concave non-decreasing functions of the singular values of symmetric positive definite matrices, and hence favor both sparsity of Γ and minimal rank of Ψr or Ψc, the former is far more strongly concave (in the sense of relative concavity described in [25]). In this respect we may expect that log | · | is less likely to over-shrink large values [11]. Moreover, applying a concave non-decreasing penalty to elements of Γ favors a sparse estimate, which in turn transfers this sparsity directly to E by virtue of the left multiplication by ¯Γ in (16). Likewise for the singular values of Ψc and Ψr. Non-Separability: While potentially desirable, the relative concavity distinction described above is certainly not sufficient to motivate why PB-RPCA might represent an effective RPCA approach, especially given the breadth of non-convex alternatives already in the literature. However, a much stronger argument can be made by exposing a fundamental limitation of all RPCA methods (convex or otherwise) that rely on minimization of generic penalties in the separable or additive form of (4). For this purpose, let Ωdenote a set of indices that correspond with zero-valued elements in E, such that EΩ= 0 while all other elements of E are arbitrary nonzeros (it can equally be viewed as the complement of the support of E). In the case of MC, Ωwould also represent the set of observed matrix elements. We then have the following: Proposition 1. To guarantee that (4) has the same global optimum as (1) for all Y where a unique solution exists, it follows that f1 and f2 must be non-convex and no feasible descent direction can ever remove an index from or decrease the cardinality of Ω. In [31] it has been shown that, under similar conditions, the gradient in a feasible direction at any zero-valued element of E must be infinite to guarantee a matching global optimum, from which this result naturally follows. The ramifications of this proposition are profound if we ever wish to produce a version of RPCA that can mimic the desirable behavior of much simpler MC problems with known support, or at least radically improve upon PCP with unknown outlier support. In words, Proposition 1 implies that under the stated global-optimality preserving conditions, if any element of E converges to zero during optimization with an arbitrary descent algorithm, it will remain anchored at zero until the end. Consequently, if the algorithm prematurely errs in setting the wrong element to zero, meaning the wrong support pattern has been inferred at any time during an optimization trajectory, it is impossible to ever recover, a problem naturally side-stepped by MC where the support is effectively known. Therefore, the adoption of separable penalty functions can be quite constraining and they are unlikely to produce sufficiently reliable support recovery. But how does this relate to PB-RPCA? Our algorithm maintains a decidedly non-separable penalty function on Ψc, Ψr, and Γ, which directly transfers to an implicit, non-separable regularizer over Z and E when viewed through the dual-space framework from [32].5 By this we mean a penalty f(Z, E)̸=f1(Z)+f2(E) for any functions f1 and f2, and with Z fixed, we have f(Z, E)̸=P i,j fij(eij) for any set of functions {fij}. We now examine the consequences. Let Ωnow denote a set of indices that correspond with zerovalued elements in Γ, which translates into an equivalent support set for Z via (16). This then leads to quantifiable benefits: Proposition 2. The following properties hold w.r.t. the PB-RPCA objective (assuming n = m for simplicity): • Assume that a unique global solution to (1) exists such that either rank[Z]+maxj ∥e·j∥0<n or rank[Z]+maxi ∥ei·∥0<n. Additionally, let {Ψ∗ c, Ψ∗ r, Γ∗} denote a globally minimizing solution to (14) and {Z∗,E∗} the corresponding values of Z and E computed using (16). Then in the limit λ→0, Z∗and E∗globally minimize (1). 5Even though this penalty function is not available in closed-form, non-separability is nonetheless enforced via the linkage between Ψc, Ψr, and Γ in the log | · | operator. 6 Rank ratio 0.05 0.1 0.15 0.2 0.25 0.3 0.35 0.4 Outlier ratio 0.2 0.4 0.6 (a) CVX–PCP Rank ratio 0.05 0.1 0.15 0.2 0.25 0.3 0.35 0.4 Outlier ratio 0.2 0.4 0.6 (b) IRLS–RPCA Rank ratio 0.05 0.1 0.15 0.2 0.25 0.3 0.35 0.4 Outlier ratio 0.2 0.4 0.6 (c) VB–RPCA Rank ratio 0.05 0.1 0.15 0.2 0.25 0.3 0.35 0.4 Outlier ratio 0.2 0.4 0.6 (d) PB–RPCA w/o sym. Rank ratio Outlier ratio 0.05 0.1 0.15 0.2 0.25 0.3 0.35 0.4 0.1 0.2 0.3 0.4 0.5 0 0.2 0.4 0.6 0.8 1 Rank ratio 0.05 0.1 0.15 0.2 0.25 0.3 0.35 0.4 Outlier ratio 0.2 0.4 0.6 [Known outlier location] (e) CVX–MC Rank ratio 0.05 0.1 0.15 0.2 0.25 0.3 0.35 0.4 Outlier ratio 0.2 0.4 0.6 [Known rank] (f) TNN–RPCA Rank ratio 0.05 0.1 0.15 0.2 0.25 0.3 0.35 0.4 Outlier ratio 0.2 0.4 0.6 (g) FB–RPCA Rank ratio 0.05 0.1 0.15 0.2 0.25 0.3 0.35 0.4 Outlier ratio 0.2 0.4 0.6 (h) PB–RPCA (Proposed) Rank ratio Outlier ratio 0.05 0.1 0.15 0.2 0.25 0.3 0.35 0.4 0.1 0.2 0.3 0.4 0.5 0 0.2 0.4 0.6 0.8 1 Figure 1: Phase transition over outlier (y-axis) and rank (x-axis) ratio variations. Here CVX-MC and TNN-RPCA maintain advantages of exactly known outlier support pattern and true rank respectively. • Assume that Y has no entries identically equal to zero.6 Then for any arbitrary Ω, there will always exist a range of Ψc and Ψr values such that for any Γ consistent with Ωwe are not at a locally minimizing solution to (14), meaning there exists a feasible descent direction whereby elements of Γ can escape from zero. A couple important comments are worth stating regarding this result. First, the rank and row/columnsparsity requirements are extremely mild. In fact, any minimum of (1) will be such that rank[Z] + maxj ∥e·j∥0 ≤n and rank[Z] + maxi ∥ei·∥0 ≤m, regardless of Y. Secondly, unlike any separable penalty function (4) that retains the correct global optimal as (1), Proposition 2 implies that (14) need not be locally minimized by every possible support pattern for outlier locations. Consequently, premature convergence to suboptimal supports need not disrupt trajectories towards the global solution to the extent that (4) may be obstructed. Moreover, beyond algorithms that explicitly adopt separable penalties (the vast majority), some existing Bayesian approaches may implicitly default to (4). For example, as shown in [23], the mean-field factorizations adopted by VB-RPCA actually allow the underlying free energy objective to be expressible as (4) for some f1 and f2. Symmetry: Without the introduction of symmetry via our pseudo-Bayesian proposal (meaning either Ψc or Ψr is forced to zero), then PB-RPCA collapses to something like EB-RPCA, which depends heavily on whether Y or Y⊤is provided as input and penalizes column- and row-spaces asymmetrically. In this regime it can be shown that the analogous requirement to replicate Proposition 2 becomes more stringent, namely we must assume the asymmetric condition rank[Z] + maxj ∥e·j∥0 < n. Thus the symmetric cost of PB-RPCA of allows us to relax this column-wise restriction provided a rowwise alternative holds (and vice versa), allowing the PB-RPCA objective (14) to match the global optimum of our original problem from (1) under broader conditions. In closing this section, we reiterate that all of our analysis and conclusions are based on (14), after the stated approximations. Therefore we need not rely on the plausibility of the original Bayesian starting point from Section 3 nor the tightness of subsequent approximations for justification; rather (14) can be viewed as a principled stand-alone objective for RPCA regardless of its origins. Moreover, it represents the first approach satisfying the relative concavity, non-separability, and symmetry properties described above, which can loosely be viewed as necessary, but not sufficient design criteria for an optimal RPCA objective. 5 Experiments To examine significant factors that influence the ability to solve (1), we first evaluate the relative performance of PB-RPCA estimating random simulated subspaces from corrupted measurements, the standard benchmark. Later we present subspace clustering results for motion segmentation as a practical application. Additional experiments and a photometric stereo example are provided in [23]. Phase Transition Graphs: We compare our method against existing RPCA methods: PCP [16], TNN [24], IRLS [18], VB [1], and FB [9]. We also include results using PB-RPCA but with symmetry removed (which then defaults to something like EB-RPCA), allowing us to isolate the importance of this factor, called “PB-RPCA w/o sym.”. For competing algorithms, we set parameters based on the values suggested by original authors with the exception of IRLS. Detailed settings and parameters can be found in [23]. 6This assumption can be relaxed with some additional effort but we avoid such considerations here for clarity of presentation. 7 Outlier Ratio 0 0.2 0.4 0.6 0.8 1 Success Rate 0 0.2 0.4 0.6 0.8 1 PB-RPCA (easy case) PB-RPCA (hard case) PCP (easy case) PCP (hard case) Figure 2: Hard case comparison. ρ SSC Robust SSC PCP+SSC PB+SSC (Ours) Without sub-sampling (large number of measurements) 0.1 19.0 / 14.9 5.3 / 0.3 3.0 / 0.0 2.4 / 0.0 0.2 28.2 / 28.3 6.4 / 0.4 3.0 / 0.0 2.4 / 0.0 0.3 33.2 / 34.7 7.2 / 0.5 3.6 / 0.2 2.8 / 0.0 0.4 36.5 / 39.0 8.5 / 0.6 4.7 / 0.2 3.1 / 0.0 With sub-sampling (small number of measurements) 0.1 19.5 / 17.2 4.0 / 0.0 2.9 / 0.0 2.8 / 0.0 0.2 33.0 / 33.3 5.3 / 0.0 3.7 / 0.0 3.6 / 0.0 0.3 39.3 / 41.1 5.7 / 1.7 5.0 / 0.7 3.9 / 0.0 0.4 42.2 / 43.5 6.4 / 2.1 9.8 / 5.1 3.7 / 0.0 *Values are percentage with (mean / median). Figure 3: Motion segmentation errors on Hopkins155. We construct phase transition plots as in [4, 9] that evaluate the recovery success of every pairing of outlier ratio and rank using data Y=ZGT +EGT , where Y∈Rm×n and m=n=200. The ground truth outlier matrix EGT is generated by selecting non-zero entries uniformly with probability ρ∈[0,1], and its magnitudes are sampled iid from the uniform distribution U[−20, 20]. We generate the ground truth low-rank matrix by ZGT =AB⊤, where A∈Rn×r and B∈Rm×r are drawn from iid N(0,1). Figure 1 shows comparisons among competing methods, as well as the convex nuclear norm based matrix completion (CVX-MC) [5], the latter representing a far easier estimation task given that missing entry locations (analogous to corruptions) occur in known locations. The color of each cell encodes the percentage of success trials (out of 10 total) whereby the normalized root-mean-squared error (NRMSE, ∥ˆZ−ZGT ∥F ∥ZGT ∥F ) recovering ZGT is less than 0.001 to classify success following [4, 9]. Notably PB-RPCA displays a much broader recoverability region. This improvement is even maintained over TNN-RPCA and MC which require prior knowledge such as the true rank and exact outlier locations respectively. These forms of prior knowledge offer a substantial advantage, although in practical situations are usually unavailable. PB-RPCA also outperforms PB-RPCA w/o sym. (its closest relative) by a wide margin, suggesting that the symmetry plays an important role. The poor performance of FB-RPCA is explained in [23]. Hard Case Comparison: Recovery of Gaussian iid low-rank components (the typical benchmark recovery problem in the literature) is somewhat ideal for existing algorithms like PCP because the singular vectors of ZGT will not resemble unit vectors that could be mistaken for sparse components. However, a simple test reveals just how brittle PCP is to deviations from the theoretically optimal regime. We generate a rank one ZGT = σa3(b3)⊤, where the cube operation is applied element-wise, a and b are vectors drawn iid from a unit sphere, and σ scales ZGT to unit variance. EGT has nonzero elements drawn iid from U[−1, 1]. Figure 2 shows the recovery results as the outlier ratio is increased. The hard case refers to the data just described, while the easy case follows the model used to make the phase transition plots. While PB-RPCA is quite stable, PCP completely fails for the hard data. Outlier Removal for Motion Segmentation: Under an affine camera model, the stacked matrix consisting of feature point trajectories of k rigidly moving objects forms a union of k affine subspaces of at most rank 4k [29]. But in practice, mismatches often occur due to occlusions or tracking algorithm limitations, and these introduce significant outliers into the feature motions such that the corresponding trajectory matrix may be at or near full rank. We adopt an experimental paradigm from [17] designed to test motion segmentation estimation in the presence of outliers. To mimic mismatches while retaining access to ground-truth, we randomly corrupt the entries of the trajectory matrix formed from Hopkins155 data [28]. Specifically, following [17] we add noise drawn from N(0, 0.1κ) to randomly sampled points with outlier ratio ρ∈[0, 1], where κ is the maximum absolute value of the data. We may then attempt to recover a clean version from the corrupted measurements using RPCA as a preprocessing step; motion segmentation can then be applied using standard subspace clustering [29]. We use SSC and robust SSC algorithms [10] as baselines, and compare with RPCA preprocessing computed via PCP (as suggested in [10]) and PB-RPCA followed by SSC. Additionally, we sub-sampled the trajectory matrix to increase problem difficulty by fewer samples. Segmentation accuracy is reported in Fig. 3, where we observe that PB shows the best performance across different outlier ratios, and the performance gap widens when the measurements are scarce. 6 Conclusion Since the introduction of convex RPCA algorithms, there has not been a significant algorithmic break-through in terms of dramatically enhancing the regime where success is possible, at least in the absence of any prior information (beyond the generic low-rank and sparsity assumptions). The likely explanation is that essentially all of these approaches solve either a problem in the form of (4), an asymmetric problem in the form of (11), or else require strong priori knowledge. We provide a novel integration of three important design criteria, concavity, non-separability, and symmetry, that leads to state-of-the-art results by a wide margin without tuning parameters or prior knowledge. 8 References [1] S. D. Babacan, M. Luessi, R. Molina, and A. K. Katsaggelos. Sparse Bayesian methods for low-rank matrix estimation. IEEE Trans. Signal Process., 2012. [2] C. M. Bishop. Pattern recognition and machine learning. Springer New York, 2006. [3] S. Boyd, N. Parikh, E. Chu, B. Peleato, and J. Eckstein. Distributed optimization and statistical learning via the alternating direction method of multipliers. Foundations and Trends R⃝in Machine Learning, 2011. [4] E. J. Candès, X. Li, Y. Ma, and J. Wright. Robust principal component analysis? J. of the ACM, 2011. [5] E. J. Candès and B. Recht. Exact matrix completion via convex optimization. Foundations of Computational mathematics, 2009. [6] V. Chandrasekaran, S. Sanghavi, P. A. Parrilo, and A. S. Willsky. Rank-sparsity incoherence for matrix decomposition. SIAM J. on Optim., 2011. [7] R. Chartrand. Nonconvex splitting for regularized low-rank+ sparse decomposition. IEEE Trans. Signal Process., 2012. [8] Y.-L. Chen and C.-T. Hsu. A generalized low-rank appearance model for spatio-temporally correlated rain streaks. In IEEE Int. Conf. Comput. Vis., 2013. [9] X. Ding, L. He, and L. Carin. Bayesian robust principal component analysis. IEEE Trans. Image Process., 2011. [10] E. Elhamifar and R. Vidal. Sparse subspace clustering: Algorithm, theory, and applications. IEEE Trans. Pattern Anal. and Mach. Intell., 2013. [11] J. Fan and R. Li. Variable selection via nonconcave penalized likelihood and its oracle properties. J. Am. Stat. Assoc., 2001. [12] D. R. Hunter and K. Lange. A tutorial on MM algorithms. The American Statistician, 2004. [13] H. Ji, C. Liu, Z. Shen, and Y. Xu. Robust video denoising using low rank matrix completion. In IEEE Conf. Comput. Vis. and Pattern Recognit., 2010. [14] M. I. Jordan, Z. Ghahramani, T. S. Jaakkola, and L. K. Saul. An introduction to variational methods for graphical models. Mach. Learn., 1999. [15] B. Lakshminarayanan, G. Bouchard, and C. Archambeau. Robust Bayesian matrix factorisation. In AISTATS, 2011. [16] Z. Lin, M. Chen, and Y. Ma. The augmented Lagrange multiplier method for exact recovery of corrupted low-rank matrices. arXiv:1009.5055, 2010. [17] G. Liu and S. Yan. Latent low-rank representation for subspace segmentation and feature extraction. In IEEE Int. Conf. Comput. Vis., 2011. [18] C. Lu, Z. Lin, and S. Yan. Smoothed low rank and sparse matrix recovery by iteratively reweighted least squares minimization. IEEE Trans. Image Process., 2015. [19] K. Mohan and M. Fazel. Iterative reweighted algorithms for matrix rank minimization. J. Mach. Learn. Res., 2012. [20] K. P. Murphy. Machine Learning: a Probabilistic Perspective. MIT Press, 2012. [21] K. P. Murphy, Y. Weiss, and M. I. Jordan. Loopy belief propagation for approximate inference: An empirical study. In UAI, 1999. [22] T.-H. Oh, J.-Y. Lee, Y.-W. Tai, and I. S. Kweon. Robust high dynamic range imaging by rank minimization. IEEE Trans. Pattern Anal. and Mach. Intell., 2015. [23] T.-H. Oh, Y. Matsushita, I. S. Kweon, and D. Wipf. Pseudo-Bayesian robust PCA: Algorithms and analyses. arXiv preprint arXiv:1512.02188, 2015. [24] T.-H. Oh, Y.-W. Tai, J.-C. Bazin, H. Kim, and I. S. Kweon. Partial sum minimization of singular values in Robust PCA: Algorithm and applications. IEEE Trans. Pattern Anal. and Mach. Intell., 2016. [25] J. A. Palmer. Relative convexity. ECE Dept., UCSD, Tech. Rep, 2003. [26] J. T. Parker, P. Schniter, and V. Cevher. Bilinear generalized approximate message passing. arXiv:1310.2632, 2013. [27] Y. Peng, A. Ganesh, J. Wright, W. Xu, and Y. Ma. RASL: Robust alignment by sparse and low-rank decomposition for linearly correlated images. IEEE Trans. Pattern Anal. and Mach. Intell., 2012. [28] R. Tron and R. Vidal. A benchmark for the comparison of 3-d motion segmentation algorithms. In IEEE Conf. Comput. Vis. and Pattern Recognit., 2007. [29] R. Vidal. Subspace clustering. IEEE Signal Process. Mag., 2011. [30] N. Wang and D.-Y. Yeung. Bayesian robust matrix factorization for image and video processing. In IEEE Int. Conf. Comput. Vis., 2013. [31] D. Wipf. Non-convex rank minimization via an empirical Bayesian approach. In UAI, 2012. [32] D. Wipf, B. D. Rao, and S. Nagarajan. Latent variable Bayesian models for promoting sparsity. IEEE Trans. on Information Theory, 2011. [33] L. Wu, A. Ganesh, B. Shi, Y. Matsushita, Y. Wang, and Y. Ma. Robust photometric stereo via low-rank matrix completion and recovery. In Asian Conf. Comput. Vis., 2010. [34] B. Xin and D. Wipf. Pushing the limits of affine rank minimization by adapting probabilistic PCA. In Int. Conf. Mach. Learn., 2015. 9 | 2016 | 536 |
6,479 | The Forget-me-not Process Kieran Milan†, Joel Veness†, James Kirkpatrick, Demis Hassabis Google DeepMind {kmilan,aixi,kirkpatrick,demishassabis}@google.com Anna Koop, Michael Bowling University of Alberta {anna,bowling}@cs.ualberta.ca Abstract We introduce the Forget-me-not Process, an efficient, non-parametric metaalgorithm for online probabilistic sequence prediction for piecewise stationary, repeating sources. Our method works by taking a Bayesian approach to partitioning a stream of data into postulated task-specific segments, while simultaneously building a model for each task. We provide regret guarantees with respect to piecewise stationary data sources under the logarithmic loss, and validate the method empirically across a range of sequence prediction and task identification problems. 1 Introduction Modeling non-stationary temporal data sources is a fundamental problem in signal processing, statistical data compression, quantitative finance and model-based reinforcement learning. One widely-adopted and successful approach has been to design meta-algorithms that automatically generalize existing stationary learning algorithms to various non-stationary settings. In this paper we introduce the Forget-me-not Process, a probabilistic meta-algorithm that provides the ability to model the class of memory bounded, piecewise-repeating sources given an arbitrary, probabilistic memory bounded stationary model. The most well studied class of probabilistic meta-algorithms are those for piecewise stationary sources, which model data sequences with abruptly changing statistics. Almost all meta-algorithms for abruptly changing sources work by performing Bayesian model averaging over a class of hypothesized temporal partitions. To the best of our knowledge, the earliest demonstration of this fundamental technique was [21], for the purpose of data compression; closely related techniques have gained popularity within the machine learning community for change point detection [1] and have been proposed by neuroscientists as a mechanism by which humans deal with open-ended environments composed of multiple distinct tasks [4–6]. One of the reasons for the popularity of this approach is that the temporal structure can be exploited to make exact Bayesian inference tractable via dynamic programming; in particular inference over all possible temporal partitions of n data points results in an algorithm of O(n2) time complexity and O(n) space complexity [21, 1]. Many variants have been proposed in the literature [20, 11, 10, 17], which trade off predictive accuracy for improved time and space complexity; in particular the Partition Tree Weighting meta-algorithm [17] has O(n log n) time and O(log n) space complexity, and has been shown empirically to exhibit superior performance versus other low-complexity alternatives on piecewise stationary sources. A key limitation of these aforementioned techniques is that they can perform poorly when there exist multiple segments of data that are similarly distributed. For example, consider data generated according to the schedule depicted in Figure 1. For all these methods, once a change-point occurs, the base (stationary) model is invoked from scratch, even if the task repeats, which is clearly undesirable † indicates joint first authorship. 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. 1 20 40 60 80 100 120 140 160 1 2 3 Time Task Figure 1: An example task segmentation. in many situations of interest. Our main contribution in this paper is to introduce the Forget-me-not Process, which has the ability to avoid having to relearn repeated tasks, while still maintaining essentially the same theoretical performance guarantees as Partition Tree Weighting on piecewise stationary sources. 2 Preliminaries We now introduce some notation and necessary background material. Sequential Probabilistic Data Generators. We begin with some terminology for sequential, probabilistic data generating sources. An alphabet is a finite non-empty set of symbols, which we will denote by X. A string x1x2 . . . xn ∈X n of length n is denoted by x1:n. The prefix x1:j of x1:n, where j ≤n, is denoted by x≤j or x<j+1. The empty string is denoted by ϵ and we define X ∗= {ϵ} ∪S∞ i=1 X i. Our notation also generalizes to out of bounds indices; that is, given a string x1:n and an integer m > n, we define x1:m := x1:n and xm:n := ϵ. The concatenation of two strings s, r ∈X ∗is denoted by sr. Unless otherwise specified, base 2 is assumed for all logarithms. A sequential probabilistic data generating source ρ is defined by a sequence of probability mass functions ρn : X n →[0, 1], for all n ∈N, satisfying the constraint that ρn(x1:n) = P y∈X ρn+1(x1:ny) for all x1:n ∈X n, with base case ρ0(ϵ) = 1. From here onwards, whenever the meaning is clear from the argument to ρ, the subscripts on ρ will be dropped. Under this definition, the conditional probability of a symbol xn given previous data x<n is defined as ρ(xn | x<n) := ρ(x1:n)/ρ(x<n) provided ρ(x<n) > 0, with the familiar chain rule ρ(xi:j | x<i) = Qj k=i ρ(xk | x<k) applying as usual. Notice too that a new sequential probabilistic data generating source ν can be obtained from an existing source ρ by conditioning on a fixed sequence of input data. More explicitly, given a string s ∈X ∗, one can define ν(x1:n) := ρ(x1:n | s) for all n; we will use the notation ρ[s] to compactly denote such a derived probabilistic data generating source. Temporal Partitions, Piecewise Sources and Piecewise-repeating sources. We now introduce some notation to formally describe temporal partitions and piecewise sources. A segment is a tuple (a, b) ∈N × N with a ≤b. A segment (a, b) is said to overlap with another segment (c, d) if there exists an i ∈N such that a ≤i ≤b and c ≤i ≤d. A temporal partition P of a set of time indices S = {1, 2, . . . n}, for some n ∈N, is a set of non-overlapping segments such that for all x ∈S, there exists a segment (a, b) ∈P such that a ≤x ≤b. We also use the overloaded notation P(a, b) := {(c, d) ∈P : a ≤c ≤d ≤b} to denote the set of segments falling inclusively within the range (a, b). Finally, Tn will be used to denote the set of all possible temporal partitions of {1, 2, . . . , n}. We can now define a piecewise data generating source µh P in terms of a partition P = {(a1, b1), (a2, b2), . . . } and a set of probabilistic data generating sources {µ1, µ2, . . . }, such that for all n ∈N, for all x1:n ∈X n, µh P(x1:n) := Y (a,b)∈Pn µh(a)(xa:b), where Pn := {(a, b) ∈P : a ≤n} and h : N →N is a task assignment function that maps segment beginnings to task identifiers. A piecewise repeating data generating source is a special case of a piecewise data generating source that satisfies the additional constraint that ∃a, c ∈{x : (x, y) ∈P} such that a ̸= c and h(a) = h(c). 2 In terms of modeling a piecewise repeating source, there are three key unknowns: the partition which defines the location of the change points, the task assignment function, and the model for each individual task. Bayesian Sequence Prediction. A fundamental technique for constructing algorithms that work well under the logarithmic loss is Bayesian model averaging. We now provide a short overview sufficient for the purposes of this paper; for more detail, we recommend the work of [12] and [14]. Given a non-empty discrete set of probabilistic data generating sources M := {ρ1, ρ2, . . . } and a prior weight wρ 0 > 0 for each ρ ∈M such that P ρ∈M wρ 0 = 1, the Bayesian mixture predictor is defined in terms of its marginal by ξ(x1:n) := P ρ∈M wρ 0 ρ(x1:n). The predictive probability is thus given by the ratio of the marginals ξ(xn | x<n) = ξ(x1:n) / ξ(x<n). The predictive probability can also be expressed in terms of a convex combination of conditional model predictions, with each model weighted by its posterior probability. More explicitly, ξ(xn | x<n) = P ρ∈M wρ 0 ρ(x1:n) P ρ∈M wρ 0 ρ(x<n) = X ρ∈M wρ n−1 ρ(xn | x<n), where wρ n−1 := wρ 0 ρ(x<n) P ν∈M wν 0 ν(x<n). A fundamental property of Bayesian mixtures is that if there exists a model ρ∗∈M that predicts well, then ξ will predict well since the cumulative loss satisfies −log ξ(x1:n) = −log X ρ∈M wρ 0 ρ(x1:n) ≤−log wρ∗ 0 −log ρ∗(x1:n). (1) Equation 1 implies that a constant regret is suffered when using ξ in place of the best (in hindsight) model within M. 3 The Forget-me-not Process We now introduce the Forget-me-not Process (FMN), a meta-algorithm designed to better model piecewise-repeating data generating sources. As FMN is a meta-algorithm, it takes as input a base model, which we will hereby denote as ν. At a high level, the main idea is to extend the Partition Tree Weighting [17] algorithm to incorporate a memory of previous model states, which is used to improve performance on repeated tasks. More concretely, our construction involves defining a two-level hierarchical process, with each level performing exact Bayesian model averaging. The first level will perform model averaging over a set of postulated segmentations of time, using the Partition Tree Weighting technique. The second level will perform model averaging over a growing set of stored base model states. We describe each level in turn before describing how to combine these ideas into the Forget-me-not Process. Averaging over Temporal Segmentations. We now define the class of binary temporal partitions, which will correspond to the set of temporal partitions we perform model averaging over in the first level of our hierarchical model. Although more restrictive than the class of all possible temporal partitions, binary temporal partitions possess important computational advantages. Definition 1. Given a depth parameter d ∈N and a time t ∈N, the set Cd(t) of all binary temporal partitions from t is recursively defined by Cd(t) := {(t, t + 2d −1)} ∪ S1 ∪S2 : S1 ∈Cd−1 (t) , S2 ∈Cd−1 t + 2d−1 , with C0(t) := {(t, t)} . We also define Cd := Cd(1). Each binary temporal partition can be naturally mapped onto a tree structure known as a partition tree; for example, Figure 2 shows the collection of partition trees represented by C2; the leaves of each tree correspond to the segments within each particular partition. There are two important properties of binary temporal partition trees. The first is that there always exists a partition P′ ∈Cd which is close to any temporal partition P, in the sense that P′ always starts a new segment whenever P does, and |P′| ≤|P|(⌈log n⌉+ 1) [17, Lemma 2]. The second is that exact Bayesian model averaging can be performed efficiently with an appropriate choice of prior. This is somewhat surprising, since the 3 • (1,4) (1,2) • (3,4) • • (2, 2) (3, 4) (1,2) • (3,3) (4,4) (1,1) • • (2,2) (3,3) • (4,4) (1,1) Figure 2: The set C2 represented as a collection of temporal partition trees. number of binary temporal partitions |Cd| grows double exponentially in d. The trick is to define, given a data sequence x1:n, the Bayesian mixture PTWd(x1:n) := X P∈Cd 2−Γd(P) Y (a,b)∈P ρ(xa:b), (2) where Γd(P) gives the number of nodes in the partition tree associated with P that have a depth less than d and ρ denotes the base model to the PTW process. This prior weighting is identical to how the Context Tree Weighting method [22] weighs over tree structures, and is an application of the general technique used by the class of Tree Experts described in Section 5.3 of [3]. It is a valid prior, as one can show P P∈Cd 2−Γd(P) = 1 for all d ∈N. A direct computation of Equation 2 is clearly intractable, but we can make use of the tree structured prior to recursively decompose Equation 2 using the following lemma. Lemma 1 (Veness et al. [17]). For any depth d ∈N, for all x1:n ∈X n satisfying n ≤2d, PTWd(x1:n) = 1 2ρ(x1:n) + 1 2 PTWd−1 (x1:k) PTWd−1 (xk+1:n) , where k = 2d−1. Averaging over Previous Model States given a Known Temporal Partition. Given a data sequence x1:n ∈X n, a base model ρ and a temporal partition P := {(a1, b1), . . . , (am, bm)} satisfying P ∈Tn, consider a sequential probabilistic model defined by πP(x1:n) := |P| Y i=1 X ρ∈Mi 1 |Mi| ρ(xai:bi) , where M1 := {ρ} and Mi := Mi−1 ∪{ρ [xai:bi]}ρ∈Mi−1 for 1 < i ≤|P|. Here, whenever the ith segment of data is seen, each model in Mi is given the option of either ignoring or adapting to this segment’s data, which implies |Mi| = 2 |Mi−1|. Using an argument similar to Equation 1, and letting xh(t) <t denote the subsequence of x<t generated by µh(t), we can see that the cumulative loss when the data is generated by a piecewise-repeating source µh P is bounded by −log πP(x1:n) = −log |P| Y i=1 X ρ∈Mi 1 |Mi| ρ(xai:bi) = −log |P| Y i=1 X ρ∈Mi 2−i+1 ρ(xai:bi) ≤−log |P| Y i=1 2−i+1 ρ xai:bi | xh(ai) <ai = |P|2 −|P| 2 −log |P| Y i=1 ρ xai:bi | xh(ai) <ai . (3) Roughly speaking, this bound implies that πP(x1:n) will perform almost as well as if we knew h(·) in advance, provided the number of segments grows o(√n). The two main drawbacks with this approach are that: a) computing πP(x1:n) takes time exponential in |P|; and b) a regret of (|P|2 −|P|)/2 seems overly large in cases where the source isn’t repeating. These problems can be rectified with the following modified process, νP(x1:n) := |P| Y i=1 1 2ρ(xai:bi) + 1 2 X ρ′∈Mi\{ρ} 1 |Mi|−1 ρ′(xai:bi) (4) where now M1 := {ρ} and Mi := Mi−1 ∪ n ρ∗[xai:bi] ρ∗= argmaxρ∈Mi−1 {ρ (xai:bi)} o . 4 1 2 3 4 5 6 7 8 3 2 1 0 Time Depth Figure 3: A graphical depiction of the Forget Me Not process (d = 3) after processing 7 symbols. With this modified definition of Mi, where the argmax implements a greedy approximation (ties are broken arbitrarily), |Mi| now grows linearly with the number of segments, and thus the overall time to compute νP(x1:n) is O(|P| n) assuming the base model runs in linear time. Although heuristic, this approximation is justified provided that ρ[ϵ] assigns the highest probability out of any model in Mi whenever a task is seen for the first time, and that a model trained on k segments for a given task is always better than a model trained on less than k segments for the same task (or a model trained on any number of other tasks). Furthermore, using a similar dominance argument to Equations 1 and 3, the cost of not knowing h(·) with respect to piecewise non-repeating sources is now |P| vs O(|P|2). Averaging over Binary Temporal Segmentations and Previous Model States. This section describes how to hierarchically combine the PTW and νP models to give rise to the Forget Me Not process. Our goal will be to perform model averaging over both binary temporal segmentations and previous model states. This can be achieved by instantiating the PTW meta-algorithm with a sequence of time dependent base models similar in spirit to νP. Intuitively, this requires modifying the definition of Mi so that the best performing model state, for any completed segment within the PTW process, is available for future predictions. For example, Figure 3 provides a graphical depiction of our desired FMN3 process after processing 7 symbols. The dashed segments ending in unfilled circles describe the segments whose set of base models are contributing to the predictive distribution at time 8. The solid-line segments denote previously completed segments for which we want the best performing model state to be remembered and made available to segments starting at later times. A solid circle indicates a time where a model is added to the pool of available models; note that now multiple models can be added at any particular time. We now formalize the above intuitions. Let Bt := {(a, b) ∈Cd : b = t} be the set of segments ending at time t ≤2d. Given an an arbitrary string s ∈X ∗, our desired sequence of base models is given by νt(s) := 1 2ρ(s) + 1 2 X ρ′∈Mt\{ρ} 1 |Mt|−1 ρ′(s), (5) with the model pool defined by M1 := {ρ} and Mt := Mt−1 ∪ [ (a,b)∈Bt−1 ρ∗[sa:b] ρ∗= argmax ρ∈Ma {ρ (sa:b)} for t > 1. (6) Finally, substituting Equation 5 in for the base model of PTW yields our Forget Me Not process FMNd(x1:n) := X P∈Cd 2−Γd(P) Y (a,b)∈Pn νa(xa:b). (7) Algorithm. Algorithm 1 describes how to compute the marginal probability FMNd(x1:n). The rj variables store the segment start times for the unclosed segments at depth j; the bj variables implement a dynamic programming caching mechanism to speed up the PTW computation as explained in Section 3.3 of [17]; the wj variables hold intermediate results needed to apply Lemma 1. The Most Significant Changed Bit routine MSCBd(t), invoked at line 4, is used to determine the range of segments ending at the current time t, and is defined for t > 1 as the number of bits to the left of the most significant location at which the d-bit binary representations of t−1 and t−2 differ, with MSCBd(1) := 0 for all d ∈N. For example, in Figure 3, at t = 5, before processing x5, we need to deal with the segments 5 Algorithm 1 FORGET-ME-NOT - FMNd(x1:n) Require: A depth parameter d ∈N, and a base probabilistic model ρ Require: A data sequence x1:n ∈X n satisfying n ≤2d 1: bj ←1, wj ←1, rj ←1, for 0 ≤j ≤d 2: M ←{ρ} 3: for t = 1 to n do 4: i ←MSCBd(t) 5: bi ←wi+1 6: for j = i + 1 to d do 7: M ←UPDATEMODELPOOL(νrj, xrj:t−1) 8: wj ←1, bj ←1, rj ←t 9: end for 10: wd ←νrd(xrd:t) 11: for i = d −1 to 0 do 12: wi ←1 2νri(xri:t) + 1 2wi+1bi 13: end for 14: end for 15: return w0 (1, 4), (3, 4), (4, 4) finishing. The method UPDATEMODELPOOL applies Equation 6 to remember the best performing model in the mixture νrj on the completed segment (rj, t −1). Lines 11 to 13 invoke Lemma 1 from bottom-up, to compute the desired marginal probability FMNd(x1:n) = w0. (Space and Time Overhead) Under the assumption that each base model conditional probability can be obtained in O(1) time, the time complexity to process a sequence of length n is O(nk log n), where k is an upper bound on |M|. The n log n factor is due to the number of iterations in the inner loops on Lines 6 to 9 and Lines 11 to 13 being upper bounded by d + 1. The k factor is due to the cost of maintaining the vt terms for the segments which have not yet closed. An upper bound on k can be obtained from inspection of Figure 3, where if we set n = 2d, we have that the number of completed segments is given by Pd i=0 2i = 2d+1 −1 = 2n + 1 = O(n); thus the time complexity is O(n2 log n). The space overhead is O(k log n), due to the O(log n) instances of Equation 5. (Complexity Reducing Operations) For many applications of interest, a running time of O(n2 log n) is unacceptable. A workaround is to fix k in advance and use a model replacement strategy that enforces |M| ≤k via a modified UPDATEMODELPOOL routine; this reduces the time complexity to O(nk log n). We found the following heuristic scheme to be effective in practice: when a segment (a, b) closes, the best performing model ρ∗∈Ma for this segment is identified. Now, 1) letting yρ∗ denote a uniform sub-sample of the data used to train ρ∗, if log ρ∗[xa:b](yρ∗) −log ρ∗(yρ∗) > α then replace ρ∗with ρ∗[xa:b] in M; else 2) if a uniform Bayes mixture ξ over M assigns sufficiently higher probability to a uniform sub-sample s of xa:b than ρ∗does, that is log ξ(s) −log ρ∗(s) > β, then leave M unchanged; else 3) add ρ∗[xa:b] to M; if |M| > k, remove the oldest model in M. This requires choosing hyperparameters α, β ∈R and appropriate constant sub-sample sizes. Step 1 avoids adding multiple models for the same task; Step 2 avoids adding a redundant model to the model pool. Note that the per model and per segment sub-samples can be efficiently maintained online using reservoir sampling [19]. As a further complexity reducing operation, one can skip calls to UPDATEMODELPOOL unless (b −a + 1) ≥2c for some c < d. (Strongly Online Prediction) A strongly online FMN process, where one does not need to fix a d in advance such that n ≤2d, can be obtained by defining FMN(x1:n) := Qn i=1 FMN⌈log i⌉(xi | x<i), and efficiently computed in the same manner as for PTW, with a similar loss bound −log FMN(x1:n) ≤ −log FMNd(x1:n) + ⌈log n⌉(log 3 −1) following trivially from Theorem 2 in [17]. Theoretical properties. We now show that the Forget Me Not process is competitive with any piecewise stationary source, provided the base model enjoys sufficiently strong regret guarantees on 6 non-piecewise sources. Note that provided c = 0, Proposition 1 also holds when the complexity reducing operations are used. While the following regret bound is of the same asymptotic order as PTW for piecewise stationary sources, note that it is no tighter for sources that repeat; we will later explore the advantage of the FMN process on repeating sources experimentally. Proposition 1. For all n ∈N, using FMN with d = ⌈log n⌉and a base model ρ whose redundancy is upper bounded by a non-negative, monotonically non-decreasing, concave function g : N →R with g(0) = 0 on some class G of bounded memory data generating sources, the regret log µh P(x1:n) FMNd(x1:n) ≤2|Pn| (⌈log n⌉+ 1) + |Pn| g n |Pn|(⌈log n⌉+ 1) (⌈log n⌉+ 1) + |Pn|, where µ is a piecewise stationary data generating source, and the data in each of the stationary regions P ∈Tn is distributed according to some source in G. Proof. First observe that for all x1:n ∈X n we can lower bound the probability FMNd(x1:n) = X P∈Cd 2−Γd(P) Y (a,b)∈Pn νa(xa:b) ≥ X P∈Cd 2−Γd(P) Y (a,b)∈Pn 1 2ρ(xa:b) = 2−|Pn| X P∈Cd 2−Γd(P) Y (a,b)∈Pn ρ(xa:b) = 2−|Pn| PTWd(x1:n). Hence we have that −log FMNd(x1:n) ≤|P| −log PTWd(x1:n). The proof is completed by using Theorem 1 from [17] to upper bound −log PTWd(x1:n). 4 Experimental Results We now report some experimental results with the FMN algorithm across three test domains. The first two domains, The Mysterious Bag of Coins and A Fistful of Digits, are repeating sequence prediction tasks. The final domain, Continual Atari 2600 Task Identification, is a video stream of game-play from a collection of Atari games provided by the ALE [2] framework; here we qualitatively assess the capabilities of the FMN process to provide meaningful task labels online from high dimensional input. Domain Description. (Mysterious Bag of Coins) Our first domain is a sequence prediction game involving a predictor, an opponent and a bag of m biased coins. Flipping the ith coin involves sampling a value from a parametrized Bernoulli distribution B(θi), with θi ∈[0, 1] for 1 ≤i ≤m. The predictor knows neither how many coins are in the bag, nor the value of the θi parameters. The data is generated by having the opponent flip a single coin (the choice of which is hidden from the predictor) drawn uniformly from the bag for X ∼G(0.005) flips, and repeating, where G(θ) denotes the geometric distribution with success probability θ. At each time step t, the predictor outputs a distribution ρt : {0, 1} →[0, 1], and suffers an instantaneous loss of ℓt(xt) := −log ρt(xt). Here we test whether the FMN process can robustly identify change points, and exploit the knowledge that some segments of data appear to be similarly distributed. (A Fistful of Digits) The second test domain uses a similar setup to The Mysterious Bag of Coins, except that now each observation is a 28x28 binary image taken from the MNIST [15] data set. We partitioned the MNIST data into m = 10 classes, one for each distinct digit, which we used to derive ten digit-specific empirical distributions. After picking a digit class, a random number Y = 200 + X ∼G(0.01) of examples are sampled (with replacement) from the associated empirical distribution, before repeating the digit selection and generation process. Similar to before, the predictor is required to output a distribution ρt : {0, 1}28×28 →[0, 1] over the possible outcomes, suffering an instantaneous loss of ℓt(xt) := −log ρt(xt) at each time step. (Continual Atari 2600 Task Identification) Our third domain consists of a sequence of sampled Atari 2600 frames. Each frame has been downsampled to a 28 × 28 resolution and a 3 bit color space for reasons of computational efficiency. The sequence of frames is generated by first picking a game uniformly at random from a set of 45 Atari games (for which a game-specific DQN [16] policy is available), and then generating a random number Y = 200 + X of frames, where X ∼G(0.005). Each action is chosen by the relevant game specific DQN controller, which uses an epsilon-greedy policy. Once Y frames have been generated, the process is then repeated. 7 Algorithm Average Cumulative Regret KT 783.86 ± 7.79 PTW + KT 157.19 ± 0.77 FMN + KT 148.43 ± 0.75 FMN∗+ KT 147.75 ± 0.74 Algorithm Average Per Digit Loss MADE 94.08 ± 0.05 PTW + MADE 94.08 ± 0.05 FMN + MADE 86.12 ± 0.28 Oracle 82.81 ± 0.06 Figure 4: (Left) Results on the Mysterious Bag of Coins; (Right) Results on a Fistful of Digits. Results. We now describe our experimental setup and results. The following base models were chosen for each test domain: for the Mysterious Bag of Coins (MBOC), we used the KT-estimator [13], a beta-binomial model; for A Fistful of Digits (FOD), we used MADE [9], a recently introduced, general purpose neural density estimator, with 500 hidden units, trained online using ADAGRAD [8] with a learning rate of 0.1; MADE was also the base model for the Continual Atari task, but here a smaller network consisting of 50 neurons was used for reasons of computational efficiency. (Sequence Prediction) For each domain, we compared the performance of the base model, the base model combined with PTW and the base model combined with the FMN process. We also report the performance relative to a domain specific oracle: for the MBOC domain, the oracle is the true data generating source, which has the (unfair) advantage of knowing the location of all potential change-points and task-specific data generating distributions; for the FOD domain, we trained a class conditional MADE model for each digit offline, and applied the relevant task-specific model to each segment. Regret is reported for MBOC since we know the true data generating source, whereas loss is reported for FOD. All results are reported in nats. The sequence length and number of repeated runs for MBOC and FOD was 5k/10k and 221/64 respectively. For the MBOC experiment we set m = 7 and generated each θi uniformly at random. Our sequence prediction results for each domain are summarized in Figure 4, with 95% confidence intervals provided. Here FMN∗denotes the Forget-me-not algorithm without the complexity reducing techniques previously described (these results are only feasible to produce on MBOC). For the FMN results, the MBOC hyper-parameters are k = 15, α = 0, β = 0, c = 4 and sub-sample sizes of 100; the FOD hyper-parameters are k = 30, α = 0.2, β = 0.06, c = 4 with sub-sample sizes of 10. Here we see a clear advantage to using the FMN process compared with PTW, and that no significant performance is lost by using the low complexity version of the algorithm. Digging a bit deeper, it is interesting to note the inability of PTW to improve upon the performance of the base model on FOD. This is in contrast to the FMN process, whose ability to remember previous model states allows it to, over time, develop specialized models across digit specific data from multiple segments, even in the case where the base model can be relatively slow to adapt online. The reverse effect occurs in MBOC, where both FMN and PTW provide a large improvement over the performance of the base model. The advantage of being able to remember is much smaller here due to the speed at which the KT base model can learn, although not insignificant. It is also worth noting that a performance improvement is obtained even though each individual observation is by itself not informative; the FMN process is exploiting the statistical similarity of the outcomes across time. (Online Task Identification) A video demonstrating real-time segmentation of Atari frames can be found at: http://tinyurl.com/FMNVideo. Here we see that the (low complexity) FMN quickly learns 45 game specific models, and performs an excellent job of routing experience to the appropriate model. These results provide evidence that this technique can scale to long, high dimensional input sequences using state of the art density models. 5 Conclusion We introduced the Forget-me-not Process, an efficient, non-parametric meta-algorithm for online probabilistic sequence prediction and task-segmentation for piecewise stationary, repeating sources. We provided regret guarantees with respect to piecewise stationary data sources under the logarithmic loss, and validated the method empirically across a range of sequence prediction and task identification problems. For future work, it would be interesting to see whether a single Multiple Model-based Reinforcement Learning [7] agent could be constructed using the Forget-me-not process for task identification. Alternatively, the FMN process could be used to augment the conditional state density models used for value estimation in [18]. Such systems would have the potential to be able to learn to simultaneously play many different Atari games from a single stream of experience, as opposed to previous efforts [16, 18] where game specific controllers were learnt independently. 8 References [1] Ryan Prescott Adams and David J.C. MacKay. Bayesian Online Changepoint Detection. In arXiv, http://arxiv.org/abs/0710.3742, 2007. [2] M. G. Bellemare, Y. Naddaf, J. Veness, and M. Bowling. The arcade learning environment: An evaluation platform for general agents. Journal of Artificial Intelligence Research, 47:253–279, 06 2013. [3] Nicolo Cesa-Bianchi and Gabor Lugosi. Prediction, Learning, and Games. Cambridge University Press, New York, NY, USA, 2006. ISBN 0521841089. [4] Anne Collins and Etienne Koechlin. Reasoning, learning, and creativity: Frontal lobe function and human decision-making. PLoS Biol, 10(3):1–16, 03 2012. [5] Anne G.E. Collins and Michael J. Frank. Cognitive Control over Learning: Creating, Clustering and Generalizing Task-Set Structure. Psychological review, 120.1:190–229, 2013. [6] Maël Donoso, Anne G. E. Collins, and Etienne Koechlin. Foundations of human reasoning in the prefrontal cortex. Science, 344(6191):1481–1486, 2014. doi: 10.1126/science.1252254. [7] Kenji Doya and Kazuyuki Samejima. Multiple model-based reinforcement learning. Neural Computation, 14:1347–1369, 2002. [8] John Duchi, Elad Hazan, and Yoram Singer. Adaptive Subgradient Methods for Online Learning and Stochastic Optimization. Journal of Machine Learning Research (JMLR), 12:2121–2159, 07 2011. [9] Mathieu Germain, Karol Gregor, Iain Murray, and Hugo Larochelle. MADE: masked autoencoder for distribution estimation. In Proceedings of the 32nd International Conference on Machine Learning, JMLR W&CP, volume 37, pages 881–889, 2015. [10] A. György, T. Linder, and G. Lugosi. Efficient tracking of large classes of experts. IEEE Transactions on Information Theory, 58(11):6709–6725, 2011. [11] E. Hazan and C. Seshadhri. Efficient learning algorithms for changing environments. In Proceedings of the 26th Annual International Conference on Machine Learning, pages 393–400. ACM, 2009. [12] Marcus Hutter. On universal prediction and Bayesian confirmation. Theoretical Computer Science, 384(1): 33–48, 2007. [13] R. Krichevsky and V. Trofimov. The performance of universal encoding. Information Theory, IEEE Transactions on, 27(2):199–207, 1981. [14] Tor Lattimore, Marcus Hutter, and Peter Sunehag. Concentration and confidence for discrete bayesian sequence predictors. In Sanjay Jain, Rémi Munos, Frank Stephan, and Thomas Zeugmann, editors, Proceedings of the 24th International Conference on Algorithmic Learning Theory, pages 324–338. Springer, 2013. [15] Y. Lecun, L. Bottou, Y. Bengio, and P. Haffner. Gradient-based learning applied to document recognition. Proceedings of the IEEE, 86(11):2278–2324, Nov 1998. [16] Volodymyr Mnih, Koray Kavukcuoglu, David Silver, Andrei A. Rusu, Joel Veness, Marc G. Bellemare, Alex Graves, Martin Riedmiller, Andreas K. Fidjeland, Georg Ostrovski, Stig Petersen, Charles Beattie, Amir Sadik, Ioannis Antonoglou, Helen King, Dharshan Kumaran, Daan Wierstra, Shane Legg, and Demis Hassabis. Human-level control through deep reinforcement learning. Nature, 518, 2015. [17] J. Veness, M. White, M. Bowling, and A. Gyorgy. Partition tree weighting. In Data Compression Conference (DCC), pages 321–330, March 2013. [18] Joel Veness, Marc G. Bellemare, Marcus Hutter, Alvin Chua, and Guillaume Desjardins. Compress and control. In Proceedings of the Twenty-Ninth AAAI Conference on Artificial Intelligence, January 25-30, 2015, Austin, Texas, USA., pages 3016–3023, 2015. [19] Jeffrey S. Vitter. Random sampling with a reservoir. ACM Trans. Math. Softw., 11(1):37–57, March 1985. ISSN 0098-3500. doi: 10.1145/3147.3165. [20] F. Willems and M. Krom. Live-and-die coding for binary piecewise i.i.d. sources. In Information Theory. 1997. Proceedings., 1997 IEEE International Symposium on, page 68, jun-4 jul 1997. [21] Frans M. J. Willems. Coding for a binary independent piecewise-identically-distributed source. IEEE Transactions on Information Theory, 42:2210–2217, 1996. [22] Frans M.J. Willems, Yuri M. Shtarkov, and Tjalling J. Tjalkens. The Context Tree Weighting Method: Basic Properties. IEEE Transactions on Information Theory, 41:653–664, 1995. 9 | 2016 | 537 |
6,480 | Unsupervised Risk Estimation Using Only Conditional Independence Structure Jacob Steinhardt Stanford University jsteinhardt@cs.stanford.edu Percy Liang Stanford University pliang@cs.stanford.edu Abstract We show how to estimate a model’s test error from unlabeled data, on distributions very different from the training distribution, while assuming only that certain conditional independencies are preserved between train and test. We do not need to assume that the optimal predictor is the same between train and test, or that the true distribution lies in any parametric family. We can also efficiently compute gradients of the estimated error and hence perform unsupervised discriminative learning. Our technical tool is the method of moments, which allows us to exploit conditional independencies in the absence of a fully-specified model. Our framework encompasses a large family of losses including the log and exponential loss, and extends to structured output settings such as conditional random fields. 1 Introduction Can we measure the accuracy of a model at test time without any ground truth labels, and without assuming the test distribution is close to the training distribution? This is the problem of unsupervised risk estimation (Donmez et al., 2010): Given a loss function L(θ; x, y) and a fixed model θ, estimate the risk R(θ) def = Ex,y∼p∗[L(θ; x, y)] with respect to a test distribution p∗(x, y), given access only to m unlabeled examples x(1:m) ∼p∗(x). Unsupervised risk estimation lets us estimate model accuracy on a novel distribution, and is thus important for building reliable machine learning systems. Beyond evaluating a single model, it also provides a way of harnessing unlabeled data for learning: by minimizing the estimated risk over θ, we can perform unsupervised learning and domain adaptation. Unsupervised risk estimation is impossible without some assumptions on p∗, as otherwise p∗(y | x)— about which we have no observable information—could be arbitrary. How satisfied we should be with an estimator depends on how strong its underlying assumptions are. In this paper, we present an approach which rests on surprisingly weak assumptions—that p∗satisfies certain conditional independencies, but not that it lies in any parametric family or is close to the training distribution. To give a flavor for our results, suppose that y ∈{1, . . . , k} and that the loss decomposes as a sum of three parts: L(θ; x, y) = P3 v=1 fv(θ; xv, y), where the xv (v = 1, 2, 3) are independent conditioned on y. In this case, we show that we can estimate the risk to error ϵ in poly(k)/ϵ2 samples, independently of the dimension of x or θ, with only very mild additional assumptions on p∗. In Sections 2 and 3 we generalize to a larger family of losses including the log and exponential losses, and extend beyond the multiclass case to conditional random fields. Some intuition behind our result is provided in Figure 1. At a fixed value of x, we can think of each fv as “predicting” that y = j if fv(xv, j) is low and fv(xv, j′) is high for j′ ̸= j. Since f1, f2, and f3 all provide independent signals about y, their rate of agreement gives information about the model accuracy. If f1, f2, and f3 all predict that y = 1, then it is likely that the true y equals 1 and the loss is small. Conversely, if f1, f2, and f3 all predict different values of y, then the loss is likely 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. 1 2 3 4 1 2 3 4 1 2 3 4 y y y f1 f2 f3 1 2 3 4 1 2 3 4 1 2 3 4 y y y f1 f2 f3 Figure 1: Two possible loss profiles at a given value of x. Left: if f1, f2, and f3 are all minimized at the same value of y, that is likely to be the correct value and the total loss is likely to be small. Right: conversely, if f1, f2, and f3 are small at differing values of y, then the loss is likely to be large. large. This intuition is formalized by Dawid and Skene (1979) when the fv measure the 0/1-loss of independent classifiers; in particular, if rv is the prediction of a classifier based on xv, then Dawid and Skene model the rv as independent given y: p(r1, r2, r3) = Pk j=1 p(y = j) Q3 v=1 p(rv | y = j). They then use the learned parameters of this model to compute the 0/1-loss. Partial specification. Dawid and Skene’s approach relies on the prediction rv only taking on k values. In this case, the full distribution p(r1, r2, r3) can be parametrized by k×k conditional probability matrices p(rv |y) and marginals p(y). However, as shown in Figure 1, we want to estimate continuous losses such as the log loss. We must therefore work with the prediction vector fv ∈Rk rather than a single predicted output rv ∈{1, . . . , k}. To fully model p(f1, f2, f3) would require nonparametric estimation, resulting in an undesirable sample complexity exponential in k—in contrast to the discrete case, conditional independence effectively only partially specifies a model for the losses. To sidestep this issue, we make use of the method of moments, which has recently been used to fit non-convex latent variable models (e.g. Anandkumar et al., 2012). In fact, it has a much older history in the econometrics literature, where it is used as a tool for making causal identifications under structural assumptions, even when no explicit form for the likelihood is known (Anderson and Rubin, 1949; 1950; Sargan, 1958; 1959; Hansen, 1982; Powell, 1994; Hansen, 2014). It is this latter perspective that we draw upon. The key insight is that even in the absence of a fully-specified model, certain moment equations–such as E[f1f2 | y] = E[f1 | y]E[f2 | y]–can be derived solely from the assumed conditional independence. Solving these equations yields estimates of E[fv |y], which can in turn be used to estimate the risk. Importantly, our procedure avoids estimation of the full loss distribution p(f1, f2, f3), on which we make no assumptions other than conditional independence. Our paper is structured as follows. In Section 2, we present our basic framework, and state and prove our main result on estimating the risk. In Section 3, we extend our framework in several directions, including to conditional random fields. In Section 4, we present a gradient-based learning algorithm and show that the sample complexity needed for learning is d · poly(k)/ϵ2, where d is the dimension of the parameters θ. In Section 5, we investigate how our method performs empirically. Related Work. While the formal problem of unsupervised risk estimation was only posed recently by Donmez et al. (2010), several older ideas from domain adaptation and semi-supervised learning are also relevant. The covariate shift assumption posits access to labeled samples from a training distribution p0(x, y) for which p∗(y | x) = p0(y | x). If p∗(x) and p0(x) are close, we can approximate p∗by p0 via importance weighting (Shimodaira, 2000; Quiñonero-Candela et al., 2009). If p∗and p0 are not close, another approach is to assume a well-specified discriminative model family Θ, such that p0(y |x) = p∗(y |x) = pθ∗(y |x) for some θ∗∈Θ; then the only error when moving from p0 to p∗is statistical error in the estimation of θ∗(Blitzer et al., 2011; Li et al., 2011). Such assumptions are restrictive—importance weighting only allows small perturbations from p0 to p∗, and mis-specified models of p(y|x) are common in practice; many authors report that mis-specification can lead to severe issues in semi-supervised settings (Merialdo, 1994; Nigam et al., 1998; Cozman and Cohen, 2006; Liang and Klein, 2008; Li and Zhou, 2015). More sophisticated approaches based on discrepancy minimization (Mansour et al., 2009) or learning invariant representations (Ben-David et al., 2006; Johansson et al., 2016) typically also make some form of the covariate shift assumption. Our approach is closest to Dawid and Skene (1979) and some recent extensions (Zhang et al., 2014; Platanios, 2015; Jaffe et al., 2015; Fetaya et al., 2016). Similarly to Zhang et al. (2014) and Jaffe et al. (2015), we use the method of moments for estimating latent-variable models. However, those papers use it for parameter estimation in the face of non-convexity, rather than as a way to avoid full estimation of p(fv |y). The insight that the method of moments works under partial specification lets us extend beyond the simple discrete settings they consider to handle more complex continuous and structured losses. The intriguing work of Balasubramanian et al. (2011) provides an alternate approach 2 label: inputs: y x1 x2 x3 yt−2 yt−1 yt yt+1 xt−2 xt−1 xt xt+1 y z x1 x2 x3 Figure 2: Left: our basic 3-view setup (Assumption 1). Center: Extension 1, to CRFs; the embedding of 3 views into the CRF is indicated in blue. Right: Extension 3, to include a mediating variable z. to continuous losses; they show that the distribution of losses L|y is often approximately Gaussian, and use that to estimate the risk. Among all this work, ours is the first to perform gradient-based learning and the first to handle a structured loss (the log loss for conditional random fields). 2 Framework and Estimation Algorithm We will focus on multiclass classification; we assume an unknown true distribution p∗(x, y) over X × Y, where Y = {1, . . . , k}, and are given unlabeled samples x(1), . . . , x(m) drawn i.i.d. from p∗(x). Given parameters θ ∈Rd and a loss function L(θ; x, y), our goal is to estimate the risk of θ on p∗: R(θ) def = Ex,y∼p∗[L(θ; x, y)]. Throughout, we will make the 3-view assumption: Assumption 1 (3-view). Under p∗, x can be split into x1, x2, x3, which are conditionally independent given y (see Figure 2). Moreover, the loss decomposes additively across views: L(θ; x, y) = A(θ; x) −P3 v=1 fv(θ; xv, y), for some functions A and fv. Note that each xv can be large (e.g. they could be vectors in Rd). If we have V > 3 views, we can combine views to obtain V = 3 without loss of generality. It also suffices for just the fv to be independent rather than the xv. Given only 2 views, the risk can be shown to be unidentifiable in general, although obtaining upper bounds may be possible. We give some examples where Assumption 1 holds, then state and prove our main result (see Section 3 for additional examples). We start with logistic regression, which will be our primary focus later on: Example 1 (Logistic Regression). Suppose that we have a log-linear model pθ(y | x) = exp θ⊤(φ1(x1, y) + φ2(x2, y) + φ3(x3, y)) −A(θ; x) , where x1, x2, and x3 are independent conditioned on y. If our loss function is the log-loss L(θ; x, y) = −log pθ(y | x), then Assumption 1 holds with fv(θ; xv, y) = θ⊤φv(xv, y) and A(θ; x) equal to the partition function of pθ. Assumption 1 does not hold for the hinge loss (see Appendix A for details), but it does hold for a modified hinge loss, where we apply the hinge separately to each view: Example 2 (Modified Hinge Loss). Suppose that L(θ; x, y) = P3 v=1(1 + maxj̸=y θ⊤φv(xv, j) − θ⊤φv(xv, y))+. In other words, L is the sum of 3 hinge losses, one for each view. Then Assumption 1 holds with A = 0, and −fv equal to the hinge loss for view v. The model can also be non-linear within each view xv, as long as the views are combined additively: Example 3 (Neural Networks). Suppose that for each view v we have a neural network whose output is a score for each of the k classes, (fv(θ; xv, j))k j=1. Sum the scores f1 + f2 + f3, apply a soft-max, and evaluate using the log loss; then L(θ; x, y) = A(θ; x) −P3 v=1 fv(θ; xv, y), where A(θ; x) is the log-normalization constant of the softmax, and hence L satisfies Assumption 1. We are now ready to present our main result on recovering the risk R(θ). The key starting point is the conditional risk matrices Mv ∈Rk×k, defined as (suppressing the dependence on θ) (Mv)ij = E[fv(θ; xv, i) | y = j]. (1) In the case of the 0/1-loss, the Mv are confusion matrices; in general, (Mv)ij measures how strongly we predict class i when the true class is j. If we could recover these matrices along with the marginal class probabilities πj def = p∗(y = j), then estimating the risk would be straightforward; indeed, R(θ) = E " A(θ; x) − 3 X v=1 fv(θ; xv, y) # = E[A(θ; x)] − k X j=1 πj 3 X v=1 (Mv)j,j, (2) 3 where E[A(θ; x)] can be estimated from unlabeled data alone. Caveat: Class permutation. Suppose that at training time, we learn to predict whether an image contains the digit 0 or 1. At test time, nothing changes except the definitions of 0 and 1 are reversed. It is clearly impossible to detect this from unlabeled data— mathematically, the risk matrices Mv are only recoverable up to column permutation. We will end up computing the minimum risk over these permutations, which we call the optimistic risk and denote ˜R(θ) def = minσ∈Sym(k) Ex,y∼p∗[L(θ; x, σ(y))]. This equals the true risk as long as θ is at least aligned with the correct classes in the sense that Ex[L(θ; x, j) | y = j] ≤Ex[L(θ; x, j′) | y = j] for j′ ̸= j. The optimal σ can be computed from Mv and π in O k3 time using maximum weight bipartite matching; see Section B for details. Our main result, Theorem 1, says that we can recover both Mv and π up to permutation, with a number of samples that is polynomial in k: Theorem 1. Suppose Assumption 1 holds. Then, for any ϵ, δ ∈(0, 1), we can estimate Mv and π up to column permutation, to error ϵ (in Frobenius and ∞-norm respectively). Our algorithm requires m = poly k, π−1 min, λ−1, τ · log(2/δ) ϵ2 samples to succeed with probability 1 −δ, where πmin def = k min j=1 p∗(y = j), τ def = E P v,jfv(θ; xv, j)2 , and λ def = 3 min v=1 σk(Mv), (3) and σk denotes the kth singular value. Moreover, the algorithm runs in time m · poly(k). Estimates for Mv and π imply an estimate for ˜R via (2); see Algorithm 1 below for details. Importantly, the sample complexity in Theorem 1 depends on the number of classes k, but not on the dimension d of θ. Moreover, Theorem 1 holds even if p∗lies outside the model family θ, and even if the train and test distributions are very different (in fact, the result is agnostic to how the model θ was produced). The only requirement is the 3-view assumption for p∗and that λ, πmin ̸= 0. Let us interpret each term in (3). First, τ tracks the variance of the loss, and we should expect the difficulty of estimating the risk to increase with this variance. The log(2/δ) ϵ2 term is typical and shows up even when estimating the parameter of a random variable to accuracy ϵ from m samples. The π−1 min term appears because, if one of the classes is very rare, we need to wait a long time to observe even a single sample from that class, and even longer to estimate the risk on that class accurately. Perhaps least intuitive is the λ−1 term, which is large e.g. when two classes have similar conditional risk vectors E[(fv(θ; xv, i))k i=1 | y = j]. To see why this matters, consider an extreme where x1, x2, and x3 are independent not only of each other but also of y. Then p∗(y) is completely unconstrained, and it is impossible to estimate R at all. Why does this not contradict Theorem 1? The answer is that in this case, all rows of Mv are equal and hence Mv has rank 1, λ = 0, λ−1 = ∞, and we need infinitely many samples for Theorem 1 to hold; λ measures how close we are to this degenerate case. Proof of Theorem 1. We now outline a proof of Theorem 1. Recall the goal is to estimate the conditional risk matrices Mv, defined as (Mv)ij = E[fv(θ; xv, i) | y = j]; from these we can recover the risk itself using (2). The key insight is that certain moments of p∗(y | x) can be expressed as polynomial functions of the matrices Mv, and therefore we can solve for the Mv even without explicitly estimating p∗. Our approach follows the technical machinery behind the spectral method of moments (e.g., Anandkumar et al., 2012), which we explain below for completeness. Define the loss vector hv(xv) = (fv(θ; xv, i))k i=1, which measures the loss that would be incurred under each of the k classes. The conditional independence of the xv means that E[h1(x1)h2(x2)⊤| y] = E[h1(x1) | y]E[h2(x2) | y]⊤, and similarly for higher-order conditional moments. Marginalizing over y, we see that there is low-rank structure in the moments of h that we can exploit; in particular (letting ⊗denote outer product and A·,j denote the jth column of A): E[hv(xv)] = k X j=1 πj·(Mv)·,j, E[hv(xv)⊗hv′(xv′)] = k X j=1 πj·(Mv)·,j⊗(Mv′)·,j for v ̸= v′, and E[h1(x1)⊗h2(x2)⊗h3(x3)] = k X j=1 πj·(M1)·,j⊗(M2)·,j⊗(M3)·,j. (4) The left-hand-side of each equation can be estimated from unlabeled data; using tensor decomposition (Lathauwer, 2006; Comon et al., 2009; Anandkumar et al., 2012; 2013; Kuleshov et al., 2015), it is 4 Algorithm 1 Algorithm for estimating ˜R(θ) from unlabeled data. 1: Input: unlabeled samples x(1), . . . , x(m) ∼p∗(x). 2: Estimate the left-hand-side of each term in (4) using x(1:m). 3: Compute approximations ˆ Mv and ˆπ to Mv and π using tensor decomposition. 4: Compute σ maximizing Pk j=1 ˆπσ(j) P3 v=1( ˆ Mv)j,σ(j) using maximum bipartite matching. 5: Output: estimated risk, 1 m Pm i=1 A(θ; x(i)) −Pk j=1 ˆπσ(j) P3 v=1( ˆ Mv)j,σ(j). then possible to solve for Mv and π. In particular, we can recover M and π up to permutation: that is, we recover ˆ M and ˆπ such that Mi,j ≈ˆ Mi,σ(j) and πj ≈ˆπσ(j) for some permutation σ ∈Sym(k). This then yields Theorem 1; see Section C for a full proof. Assumption 1 thus yields a set of moment equations (4) whose solution lets us estimate the risk without any labels y. The procedure is summarized in Algorithm 1: we (i) approximate the left-handside of each term in (4) by sample averages; (ii) use tensor decomposition to solve for π and Mv; (iii) use maximum matching to compute the permutation σ; and (iv) use (2) to obtain ˜R from π and Mv. 3 Extensions Theorem 1 provides a basic building block which admits several extensions to more complex model structures. We go over several cases below, omitting most proofs to avoid tedium. Extension 1 (Conditional Random Field). Most importantly, the variable y need not belong to a small discrete set; we can handle structured outputs such as a CRF as long as p∗has the right structure. This contrasts with previous work on unsupervised risk estimation that was restricted to multiclass classification (though in a different vein, it is close to Proposition 8 of Anandkumar et al. (2012)). Suppose that p∗(x1:T , y1:T ) factorizes as a hidden Markov model, and that pθ is a CRF respecting the HMM structure: pθ(y1:T | x1:T ) ∝QT t=2 fθ(yt−1, yt) · QT t=1 gθ(yt, xt). For the log-loss L(θ; x, y) = −log pθ(y1:T | x1:T ), we can exploit the decomposition −log pθ(y1:T | x1:T ) = T X t=2 −log pθ(yt−1, yt | x1:T ) | {z } def = ℓt − T X t=1 −log pθ(yt | x1:T ) | {z } def = ℓ′ t . (5) Each of the components ℓt and ℓ′ t satisfy Assumption 1 (see Figure 2; for ℓt, the views are x1:t−2, xt−1:t, xt+1:T , and for ℓ′ t they are x1:t−1, xt, xt+1:T ). We use Theorem 1 to estimate each E[ℓt], E[ℓ′ t] individually, and thus also the full risk E[L]. (We actually estimate the risk for y2:T −1 | x1:T due to the 3-view assumption failing at the boundaries.) In general, the idea in (5) applies to any structured output problem that is a sum of local 3-view structures. It would be interesting to extend our results to other structures such as more general graphical models (Chaganty and Liang, 2014) and parse trees (Hsu et al., 2012). Extension 2 (Exponential Loss). We can also relax the additivity L=A−f1−f2−f3 in Assumption 1. For instance, suppose L(θ; x, y) = exp(−θ⊤P3 v=1 φv(xv, y)) is the exponential loss. Theorem 1 lets us estimate the matrices Mv corresponding to fv(θ; xv, y) = exp(−θ⊤φv(xv, y)). Then R(θ) = E " 3 Y v=1 fv(θ; xv, y) # = X j πj 3 Y v=1 E [fv(θ; xv, j) | y = j] (6) by conditional independence, so the risk can be computed as P j πj Q3 v=1(Mv)j,j. This idea extends to any loss expressible as L(θ; x, y) = A(θ; x) + Pn i=1 Q3 v=1 f v i (θ; xv, y) for some functions f v i . Extension 3 (Mediating Variable). Assuming that x1:3 are independent conditioned only on y may not be realistic; there might be multiple subclasses of a class (e.g., multiple ways to write the digit 4) which would induce systematic correlations across views. To address this, we show that independence need only hold conditioned on a mediating variable z, rather than on the class y itself. Let z be a refinement of y (in the sense that knowing z determines y) which takes on k′ values, and suppose that the views x1, x2, x3 are independent conditioned on z, as in Figure 2. Then we can 5 try to estimate the risk by defining L′(θ; x, z) = L(θ; x, y(z)), which satisfies Assumption 1. The problem is that the corresponding risk matrices M ′ v will only have k distinct rows and hence have rank k < k′. To fix this, suppose that the loss vector hv(xv) = (fv(xv, j))k j=1 can be extended to a vector h′ v(xv) ∈Rk′, such that (i) the first k coordinates of h′ v(xv) are hv(xv) and (ii) the conditional risk matrix M ′ v corresponding to h′ v has full rank. Then, Theorem 1 allows us to recover M ′ v and hence also Mv (since it is a sub-matrix of M ′ v) and thereby estimate the risk. 4 From Estimation to Learning We now turn our attention to unsupervised learning, i.e., minimizing R(θ) over θ ∈Rd. Unsupervised learning is impossible without some additional information, since even if we could learn the k classes, we wouldn’t know which class had which label (this is the same as the class permutation issue from before). Thus we assume that we have a small amount of information to break this symmetry: Assumption 2 (Seed Model). We have access to a “seed model” θ0 such that ˜R(θ0) = R(θ0). Assumption 2 is very weak — it merely asks for θ0 to be aligned with the true classes on average. We can obtain θ0 from a small amount of labeled data (semi-supervised learning) or by training in a nearby domain (domain adaptation). We define gap(θ0) to be the difference between R(θ0) and the next smallest permutation of the classes–i.e., gap(θ0) def = minσ̸=id E[L(θ0; x, σ(y)) −L(θ0; x, y)]– which will affect the difficulty of learning. For simplicity we will focus on the case of logistic regression, and show how to learn given only Assumptions 1 and 2. Our algorithm extends to general losses, as we show in Section F. Learning from moments. Note that for logistic regression (Example 1), we have R(θ) = E h A(θ; x) −θ⊤ 3 X v=1 φv(xv, y) i = E[A(θ; x)] −θ⊤¯φ, where ¯φ def = 3 X v=1 E[φv(xv, y)]. (7) From (7), we see that it suffices to estimate ¯φ, after which all terms on the right-hand-side of (7) are known. Given an approximation ˆφ to ¯φ (we will show how to obtain ˆφ below), we can learn a near-optimal θ by solving the following convex optimization problem: ˆθ = arg min ∥θ∥2≤ρ E[A(θ; x)] −θ⊤ˆφ. (8) In practice we would need to approximate E[A(θ; x)] by samples, but we ignore this for simplicity (it generally only contributes lower-order terms to the error). The reason for the ℓ2-constraint on θ is that it imparts robustness to the error between ˆφ and ¯φ. In particular (see Section D for a proof): Lemma 1. Suppose ∥ˆφ−¯φ∥2 ≤ϵ. Then the output ˆθ from (8) satisfies R(ˆθ) ≤min∥θ∥2≤ρ R(θ)+2ϵρ. If the optimal θ∗has ℓ2-norm at most ρ, Lemma 1 says that ˆθ nearly minimizes the risk: R(ˆθ) ≤ R(θ∗) + 2ϵρ. The problem of learning θ thus reduces to computing a good estimate ˆφ of ¯φ. Computing ˆφ. Estimating ¯φ can be done in a manner similar to how we estimated R(θ) in Section 2. In addition to the conditional risk matrix Mv ∈Rk×k, we compute the conditional moment matrix Gv ∈Rdk×k, which tracks the conditional expectation of φv: (Gv)i+(r−1)k,j def = E[φv(θ; xv, i)r | y = j], where r indexes 1, . . . , d. We then have ¯φr = Pk j=1 πj P3 v=1(Gv)j+(r−1)k,j. As in Theorem 1, we can solve for G1, G2, and G3 using a tensor factorization similar to (4), though some care is needed to avoid explicitly forming the (kd) × (kd) × (kd) tensor that would result (since O k3d3 memory is intractable for even moderate values of d). We take a standard approach based on random projections (Halko et al., 2011) and described in Section 6.1.2 of Anandkumar et al. (2013). We refer the reader to the aforementioned references for details, and cite only the resulting sample complexity and runtime, which are both roughly d times larger than in Theorem 1. Theorem 2. Suppose that Assumptions 1 and 2 hold. Let δ < 1 and ϵ < min(1, gap(θ0)). Then, given m = poly k, π−1 min, λ−1, τ · log(2/δ) ϵ2 samples, where λ and τ are as defined in (3), 6 Figure 3: A few sample train images (left) and test images (right) from the modified MNIST data set. 0 2 4 6 8 10 Distortion (a) 0.0 0.2 0.4 0.6 0.8 1.0 Estimated Risk validation error entropy tensor tensor + L-BFGS true (a) 0 2 4 6 8 10 Distortion (a) 0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 Risk R(θ) baseline tensor + L-BFGS oracle (b) 0 2 4 6 8 10 Distortion (λ) 0.0 0.2 0.4 0.6 0.8 1.0 1.2 Risk R(θ) baseline tensor + L-BFGS oracle (c) Figure 4: Results on the modified MNIST data set. (a) Risk estimation for varying degrees of distortion a. (b) Domain adaptation with 10,000 training and 10,000 test examples. (c) Domain adaptation with 300 training and 10,000 test examples. with probability 1 −δ we can recover Mv and π to error ϵ, and Gv to error (B/τ)ϵ, where B2 = E[P i,v ∥φv(xv, i)∥2 2] measures the ℓ2-norm of the features. The algorithm runs in time O (d (m + poly(k))), and the errors are in Frobenius norm for M and G, and ∞-norm for π. See Section E for a proof sketch. Whereas before we estimated the risk matrix Mv to error ϵ, now we estimate the gradient matrix Gv (and hence ¯φ) to error (B/τ)ϵ. To achieve error ϵ in estimating Gv requires (B/τ)2 · poly k, π−1 min, λ−1, τ log(2/δ) ϵ2 samples, which is (B/τ)2 times as large as in Theorem 1. The quantity (B/τ)2 typically grows as O(d), and so the sample complexity needed to estimate ¯φ is typically d times larger than the sample complexity needed to estimate R. This matches the behavior of the supervised case where we need d times as many samples for learning as compared to (supervised) risk estimation of a fixed model. Summary. We have shown how to perform unsupervised logistic regression, given only a seed model θ0. This enables unsupervised learning under fairly weak assumptions (only the multi-view and seed model assumptions) even for mis-specified models and zero train-test overlap, and without assuming covariate shift. See Section F for learning under more general losses. 5 Experiments To better understand the behavior of our algorithms, we perform experiments on a version of the MNIST data set that is modified to ensure that the 3-view assumption holds. To create an image I, we sample a class in {0, . . . , 9}, then sample 3 images I1, I2, I3 at random from that class, letting every third pixel in I come from the respective image Iv. This guarantees there are 3 conditionally independent views. To explore train-test variation, we dim pixel p in the image by exp (a (∥p −p0∥2 −0.4)), where p0 is the image center and distances are normalized to be at most 1. We show example images for a = 0 (train) and a = 5 (a possible test distribution) in Figure 3. Risk estimation. We use Algorithm 1 to perform unsupervised risk estimation for a model trained on a = 0, testing on various values of a ∈[0, 10]. We trained the model with AdaGrad (Duchi et al., 2010) on 10,000 training examples, and used 10,000 test examples to estimate the risk. To solve for π and M in (4), we first use the tensor power method implemented by Chaganty and Liang (2013) to initialize, and then locally minimize a weighted ℓ2-norm of the moment errors in (4) using L-BFGS. We compared with two other methods: (i) validation error from held-out samples (which would be valid if train = test), and (ii) predictive entropy P j −pθ(j | x) log pθ(j | x) on the test set (which would be valid if the predictions were well-calibrated). The results are shown in Figure 4a; both the tensor method in isolation and tensor + L-BFGS estimate the risk accurately, with the latter performing slightly better. Unsupservised domain adaptation. We next evaluate our learning algorithm in an unsupervised domain adaptation setting, where we receive labeled training data at a = 0 and unlabeled test data at a different value of a. We use the training data to obtain a seed model θ0, and then perform 7 unsupervised learning (Section 4), setting ρ = 10 in (8). The results are shown in Figure 4b. For small values of a, our algorithm performs worse than the baseline of directly using θ0, likely due to finite-sample effects. However, our algorithm is far more robust as a increases, and tracks the performance of an oracle that was trained on the same distribution as the test examples. Because we only need to provide our algorithm with a seed model for disentangling the classes, we do not need much data when training θ0. To verify this, we tried obtaining θ0 from only 300 labeled examples. Tensor decomposition sometimes led to bad initializations in this limited data regime, in which case we obtained a different θ0 by training with a smaller step size. The results are shown in Figure 4c. Our algorithm generally performs well, but has higher variability than before, seemingly due to higher condition number of the matrices Mv. Summary. Our experiments show that given 3 views, we can estimate the risk and perform unsupervised domain adaptation, even with limited labeled data from the source domain. 6 Discussion We have presented a method for estimating the risk from unlabeled data, which relies only on conditional independence structure and hence makes no parametric assumptions about the true distribution. Our approach applies to a large family of losses and extends beyond classification tasks to conditional random fields. We can also perform unsupervised learning given only a seed model that can distinguish between classes in expectation; the seed model can be trained on a related domain, on a small amount of labeled data, or any combination of the two, and thus provides a pleasingly general formulation highlighting the similarities between domain adaptation and semi-supervised learning. Previous approaches to domain adaptation and semi-supervised learning have also exploited multiview structure. Given two views, Blitzer et al. (2011) perform domain adaptation with zero source/target overlap (covariate shift is still assumed). Two-view approaches (e.g. co-training and CCA) are also used in semi-supervised learning (Blum and Mitchell, 1998; Ando and Zhang, 2007; Kakade and Foster, 2007; Balcan and Blum, 2010). These methods all assume some form of low noise or low regret, as do, e.g., transductive SVMs (Joachims, 1999). By focusing on the central problem of risk estimation, our work connects multi-view learning approaches for domain adaptation and semi-supervised learning, and removes covariate shift and low-noise/low-regret assumptions (though we make stronger independence assumptions, and specialize to discrete prediction tasks). In addition to reliability and unsupervised learning, our work is motivated by the desire to build machine learning systems with contracts, a challenge recently posed by Bottou (2015); the goal is for machine learning systems to satisfy a well-defined input-output contract in analogy with software systems (Sculley et al., 2015). Theorem 1 provides the contract that under the 3-view assumption the test error is close to our estimate of the test error; the typical (weak) contract of ML systems is that if train and test are similar, then the test error is close to the training error. One other interesting contract is to provide prediction regions that contain the truth with probability 1 −ϵ (Shafer and Vovk, 2008; Khani et al., 2016), which includes abstaining when uncertain as a special case (Li et al., 2011). The most restrictive part of our framework is the three-view assumption, which is inappropriate if the views are not completely independent or if the data have structure that is not captured in terms of multiple views. Since Balasubramanian et al. (2011) obtain results under Gaussianity (which would be implied by many somewhat dependent views), we are optimistic that unsupervised risk estimation is possible for a wider family of structures. Along these lines, we end with the following questions: Open question. In the 3-view setting, suppose the views are not completely independent. Is it still possible to estimate the risk? How does the degree of dependence affect the number of views needed? Open question. Given only two independent views, can one obtain an upper bound on the risk R(θ)? The results of this paper have caused us to adopt the following perspective: To leverage unlabeled data, we should make generative structural assumptions, but still optimize discriminative model performance. This hybrid approach allows us to satisfy the traditional machine learning goal of predictive accuracy, while handling lack of supervision and under-specification in a principled way. Perhaps, then, what is truly needed for learning is understanding the structure of a domain. Acknowledgments. This research was supported by a Fannie & John Hertz Foundation Fellowship, a NSF Graduate Research Fellowship, and a Future of Life Institute grant. 8 References A. Anandkumar, D. Hsu, and S. M. Kakade. A method of moments for mixture models and hidden Markov models. In COLT, 2012. A. Anandkumar, R. Ge, D. Hsu, S. M. Kakade, and M. Telgarsky. Tensor decompositions for learning latent variable models. arXiv, 2013. T. W. Anderson and H. Rubin. Estimation of the parameters of a single equation in a complete system of stochastic equations. The Annals of Mathematical Statistics, pages 46–63, 1949. T. W. Anderson and H. Rubin. The asymptotic properties of estimates of the parameters of a single equation in a complete system of stochastic equations. The Annals of Mathematical Statistics, pages 570–582, 1950. R. K. Ando and T. Zhang. Two-view feature generation model for semi-supervised learning. In COLT, 2007. K. Balasubramanian, P. Donmez, and G. Lebanon. Unsupervised supervised learning II: Margin-based classification without labels. JMLR, 12:3119–3145, 2011. M. Balcan and A. Blum. A discriminative model for semi-supervised learning. JACM, 57(3), 2010. S. Ben-David, J. Blitzer, K. Crammer, and F. Pereira. Analysis of representations for domain adaptation. In NIPS, pages 137–144, 2006. J. Blitzer, S. Kakade, and D. P. Foster. Domain adaptation with coupled subspaces. In AISTATS, 2011. A. Blum and T. Mitchell. Combining labeled and unlabeled data with co-training. In COLT, 1998. L. Bottou. Two high stakes challenges in machine learning. Invited talk at ICML, 2015. A. Chaganty and P. Liang. Spectral experts for estimating mixtures of linear regressions. In ICML, 2013. A. Chaganty and P. Liang. Estimating latent-variable graphical models using moments and likelihoods. In ICML, 2014. P. Comon, X. Luciani, and A. L. D. Almeida. Tensor decompositions, alternating least squares and other tales. Journal of Chemometrics, 23(7):393–405, 2009. F. Cozman and I. Cohen. Risks of semi-supervised learning: How unlabeled data can degrade performance of generative classifiers. In Semi-Supervised Learning. 2006. A. P. Dawid and A. M. Skene. Maximum likelihood estimation of observer error-rates using the EM algorithm. Applied Statistics, 1:20–28, 1979. P. Donmez, G. Lebanon, and K. Balasubramanian. Unsupervised supervised learning I: Estimating classification and regression errors without labels. JMLR, 11:1323–1351, 2010. J. Duchi, E. Hazan, and Y. Singer. Adaptive subgradient methods for online learning and stochastic optimization. In COLT, 2010. J. Edmonds and R. M. Karp. Theoretical improvements in algorithmic efficiency for network flow problems. JACM, 19(2):248–264, 1972. E. Fetaya, B. Nadler, A. Jaffe, Y. Kluger, and T. Jiang. Unsupervised ensemble learning with dependent classifiers. In AISTATS, pages 351–360, 2016. N. Halko, P.-G. Martinsson, and J. Tropp. Finding structure with randomness: Probabilistic algorithms for constructing approximate matrix decompositions. SIAM Review, 53:217–288, 2011. L. P. Hansen. Large sample properties of generalized method of moments estimators. Econometrica, 1982. L. P. Hansen. Uncertainty outside and inside economic models. Journal of Political Economy, 122(5), 2014. D. Hsu, S. M. Kakade, and P. Liang. Identifiability and unmixing of latent parse trees. In NIPS, 2012. A. Jaffe, B. Nadler, and Y. Kluger. Estimating the accuracies of multiple classifiers without labeled data. In AISTATS, pages 407–415, 2015. T. Joachims. Transductive inference for text classification using support vector machines. In ICML, 1999. F. Johansson, U. Shalit, and D. Sontag. Learning representations for counterfactual inference. In ICML, 2016. S. M. Kakade and D. P. Foster. Multi-view regression via canonical correlation analysis. In COLT, 2007. F. Khani, M. Rinard, and P. Liang. Unanimous prediction for 100% precision with application to learning semantic mappings. In ACL, 2016. V. Kuleshov, A. Chaganty, and P. Liang. Tensor factorization via matrix factorization. In AISTATS, 2015. L. D. Lathauwer. A link between the canonical decomposition in multilinear algebra and simultaneous matrix diagonalization. SIAM Journal of Matrix Analysis and Applications, 28(3):642–666, 2006. L. Li, M. L. Littman, T. J. Walsh, and A. L. Strehl. Knows what it knows: a framework for self-aware learning. Machine learning, 82(3):399–443, 2011. Y. Li and Z. Zhou. Towards making unlabeled data never hurt. IEEE TPAMI, 37(1):175–188, 2015. P. Liang and D. Klein. Analyzing the errors of unsupervised learning. In HLT/ACL, 2008. Y. Mansour, M. Mohri, and A. Rostamizadeh. Domain adaptation: Learning bounds and algorithms. In COLT, 2009. B. Merialdo. Tagging English text with a probabilistic model. Computational Linguistics, 20:155–171, 1994. K. Nigam, A. McCallum, S. Thrun, and T. Mitchell. Learning to classify text from labeled and unlabeled documents. In Association for the Advancement of Artificial Intelligence (AAAI), 1998. E. A. Platanios. Estimating accuracy from unlabeled data. Master’s thesis, Carnegie Mellon University, 2015. J. L. Powell. Estimation of semiparametric models. In Handbook of Econometrics, volume 4. 1994. J. Quiñonero-Candela, M. Sugiyama, A. Schwaighofer, and N. D. Lawrence. Dataset shift in machine learning. The MIT Press, 2009. J. D. Sargan. The estimation of economic relationships using instrumental variables. Econometrica, 1958. J. D. Sargan. The estimation of relationships with autocorrelated residuals by the use of instrumental variables. Journal of the Royal Statistical Society: Series B (Statistical Methodology), pages 91–105, 1959. D. Sculley, G. Holt, D. Golovin, E. Davydov, T. Phillips, D. Ebner, V. Chaudhary, M. Young, J. Crespo, and D. Dennison. Hidden technical debt in machine learning systems. In NIPS, pages 2494–2502, 2015. G. Shafer and V. Vovk. A tutorial on conformal prediction. JMLR, 9:371–421, 2008. H. Shimodaira. Improving predictive inference under covariate shift by weighting the log-likelihood function. Journal of Statistical Planning and Inference, 90:227–244, 2000. J. Steinhardt, G. Valiant, and S. Wager. Memory, communication, and statistical queries. In COLT, 2016. N. Tomizawa. On some techniques useful for solution of transportation network problems. Networks, 1971. Y. Zhang, X. Chen, D. Zhou, and M. I. Jordan. Spectral methods meet EM: A provably optimal algorithm for crowdsourcing. arXiv, 2014. 9 | 2016 | 538 |
6,481 | Deep Learning without Poor Local Minima Kenji Kawaguchi Massachusetts Institute of Technology kawaguch@mit.edu Abstract In this paper, we prove a conjecture published in 1989 and also partially address an open problem announced at the Conference on Learning Theory (COLT) 2015. With no unrealistic assumption, we first prove the following statements for the squared loss function of deep linear neural networks with any depth and any widths: 1) the function is non-convex and non-concave, 2) every local minimum is a global minimum, 3) every critical point that is not a global minimum is a saddle point, and 4) there exist “bad” saddle points (where the Hessian has no negative eigenvalue) for the deeper networks (with more than three layers), whereas there is no bad saddle point for the shallow networks (with three layers). Moreover, for deep nonlinear neural networks, we prove the same four statements via a reduction to a deep linear model under the independence assumption adopted from recent work. As a result, we present an instance, for which we can answer the following question: how difficult is it to directly train a deep model in theory? It is more difficult than the classical machine learning models (because of the non-convexity), but not too difficult (because of the nonexistence of poor local minima). Furthermore, the mathematically proven existence of bad saddle points for deeper models would suggest a possible open problem. We note that even though we have advanced the theoretical foundations of deep learning and non-convex optimization, there is still a gap between theory and practice. 1 Introduction Deep learning has been a great practical success in many fields, including the fields of computer vision, machine learning, and artificial intelligence. In addition to its practical success, theoretical results have shown that deep learning is attractive in terms of its generalization properties (Livni et al., 2014; Mhaskar et al., 2016). That is, deep learning introduces good function classes that may have a low capacity in the VC sense while being able to represent target functions of interest well. However, deep learning requires us to deal with seemingly intractable optimization problems. Typically, training of a deep model is conducted via non-convex optimization. Because finding a global minimum of a general non-convex function is an NP-complete problem (Murty & Kabadi, 1987), a hope is that a function induced by a deep model has some structure that makes the nonconvex optimization tractable. Unfortunately, it was shown in 1992 that training a very simple neural network is indeed NP-hard (Blum & Rivest, 1992). In the past, such theoretical concerns in optimization played a major role in shrinking the field of deep learning. That is, many researchers instead favored classical machining learning models (with or without a kernel approach) that require only convex optimization. While the recent great practical successes have revived the field, we do not yet know what makes optimization in deep learning tractable in theory. In this paper, as a step toward establishing the optimization theory for deep learning, we prove a conjecture noted in (Goodfellow et al., 2016) for deep linear networks, and also address an open problem announced in (Choromanska et al., 2015b) for deep nonlinear networks. Moreover, for 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. both the conjecture and the open problem, we prove more general and tighter statements than those previously given (in the ways explained in each section). 2 Deep linear neural networks Given the absence of a theoretical understanding of deep nonlinear neural networks, Goodfellow et al. (2016) noted that it is beneficial to theoretically analyze the loss functions of simpler models, i.e., deep linear neural networks. The function class of a linear multilayer neural network only contains functions that are linear with respect to inputs. However, their loss functions are nonconvex in the weight parameters and thus nontrivial. Saxe et al. (2014) empirically showed that the optimization of deep linear models exhibits similar properties to those of the optimization of deep nonlinear models. Ultimately, for theoretical development, it is natural to start with linear models before working with nonlinear models (as noted in Baldi & Lu, 2012), and yet even for linear models, the understanding is scarce when the models become deep. 2.1 Model and notation We begin by defining the notation. Let H be the number of hidden layers, and let (X, Y ) be the training data set, with Y ∈Rdy×m and X ∈Rdx×m, where m is the number of data points. Here, dy ≥1 and dx ≥1 are the number of components (or dimensions) of the outputs and inputs, respectively. Let Σ = Y XT (XXT )−1XY T . We denote the model (weight) parameters by W, which consists of the entries of the parameter matrices corresponding to each layer: WH+1 ∈ Rdy×dH, . . . , Wk ∈Rdk×dk−1, . . . , W1 ∈Rd1×dx. Here, dk represents the width of the k-th layer, where the 0-th layer is the input layer and the (H + 1)-th layer is the output layer (i.e., d0 = dx and dH+1 = dy). Let Idk be the dk × dk identity matrix. Let p = min(dH, . . . , d1) be the smallest width of a hidden layer. We denote the (j, i)-th entry of a matrix M by Mj,i. We also denote the j-th row vector of M by Mj,∙and the i-th column vector of M by M∙,i. We can then write the output of a feedforward deep linear model, Y (W, X) ∈Rdy×m, as Y (W, X) = WH+1WHWH−1 ∙∙∙W2W1X. We consider one of the most widely used loss functions, squared error loss: ˉL(W) = 1 2 m X i=1 ∥Y (W, X)∙,i −Y∙,i∥2 2 = 1 2∥Y (W, X) −Y ∥2 F , where ∥∙∥F is the Frobenius norm. Note that 2 m ˉL(W) is the usual mean squared error, for which all of our results hold as well, since multiplying ˉL(W) by a constant in W results in an equivalent optimization problem. 2.2 Background Recently, Goodfellow et al. (2016) remarked that when Baldi & Hornik (1989) proved Proposition 2.1 for shallow linear networks, they stated Conjecture 2.2 without proof for deep linear networks. Proposition 2.1 (Baldi & Hornik, 1989: shallow linear network) Assume that H = 1 (i.e., Y (W, X) = W2W1X), assume that XXT and XY T are invertible, assume that Σ has dy distinct eigenvalues, and assume that p < dx, p < dy and dy = dx (e.g., an autoencoder). Then, the loss function ˉL(W) has the following properties: (i) It is convex in each matrix W1 (or W2) when the other W2 (or W1) is fixed. (ii) Every local minimum is a global minimum. Conjecture 2.2 (Baldi & Hornik, 1989: deep linear network) Assume the same set of conditions as in Proposition 2.1 except for H = 1. Then, the loss function ˉL(W) has the following properties: (i) For any k ∈{1, . . . , H + 1}, it is convex in each matrix Wk when for all k′ ̸= k, Wk′ is fixed. (ii) Every local minimum is a global minimum. 2 Baldi & Lu (2012) recently provided a proof for Conjecture 2.2 (i), leaving the proof of Conjecture 2.2 (ii) for future work. They also noted that the case of p ≥dx = dx is of interest, but requires further analysis, even for a shallow network with H = 1. An informal discussion of Conjecture 2.2 can be found in (Baldi, 1989). In Appendix D, we provide a more detailed discussion of this subject. 2.3 Results We now state our main theoretical results for deep linear networks, which imply Conjecture 2.2 (ii) as well as obtain further information regarding the critical points with more generality. Theorem 2.3 (Loss surface of deep linear networks) Assume that XXT and XY T are of full rank with dy ≤dx and Σ has dy distinct eigenvalues. Then, for any depth H ≥1 and for any layer widths and any input-output dimensions dy, dH, dH−1, . . . , d1, dx ≥1 (the widths can arbitrarily differ from each other and from dy and dx), the loss function ˉL(W) has the following properties: (i) It is non-convex and non-concave. (ii) Every local minimum is a global minimum. (iii) Every critical point that is not a global minimum is a saddle point. (iv) If rank(WH ∙∙∙W2) = p, then the Hessian at any saddle point has at least one (strictly) negative eigenvalue.1 Corollary 2.4 (Effect of deepness on the loss surface) Assume the same set of conditions as in Theorem 2.3 and consider the loss function ˉL(W). For three-layer networks (i.e., H = 1), the Hessian at any saddle point has at least one (strictly) negative eigenvalue. In contrast, for networks deeper than three layers (i.e., H ≥2), there exist saddle points at which the Hessian does not have any negative eigenvalue. The assumptions of having full rank and distinct eigenvalues in the training data matrices in Theorem 2.3 are realistic and practically easy to satisfy, as discussed in previous work (e.g., Baldi & Hornik, 1989). In contrast to related previous work (Baldi & Hornik, 1989; Baldi & Lu, 2012), we do not assume the invertibility of XY T , p < dx, p < dy nor dy = dx. In Theorem 2.3, p ≥dx is allowed, as well as many other relationships among the widths of the layers. Therefore, we successfully proved Conjecture 2.2 (ii) and a more general statement. Moreover, Theorem 2.3 (iv) and Corollary 2.4 provide additional information regarding the important properties of saddle points. Theorem 2.3 presents an instance of a deep model that would be tractable to train with direct greedy optimization, such as gradient-based methods. If there are “poor” local minima with large loss values everywhere, we would have to search the entire space,2 the volume of which increases exponentially with the number of variables. This is a major cause of NP-hardness for non-convex optimization. In contrast, if there are no poor local minima as Theorem 2.3 (ii) states, then saddle points are the main remaining concern in terms of tractability.3 Because the Hessian of ˉL(W) is Lipschitz continuous, if the Hessian at a saddle point has a negative eigenvalue, it starts appearing as we approach the saddle point. Thus, Theorem 2.3 and Corollary 2.4 suggest that for 1-hidden layer networks, training can be done in polynomial time with a second order method or even with a modified stochastic gradient decent method, as discussed in (Ge et al., 2015). For deeper networks, Corollary 2.4 states that there exist “bad” saddle points in the sense that the Hessian at the point has no negative eigenvalue. However, we know exactly when this can happen from Theorem 2.3 (iv) in our deep models. We leave the development of efficient methods to deal with such a bad saddle point in general deep models as an open problem. 3 Deep nonlinear neural networks Now that we have obtained a comprehensive understanding of the loss surface of deep linear models, we discuss deep nonlinear models. For a practical deep nonlinear neural network, our theoretical results so far for the deep linear models can be interpreted as the following: depending on the 1If H = 1, to be succinct, we define WH ∙∙∙W2 = W1 ∙∙∙W2 ≜Id1, with a slight abuse of notation. 2Typically, we do this by assuming smoothness in the values of the loss function. 3Other problems such as the ill-conditioning can make it difficult to obtain a fast convergence rate. 3 nonlinear activation mechanism and architecture, training would not be arbitrarily difficult. While theoretical formalization of this intuition is left to future work, we address a recently proposed open problem for deep nonlinear networks in the rest of this section. 3.1 Model We use the same notation as for the deep linear models, defined in the beginning of Section 2.1. The output of deep nonlinear neural network, ˆY (W, X) ∈Rdy×m, is defined as ˆY(W, X) = qσH+1(WH+1σH(WHσH−1(WH−1 ∙∙∙σ2(W2σ1(W1X)) ∙∙∙))), where q ∈R is simply a normalization factor, the value of which is specified later. Here, σk : Rdk×m →Rdk×m is the element-wise rectified linear function: σk b11 . . . b1m ... ... ... bdk1 ∙∙∙ bdkm = ˉσ(b11) . . . ˉσ(b1m) ... ... ... ˉσ(bdk1) ∙∙∙ ˉσ(bdkm) , where ˉσ(bij) = max(0, bij). In practice, we usually set σH+1 to be an identity map in the last layer, in which case all our theoretical results still hold true. 3.2 Background Following the work by Dauphin et al. (2014), Choromanska et al. (2015a) investigated the connection between the loss functions of deep nonlinear networks and a function well-studied via random matrix theory (i.e., the Hamiltonian of the spherical spin-glass model). They explained that their theoretical results relied on several unrealistic assumptions. Later, Choromanska et al. (2015b) suggested at the Conference on Learning Theory (COLT) 2015 that discarding these assumptions is an important open problem. The assumptions were labeled A1p, A2p, A3p, A4p, A5u, A6u, and A7p. In this paper, we successfully discard most of these assumptions. In particular, we only use a weaker version of assumptions A1p and A5u. We refer to the part of assumption A1p (resp. A5u) that corresponds only to the model assumption as A1p-m (resp. A5u-m). Note that assumptions A1p-m and A5u-m are explicitly used in the previous work (Choromanska et al., 2015a) and included in A1p and A5u (i.e., we are not making new assumptions here). As the model ˆY (W, X) ∈Rdy×m represents a directed acyclic graph, we can express an output from one of the units in the output layer as ˆY (W, X)j,i = q Ψ X p=1 [Xi](j,p)[Zi](j,p) H+1 Y k=1 w(k) (j,p). (1) Here, Ψ is the total number of paths from the inputs to each j-th output in the directed acyclic graph. In addition, [Xi](j,p) ∈R represents the entry of the i-th sample input datum that is used in the p-th path of the j-th output. For each layer k, w(k) (j,p) ∈R is the entry of Wk that is used in the p-th path of the j-th output. Finally, [Zi](j,p) ∈{0, 1} represents whether the p-th path of the j-th output is active ([Zi](j,p) = 1) or not ([Zi](j,p) = 0) for each sample i as a result of the rectified linear activation. Assumption A1p-m assumes that the Z’s are Bernoulli random variables with the same probability of success, Pr([Zi](j,p) = 1) = ρ for all i and (j, p). Assumption A5u-m assumes that the Z’s are independent from the input X’s and parameters w’s. With assumptions A1p-m and A5u-m, we can write EZ[ ˆY (W, X)j,i] = q PΨ p=1[Xi](j,p)ρ QH+1 k=1 w(k) (j,p). Choromanska et al. (2015b) noted that A6u is unrealistic because it implies that the inputs are not shared among the paths. In addition, Assumption A5u is unrealistic because it implies that the activation of any path is independent of the input data. To understand all of the seven assumptions (A1p, A2p, A3p, A4p, A5u, A6u, and A7p), we note that Choromanska et al. (2015b,a) used these seven assumptions to reduce their loss functions of nonlinear neural networks to: Lprevious(W) = 1 λH/2 λ X i1,i2,...,iH+1=1 Xi1,i2,...,iH+1 H+1 Y k=1 wik subject to 1 λ λ X i=1 w2 i = 1, 4 where λ ∈R is a constant related to the size of the network. For our purpose, the detailed definitions of the symbols are not important (X and w are defined in the same way as in equation 1). Here, we point out that the target function Y has disappeared in the loss Lprevious(W) (i.e., the loss value does not depend on the target function). That is, whatever the data points of Y are, their loss values are the same. Moreover, the nonlinear activation function has disappeared in Lprevious(W) (and the nonlinearity is not taken into account in X or w). In the next section, by using only a strict subset of the set of these seven assumptions, we reduce our loss function to a more realistic loss function of an actual deep model. Proposition 3.1 (High-level description of a main result in Choromanska et al., 2015a) Assume A1p (including A1p-m), A2p, A3p, A4p, A5u (including A5u-m), A6u, and A7p (Choromanska et al., 2015b). Furthermore, assume that dy = 1. Then, the expected loss of each sample datum, Lprevious(W), has the following property: above a certain loss value, the number of local minima diminishes exponentially as the loss value increases. 3.3 Results We now state our theoretical result, which partially address the aforementioned open problem. We consider loss functions for all the data points and all possible output dimensionalities (i.e., vectoredvalued output). More concretely, we consider the squared error loss with expectation, L(W) = 1 2∥EZ[ ˆY (W, X) −Y ]∥2 F . Corollary 3.2 (Loss surface of deep nonlinear networks) Assume A1p-m and A5u-m. Let q = ρ−1. Then, we can reduce the loss function of the deep nonlinear model L(W) to that of the deep linear model ˉL(W). Therefore, with the same set of conditions as in Theorem 2.3, the loss function of the deep nonlinear model has the following properties: (i) It is non-convex and non-concave. (ii) Every local minimum is a global minimum. (iii) Every critical point that is not a global minimum is a saddle point. (iv) The saddle points have the properties stated in Theorem 2.3 (iv) and Corollary 2.4. Comparing Corollary 3.2 and Proposition 3.1, we can see that we successfully discarded assumptions A2p, A3p, A4p, A6u, and A7p while obtaining a tighter statement in the following sense: Corollary 3.2 states with fewer unrealistic assumptions that there is no poor local minimum, whereas Proposition 3.1 roughly asserts with more unrealistic assumptions that the number of poor local minimum may be not too large. Furthermore, our model ˆY is strictly more general than the model analyzed in (Choromanska et al., 2015a,b) (i.e., this paper’s model class contains the previous work’s model class but not vice versa). 4 Proof Idea and Important lemmas In this section, we provide overviews of the proofs of the theoretical results. Our proof approach largely differs from those in previous work (Baldi & Hornik, 1989; Baldi & Lu, 2012; Choromanska et al., 2015a,b). In contrast to (Baldi & Hornik, 1989; Baldi & Lu, 2012), we need a different approach to deal with the “bad” saddle points that start appearing when the model becomes deeper (see Section 2.3), as well as to obtain more comprehensive properties of the critical points with more generality. While the previous proofs heavily rely on the first-order information, the main parts of our proofs take advantage of the second order information. In contrast, Choromanska et al. (2015a,b) used the seven assumptions to relate the loss functions of deep models to a function previously analyzed with a tool of random matrix theory. With no reshaping assumptions (A3p, A4p, and A6u), we cannot relate our loss function to such a function. Moreover, with no distributional assumptions (A2p and A6u) (except the activation), our Hessian is deterministic, and therefore, even random matrix theory itself is insufficient for our purpose. Furthermore, with no spherical constraint assumption (A7p), the number of local minima in our loss function can be uncountable. One natural strategy to proceed toward Theorem 2.3 and Corollary 3.2 would be to use the first-order and second-order necessary conditions of local minima (e.g., the gradient is zero and the Hessian is 5 positive semidefinite).4 However, are the first-order and second-order conditions sufficient to prove Theorem 2.3 and Corollary 3.2? Corollaries 2.4 show that the answer is negative for deep models with H ≥2, while it is affirmative for shallow models with H = 1. Thus, for deep models, a simple use of the first-order and second-order information is insufficient to characterize the properties of each critical point. In addition to the complexity of the Hessian of the deep models, this suggests that we must strategically extract the second order information. Accordingly, in section 4.2, we obtain an organized representation of the Hessian in Lemma 4.3 and strategically extract the information in Lemmas 4.4 and 4.6. With the extracted information, we discuss the proofs of Theorem 2.3 and Corollary 3.2 in section 4.3. 4.1 Notations Let M ⊗M ′ be the Kronecker product of M and M ′. Let Dvec(W T k )f(∙) = ∂f(∙) ∂vec(W T k ) be the partial derivative of f with respect to vec(W T k ) in the numerator layout. That is, if f : Rdin →Rdout, we have Dvec(W T k )f(∙) ∈Rdout×(dkdk−1). Let R(M) be the range (or the column space) of a matrix M. Let M −be any generalized inverse of M. When we write a generalized inverse in a condition or statement, we mean it for any generalized inverse (i.e., we omit the universal quantifier over generalized inverses, as this is clear). Let r = (Y (W, X) −Y )T ∈Rm×dy be an error matrix. Let C = WH+1 ∙∙∙W2 ∈Rdy×d1. When we write Wk ∙∙∙Wk′, we generally intend that k > k′ and the expression denotes a product over Wj for integer k ≥j ≥k′. For notational compactness, two additional cases can arise: when k = k′, the expression denotes simply Wk, and when k < k′, it denotes Idk. For example, in the statement of Lemma 4.1, if we set k := H + 1, we have that WH+1WH ∙∙∙WH+2 ≜Idy. In Lemma 4.6 and the proofs of Theorems 2.3, we use the following additional notation. We denote an eigendecomposition of Σ as Σ = UΛU T , where the entries of the eigenvalues are ordered as Λ1,1 > ∙∙∙> Λdy,dy with corresponding orthogonal eigenvector matrix U = [u1, . . . , udy]. For each k ∈{1, . . . dy}, uk ∈Rdy×1 is a column eigenvector. Let ˉp = rank(C) ∈ {1, . . . , min(dy, p)}. We define a matrix containing the subset of the ˉp largest eigenvectors as Uˉp = [u1, . . . , uˉp]. Given any ordered set Iˉp = {i1, . . . , iˉp | 1 ≤i1 < ∙∙∙< iˉp ≤min(dy, p)}, we define a matrix containing the subset of the corresponding eigenvectors as UIˉ p = [ui1, . . . , uiˉ p]. Note the difference between Uˉp and UIˉ p. 4.2 Lemmas As discussed above, we extracted the first-order and second-order conditions of local minima as the following lemmas. The lemmas provided here are also intended to be our additional theoretical results that may lead to further insights. The proofs of the lemmas are in the appendix. Lemma 4.1 (Critical point necessary and sufficient condition) W is a critical point of ˉL(W) if and only if for all k ∈{1, ..., H + 1}, Dvec(W T k ) ˉL(W) T = WH+1WH ∙∙∙Wk+1 ⊗(Wk−1 ∙∙∙W2W1X)T T vec(r) = 0. Lemma 4.2 (Representation at critical point) If W is a critical point of ˉL(W), then WH+1WH ∙∙∙W2W1 = C(CT C)−CT Y XT (XXT )−1. Lemma 4.3 (Block Hessian with Kronecker product) Write the entries of ∇2 ˉL(W) in a block form as ∇2 ˉL(W) = Dvec(W T H+1) Dvec(W T H+1) ˉL(W) T ∙∙∙ Dvec(W T 1 ) Dvec(W T H+1) ˉL(W) T ... ... ... Dvec(W T H+1) Dvec(W T 1 ) ˉL(W) T ∙∙∙ Dvec(W T 1 ) Dvec(W T 1 ) ˉL(W) T . 4For a non-convex and non-differentiable function, we can still have a first-order and second-order necessary condition (e.g., Rockafellar & Wets, 2009, theorem 13.24, p. 606). 6 Then, for any k ∈{1, ..., H + 1}, Dvec(W T k ) Dvec(W T k ) ˉL(W) T = (WH+1 ∙∙∙Wk+1)T (WH+1 ∙∙∙Wk+1) ⊗(Wk−1 ∙∙∙W1X)(Wk−1 ∙∙∙W1X)T , and, for any k ∈{2, ..., H + 1}, Dvec(W T k ) Dvec(W T 1 ) ˉL(W) T = CT (WH+1 ∙∙∙Wk+1) ⊗X(Wk−1 ∙∙∙W1X)T + [(Wk−1 ∙∙∙W2)T ⊗X] [Idk−1 ⊗(rWH+1 ∙∙∙Wk+1)∙,1 . . . Idk−1 ⊗(rWH+1 ∙∙∙Wk+1)∙,dk] . Lemma 4.4 (Hessian semidefinite necessary condition) If ∇2 ˉL(W) is positive semidefinite or negative semidefinite at a critical point, then for any k ∈{2, ..., H + 1}, R((Wk−1 ∙∙∙W3W2)T ) ⊆R(CT C) or XrWH+1WH ∙∙∙Wk+1 = 0. Corollary 4.5 If ∇2 ˉL(W) is positive semidefinite or negative semidefinite at a critical point, then for any k ∈{2, ..., H + 1}, rank(WH+1WH ∙∙∙Wk) ≥rank(Wk−1 ∙∙∙W3W2) or XrWH+1WH ∙∙∙Wk+1 = 0. Lemma 4.6 (Hessian positive semidefinite necessary condition) If ∇2 ˉL(W) is positive semidefinite at a critical point, then C(CT C)−CT = UˉpU T ˉp or Xr = 0. 4.3 Proof sketches of theorems We now provide the proof sketch of Theorem 2.3 and Corollary 3.2. We complete the proofs in the appendix. 4.3.1 Proof sketch of Theorem 2.3 (ii) By case analysis, we show that any point that satisfies the necessary conditions and the definition of a local minimum is a global minimum. Case I: rank(WH ∙∙∙W2) = p and dy ≤p: If dy < p, Corollary 4.5 with k = H + 1 implies the necessary condition of local minima that Xr = 0. If dy = p, Lemma 4.6 with k = H + 1 and k = 2, combined with the fact that R(C) ⊆R(Y XT ), implies the necessary condition that Xr = 0. Therefore, we have the necessary condition of local minima, Xr = 0 . Interpreting condition Xr = 0, we conclude that W achieving Xr = 0 is indeed a global minimum. Case II: rank(WH ∙∙∙W2) = p and dy > p: From Lemma 4.6, we have the necessary condition that C(CT C)−CT = UˉpU T ˉp or Xr = 0. If Xr = 0, using the exact same proof as in Case I, it is a global minimum. Suppose then that C(CT C)−CT = UˉpU T ˉp . From Lemma 4.4 with k = H + 1, we conclude that ˉp ≜rank(C) = p. Then, from Lemma 4.2, we write WH+1 ∙∙∙W1 = UpU T p Y XT (XXT )−1, which is the orthogonal projection onto the subspace spanned by the p eigenvectors corresponding to the p largest eigenvalues following the ordinary least square regression matrix. This is indeed the expression of a global minimum. Case III: rank(WH ∙∙∙W2) < p: We first show that if rank(C) ≥min(p, dy), every local minimum is a global minimum. Thus, we consider the case where rank(WH ∙∙∙W2) < p and rank(C) < min(p, dy). In this case, by induction on k = {1, . . . , H+1}, we prove that we can have rank(Wk ∙∙∙W1) ≥min(p, dy) with arbitrarily small perturbation of each entry of Wk, . . . , W1 without changing the value of ˉL(W). Once this is proved, along with the results of Case I and Case II, we can immediately conclude that any point satisfying the definition of a local minimum is a global minimum. We first prove the statement for the base case with k = 1 by using an expression of W1 that is obtained by a first-order necessary condition: for an arbitrary L1, W1 = (CT C)−CT Y XT (XXT )−1 + (I −(CT C)−CT C)L1. 7 By using Lemma 4.6 to obtain an expression of C, we deduce that we can have rank(W1) ≥ min(p, dy) with arbitrarily small perturbation of each entry of W1 without changing the loss value. For the inductive step with k ∈{2, . . . , H + 1}, from Lemma 4.4, we use the following necessary condition for the Hessian to be (positive or negative) semidefinite at a critical point: for any k ∈ {2, . . . , H + 1}, R((Wk−1 ∙∙∙W2)T ) ⊆R(CT C) or XrWH+1 ∙∙∙Wk+1 = 0. We use the inductive hypothesis to conclude that the first condition is false, and thus the second condition must be satisfied at a candidate point of a local minimum. From the latter condition, with extra steps, we can deduce that we can have rank(WkWk−1 ∙∙∙W1) ≥min(p, dx) with arbitrarily small perturbation of each entry of Wk while retaining the same loss value. We conclude the induction, proving that we can have rank(C) ≥rank(WH+1 ∙∙∙W1) ≥ min(p, dx) with arbitrarily small perturbation of each parameter without changing the value of ˉL(W). Upon such a perturbation, we have the case where rank(C) ≥min(p, dy), for which we have already proven that every local minimum is a global minimum. Summarizing the above, any point that satisfies the definition (and necessary conditions) of a local minimum is indeed a global minimum. Therefore, we conclude the proof sketch of Theorem 2.3 (ii). 4.3.2 Proof sketch of Theorem 2.3 (i), (iii) and (iv) We can prove the non-convexity and non-concavity of this function simply from its Hessian (Theorem 2.3 (i)). That is, we can show that in the domain of the function, there exist points at which the Hessian becomes indefinite. Indeed, the domain contains uncountably many points at which the Hessian is indefinite. We now consider Theorem 2.3 (iii): every critical point that is not a global minimum is a saddle point. Combined with Theorem 2.3 (ii), which is proven independently, this is equivalent to the statement that there are no local maxima. We first show that if WH+1 ∙∙∙W2 ̸= 0, the loss function always has some strictly increasing direction with respect to W1, and hence there is no local maximum. If WH+1 ∙∙∙W2 = 0, we show that at a critical point, if the Hessian is negative semidefinite (i.e., a necessary condition of local maxima), we can have WH+1 ∙∙∙W2 ̸= 0 with arbitrarily small perturbation without changing the loss value. We can prove this by induction on k = 2, . . . , H + 1, similar to the induction in the proof of Theorem 2.3 (ii). This means that there is no local maximum. Theorem 2.3 (iv) follows Theorem 2.3 (ii)-(iii) and the analyses for Case I and Case II in the proof of Theorem 2.3 (ii); when rank(WH ∙∙∙W2) = p, if ∇2 ˉL(W) ⪰0 at a critical point, W is a global minimum. 4.3.3 Proof sketch of Corollary 3.2 Since the activations are assumed to be random and independent, the effect of nonlinear activations disappear by taking expectation. As a result, the loss function L(W) is reduced to ˉL(W). 5 Conclusion In this paper, we addressed some open problems, pushing forward the theoretical foundations of deep learning and non-convex optimization. For deep linear neural networks, we proved the aforementioned conjecture and more detailed statements with more generality. For deep nonlinear neural networks, when compared with the previous work, we proved a tighter statement (in the way explained in section 3) with more generality (dy can vary) and with strictly weaker model assumptions (only two assumptions out of seven). However, our theory does not yet directly apply to the practical situation. To fill the gap between theory and practice, future work would further discard the remaining two out of the seven assumptions made in previous work. Our new understanding of the deep linear models at least provides the following theoretical fact: the bad local minima would arise in a deep nonlinear model but only as an effect of adding nonlinear activations to the corresponding deep linear model. Thus, depending on the nonlinear activation mechanism and architecture, we would be able to efficiently train deep models. Acknowledgments The author would like to thank Prof. Leslie Kaelbling, Quynh Nguyen, Li Huan and Anirbit Mukherjee for their thoughtful comments on the paper. We gratefully acknowledge support from NSF grant 1420927, from ONR grant N00014-14-1-0486, and from ARO grant W911NF1410433. 8 References Baldi, Pierre. 1989. Linear learning: Landscapes and algorithms. In Advances in neural information processing systems. pp. 65–72. Baldi, Pierre, & Hornik, Kurt. 1989. Neural networks and principal component analysis: Learning from examples without local minima. Neural networks, 2(1), 53–58. Baldi, Pierre, & Lu, Zhiqin. 2012. Complex-valued autoencoders. Neural Networks, 33, 136–147. Blum, Avrim L, & Rivest, Ronald L. 1992. Training a 3-node neural network is NP-complete. Neural Networks, 5(1), 117–127. Choromanska, Anna, Henaff, MIkael, Mathieu, Michael, Ben Arous, Gerard, & LeCun, Yann. 2015a. The Loss Surfaces of Multilayer Networks. In Proceedings of the Eighteenth International Conference on Artificial Intelligence and Statistics. pp. 192–204. Choromanska, Anna, LeCun, Yann, & Arous, Gérard Ben. 2015b. Open Problem: The landscape of the loss surfaces of multilayer networks. In Proceedings of The 28th Conference on Learning Theory. pp. 1756–1760. Dauphin, Yann N, Pascanu, Razvan, Gulcehre, Caglar, Cho, Kyunghyun, Ganguli, Surya, & Bengio, Yoshua. 2014. Identifying and attacking the saddle point problem in high-dimensional non-convex optimization. In Advances in Neural Information Processing Systems. pp. 2933–2941. Ge, Rong, Huang, Furong, Jin, Chi, & Yuan, Yang. 2015. Escaping From Saddle Points—Online Stochastic Gradient for Tensor Decomposition. In Proceedings of The 28th Conference on Learning Theory. pp. 797–842. Goodfellow, Ian, Bengio, Yoshua, & Courville, Aaron. 2016. Deep Learning. Book in preparation for MIT Press. http://www.deeplearningbook.org. Livni, Roi, Shalev-Shwartz, Shai, & Shamir, Ohad. 2014. On the computational efficiency of training neural networks. In Advances in Neural Information Processing Systems. pp. 855–863. Mhaskar, Hrushikesh, Liao, Qianli, & Poggio, Tomaso. 2016. Learning Real and Boolean Functions: When Is Deep Better Than Shallow. Massachusetts Institute of Technology CBMM Memo No. 45. Murty, Katta G, & Kabadi, Santosh N. 1987. Some NP-complete problems in quadratic and nonlinear programming. Mathematical programming, 39(2), 117–129. Rockafellar, R Tyrrell, & Wets, Roger J-B. 2009. Variational analysis. Vol. 317. Springer Science & Business Media. Saxe, Andrew M, McClelland, James L, & Ganguli, Surya. 2014. Exact solutions to the nonlinear dynamics of learning in deep linear neural networks. In International Conference on Learning Representations. Zhang, Fuzhen. 2006. The Schur complement and its applications. Vol. 4. Springer Science & Business Media. 9 | 2016 | 539 |
6,482 | End-to-End Goal-Driven Web Navigation Rodrigo Nogueira Tandon School of Engineering New York University rodrigonogueira@nyu.edu Kyunghyun Cho Courant Institute of Mathematical Sciences New York University kyunghyun.cho@nyu.edu Abstract We propose a goal-driven web navigation as a benchmark task for evaluating an agent with abilities to understand natural language and plan on partially observed environments. In this challenging task, an agent navigates through a website, which is represented as a graph consisting of web pages as nodes and hyperlinks as directed edges, to find a web page in which a query appears. The agent is required to have sophisticated high-level reasoning based on natural languages and efficient sequential decision-making capability to succeed. We release a software tool, called WebNav, that automatically transforms a website into this goal-driven web navigation task, and as an example, we make WikiNav, a dataset constructed from the English Wikipedia. We extensively evaluate different variants of neural net based artificial agents on WikiNav and observe that the proposed goal-driven web navigation well reflects the advances in models, making it a suitable benchmark for evaluating future progress. Furthermore, we extend the WikiNav with questionanswer pairs from Jeopardy! and test the proposed agent based on recurrent neural networks against strong inverted index based search engines. The artificial agents trained on WikiNav outperforms the engined based approaches, demonstrating the capability of the proposed goal-driven navigation as a good proxy for measuring the progress in real-world tasks such as focused crawling and question-answering. 1 Introduction In recent years, there have been many exciting advances in building an artificial agent, which can be trained with one learning algorithm, to solve many relatively large-scale, complicated tasks (see, e.g., [8, 10, 6].) In much of these works, target tasks were computer games such as Atari games [8] and racing car game [6]. These successes have stimulated researchers to apply a similar learning mechanism to language-based tasks, such as multi-user dungeon (MUD) games [9, 4]. Instead of visual perception, an agent perceives the state of the world by its written description. A set of actions allowed to the agent is either fixed or dependent on the current state. This type of task can efficiently evaluate the agent’s ability of not only in planning but also language understanding. We, however, notice that these MUD games do not exhibit the complex nature of natural languages to the full extent. For instance, the largest game world tested by Narasimhan et al. [9] uses a vocabulary of only 1340 unique words, and the largest game tested by He et al. [4] uses only 2258 words. Furthermore, the description of a state at each time step is almost always limited to the visual description of the current scene, lacking any use of higher-level concepts present in natural languages. In this paper, we propose a goal-driven web navigation as a large-scale alternative to the text-based games for evaluating artificial agents with natural language understanding and planning capability. The proposed goal-driven web navigation consists of the whole website as a graph, in which the web pages are nodes and hyperlinks are directed edges. An agent is given a query, which consists of one 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. or more sentences taken from a randomly selected web page in the graph, and navigates the network, starting from a predefined starting node, to find a target node in which the query appears. Unlike the text-based games, this task utilizes the existing text as it is, resulting in a large vocabulary with a truly natural language description of the state. Furthermore, the task is more challenging as the action space greatly changes with respect to the state in which the agent is. We release a software tool, called WebNav, that converts a given website into a goal-driven web navigation task. As an example of its use, we provide WikiNav, which was built from English Wikipedia. We design artificial agents based on neural networks (called NeuAgents) trained with supervised learning, and report their respective performances on the benchmark task as well as the performance of human volunteers. We observe that the difficulty of a task generated by WebNav is well controlled by two control parameters; (1) the maximum number of hops from a starting to a target node Nh and (2) the length of query Nq. Furthermore, we extend the WikiNav with an additional set of queries that are constructed from Jeopardy! questions, to which we refer by WikiNav-Jeopardy. We evaluate the proposed NeuAgents against the three search-based strategies; (1) SimpleSearch, (2) Apache Lucene and (3) Google Search API. The result in terms of document recall indicates that the NeuAgents outperform those search-based strategies, implying a potential for the proposed task as a good proxy for practical applications such as question-answering and focused crawling. 2 Goal-driven Web Navigation A task T of goal-driven web navigation is characterized by T = (A, sS, G, q, R, Ω). (1) The world in which an agent A navigates is represented as a graph G = (N, E). The graph consists of a set of nodes N = {si}NN i=1 and a set of directed edges E = {ei,j} connecting those nodes. Each node represents a page of the website, which, in turn, is represented by the natural language text D(si) in it. There exists an edge going from a page si to sj if and only if there is a hyperlink in D(si) that points to sj. One of the nodes is designated as a starting node sS from which any navigation begins. A target node is the one whose natural language description contains a query q, and there may be more than one target node. At each time step, the agent A reads the natural language description D(st) of the current node in which the agent has landed. At no point, the whole world, consisting of the nodes and edges, nor its structure or map (graph structure without any natural language description) is visible to the agent, thus making this task partially observed. Once the agent A reads the description D(si) of the current node si, it can take one of the actions available. A set of possible actions is defined as a union of all the outgoing edges ei,· and the stop action, thus making the agent have state-dependent action space. Each edge ei,k corresponds to the agent jumping to a next node sk, while the stop action corresponds to the agent declaring that the current node si is one of the target nodes. Each edge ei,k is represented by the description of the next node D(sk). In other words, deciding which action to take is equivalent to taking a peek at each neighboring node and seeing whether that node is likely to lead ultimately to a target node. The agent A receives a reward R(si, q) when it chooses the stop action. This task uses a simple binary reward, where R(si, q) = 1, if q ⊆D(si) 0, otherwise Constraints It is clear that there exists an ultimate policy for the agent to succeed at every trial, which is to traverse the graph breadth-first until the agent finds a node in which the query appears. To avoid this kind of degenerate policies, the task includes a set of four rules/constraints Ω: 1. An agent can follow at most Nn edges at each node. 2. An agent has a finite memory of size smaller than T . 2 Table 1: Dataset Statistics of WikiNav-4-*, WikiNav-8-*, WikiNav-16-* and WikiNav-Jeopardy. WikiNav-4-* WikiNav-8-* WikiNav-16-* WikiNav-Jeopardy Train 6.0k 1M 12M 113k Valid 1k 20k 20k 10k Test 1k 20k 20k 10k 3. An agent moves up to Nh hops away from sS. 4. A query of size Nq comes from at least two hops away from the starting node. The first constraint alone prevents degenerate policies, such as breadth-first search, forcing the agent to make good decisions as possible at each node. The second one further constraints ensure that the agent does not cheat by using earlier trials to reconstruct the whole graph structure (during test time) or to store the entire world in its memory (during training.) The third constraint, which is optional, is there for computational consideration. The fourth constraint is included because the agent is allowed to read the content of a next node. 3 WebNav: Software As a part of this work, we build and release a software tool which turns a website into a goal-driven web navigation task.1 We call this tool WebNav. Given a starting URL, the WebNav reads the whole website, constructs a graph with the web pages in the website as nodes. Each node is assigned a unique identifier si. The text content of each node D(si) is a cleaned version of the actual HTML content of the corresponding web page. The WebNav turns intra-site hyperlinks into a set of edges ei,j. In addition to transforming a website into a graph G from Eq. (1), the WebNav automatically selects queries from the nodes’ texts and divides them into training, validation, and test sets. We ensure that there is no overlap among three sets by making each target node, from which a query is selected, belongs to only one of them. Each generated example is defined as a tuple X = (q, s∗, p∗) (2) where q is a query from a web page s∗, which was found following a randomly selected path p∗= (sS, . . . , s∗). In other words, the WebNav starts from a starting page sS, random-walks the graph for a predefined number of steps (Nh/2, in our case), reaches a target node s∗and selects a query q from D(s∗). A query consists of Nq sentences and is selected among the top-5 candidates in the target node with the highest average TF-IDF, thus discouraging the WebNav from choosing a trivial query. For the evaluation purpose alone, it is enough to use only a query q itself as an example. However, we include both one target node (among potentially many other target nodes) and one path from the starting node to this target node (again, among many possible connecting paths) so that they can be exploited when training an agent. They are not to be used when evaluating a trained agent. 4 WikiNav: A Benchmark Task With the WebNav, we built a benchmark goal-driven navigation task using Wikipedia as a target website. We used the dump file of the English Wikipedia from September 2015, which consists of more than five million web pages. We built a set of separate tasks with different levels of difficulty by varying the maximum number of allowed hops Nh ∈{4, 8, 16} and the size of query Nq ∈{1, 2, 4}. We refer to each task by WikiNav-Nh-Nq. For each task, we generate training, validation and test examples from the pages half as many hops away from a starting page as the maximum number of hops allowed.2 We use “Category:Main topic classifications” as a starting node sS. 1 The source code and datasets are publicly available at github.com/nyu-dl/WebNav. 2 This limit is an artificial limit we chose for computational reasons. 3 Table 3: Sample query-answer pairs from WikiNav-Jeopardy. Query Answer For the last 8 years of his life, Galileo was under Copernicus house arrest for espousing this man’s theory. In the winter of 1971-72, a record 1,122 inches of snow fell Washington at Rainier Paradise Ranger Station in this state. This company’s Accutron watch, introduced in 1960, Bulova had a guarantee of accuracy to within one minute a month. As a minimal cleanup procedure, we excluded meta articles whose titles start with “Wikipedia”. Any hyperlink that leads to a web page outside Wikipedia is removed in advance together with the following sections: “References”, “External Links”, “Bibliography” and “Partial Bibliography”. Hyperlinks Words Avg. 4.29 462.5 √ Var 13.85 990.2 Max 300 132881 Min 0 1 Table 2: Per-page statistics of English Wikipedia. In Table 2, we present basic per-article statistics of the English Wikipedia. It is evident from these statistics that the world of WikiNav-Nh-Nq is large and complicated, even after the cleanup procedure. We ended up with a fairly small dataset for WikiNav-4-*, but large for WikiNav-8-* and WikiNav-16-*. See Table 1 for details. 4.1 Related Work: Wikispeedia This work is indeed not the first to notice the possibility of a website, or possibly the whole web, as a world in which intelligent agents explore to achieve a certain goal. One most relevant recent work to ours is perhaps Wikispeedia from [14, 12, 13]. West et al. [14, 12, 13] proposed the following game, called Wikispeedia. The game’s world is nearly identical to the goal-driven navigation task proposed in this work. More specifically, they converted “Wikipedia for Schools”, which contains approximately 4,000 articles as of 2008, into a graph whose nodes are articles and directed edges are hyperlinks. From this graph, a pair of nodes is randomly selected and provided to an agent. The agent’s goal is to start from the first node, navigate the graph and reach the second node. Similarly to the WikiNav, the agent has access to the text content of the current nodes and all the immediate neighboring nodes. One major difference is that the target is given as a whole article, meaning that there is a single target node in the Wikispeedia while there may be multiple target nodes in the proposed WikiNav. From this description, we see that the goal-driven web navigation is a generalization and re-framing of the Wikispeedia. First, we constrain a query to contain less information, making it much more difficult for an agent to navigate to a target node. Furthermore, a major research question by West and Leskovec [13] was to “understand how humans navigate and find the information they are looking for ,” whereas in this work we are fully focused on proposing an automatic tool to build a challenging goal-driven tasks for designing and evaluating artificial intelligent agents. 5 WikiNav-Jeopardy: Jeopardy! on WikiNav One of the potential practical applications utilizing the goal-drive navigation is question-answering based on world knowledge. In this Q&A task, a query is a question, and an agent navigates a given information network, e.g., website, to retrieve an answer. In this section, we propose and describe an extension of the WikiNav, in which query-target pairs are constructed from actual Jeopardy! question-answer pairs. We refer to this extension of WikiNav by WikiNav-Jeopardy. We first extract all the question-answer pairs from J! Archive3, which has more than 300k such pairs. We keep only those pairs whose answers are titles of Wikipedia articles, leaving us with 133k pairs. We divide those pairs into 113k training, 10k validation, and 10k test examples while carefully 3 www.j-archive.com 4 ensuring that no article appears in more than one partition. Additionally, we do not shuffle the original pairs to ensure that the train and test examples are from different episodes. For each training pair, we find one path from the starting node “Main Topic Classification” to the target node and include it for supervised learning. For reference, the average number of hops to the target node is 5.8, the standard deviation is 1.2, and the maximum and minimum are 2 and 10, respectively. See Table 3 for sample query-answer pairs. 6 NeuAgent: Neural Network based Agent 6.1 Model Description Core Function The core of the NeuAgent is a parametric function fcore that takes as input the content of the current node φc(si) and a query φq(q), and that returns the hidden state of the agent. This parametric function fcore can be implemented either as a feedforward neural network fff: ht = fff(φc(si), φq(q)) which does not take into account the previous hidden state of the agent or as a recurrent neural network frec: ht = frec(ht−1, φc(si), φq(q)). We refer to these two types of agents by NeuAgent-FF and NeuAgent-Rec, respectively. For the NeuAgent-FF, we use a single tanh layer, while we use long short-term memory (LSTM) units [5], which have recently become de facto standard, for the NeuAgent-Rec. Figure 1: Graphical illustration of a single step performed by the baseline model, NeuAgent. Based on the new hidden state ht, the NeuAgent computes the probability distribution over all the outgoing edges ei. The probability of each outgoing edge is proportional to the similarity between the hidden state ht such that p(ei,j|˜p) ∝exp φc(sj)⊤ht . (3) Note that the NeuAgent peeks at the content of the next node sj by considering its vector representation φc(sj). In addition to all the outgoing edges, we also allow the agent to stop with the probability p(∅|˜p) ∝exp v⊤ ∅ht , (4) where the stop action vector v∅is a trainable parameter. In the case of NeuAgent-Rec, all these (unnormalized) probabilities are conditioned on the history ˜p which is a sequence of actions (nodes) selected by the agent so far. We apply a softmax normalization on the unnormalized probabilities to obtain the probability distribution over all the possible actions at the current node si. The NeuAgent then selects its next action based on this action probability distribution (Eqs. (3) and (4)). If the stop action is chosen, the NeuAgent returns the current node as an answer and receives a reward R(si, q), which is one if correct and zero otherwise. If the agent selects one of the outgoing edges, it moves to the selected node and repeats this process of reading and acting. See Fig. 1 for a single step of the described NeuAgent. Content Representation The NeuAgent represents the content of a node si as a vector φc(si) ∈Rd. In this work, we use a continuous bag-of-words vector for each document: φc(si) = 1 |D(si)| |D(si)| X k=1 ek. Each word vector ek is from a pretrained continuous bag-of-words model [7]. These word vectors are fixed throughout training. 5 Query Representation In the case of a query, we consider two types of representation. The first one is a continuous bag-of-words (BoW) vector, just as used for representing the content of a node. The other one is a dynamic representation based on the attention mechanism [2]. In the attention-based query representation, the query is first projected into a set of context vectors. The context vector of the k-th query word is ck = k+u/2 X k′=k−u/2 Wk′ek′, where Wk′ ∈Rd×d and ek′ are respectively a trainable weight matrix and a pretrained word vector. u is the window size. Each context vector is scored at each time step t by βt k = fatt(ht−1, ck) w.r.t. the previous hidden state of the NeuAgent, and all the scores are normalized to be positive and sum to one, i.e., αt k = exp(βt k) P|q| l=1 exp(βt l ). These normalized scores are used as the coefficients in computing the weighted-sum of query words to result in a query representation at time t: φq(q) = 1 |q| |q| X k=1 αt kck. Later, we empirically compare these two query representations. 6.2 Inference: Beam Search Once the NeuAgent is trained, there are a number of approaches to using it for solving the proposed task. The most naive approach is simply to let the agent make a greedy decision at each time step, i.e., following the outgoing edge with the highest probability arg maxk log p(ei,k| . . .). A better approach is to exploit the fact that the agent is allowed to explore up to Nn outgoing edges per node. We use a simple, forward-only beam search with the beam width capped at Nn. The beam search simply keeps the Nn most likely traces, in terms of log p(ei,k| . . .), at each time step. 6.3 Training: Supervised Learning In this paper, we investigate supervised learning, where we train the agent to follow an example trace p∗= (sS, . . . , s∗) included in the training set at each step (see Eq. (2)). In this case, the cost per training example is Csup = −log p(∅|p∗, q) − |p∗| X k=1 log p(p∗ k|p∗ <k, q). (5) This per-example training cost is fully differentiable with respect to all the parameters of the neural network, and we use stochastic gradient descent (SGD) algorithm to minimize this cost over the whole training set, where the gradients can be computed by backpropagation [11]. This allows the entire model to be trained in an end-to-end fashion, in which the query-to-target performance is optimized directly. 7 Human Evaluation One unique aspect of the proposed task is that it is very difficult for an average person who was not trained specifically for finding information by navigating through an information network. There are a number of reasons behind this difficulty. First, the person must be familiar with, via training, the graph structure of the network, and this often requires many months, if not years, of training. Second, the person must have in-depth knowledge of a broad range of topics in order to make a connection via different concepts between the themes and topics of a query to a target node. Third, each trial requires the person carefully to read the whole content of the nodes as she navigates, which is a time-consuming and exhausting job. We asked five volunteers to try up to 20 four-sentence-long queries4 randomly selected from the test sets of WikiNav-{4, 8, 16}-4 datasets. They were given up to two hours, and they were allowed to 4 In a preliminary study with other volunteers, we found that, when the queries were shorter than 4, they were not able to solve enough trials for us to have meaningful statistics. 6 Table 4: The average reward by the NeuAgents and humans on the test sets of WikiNav-Nh-Nq. Nq = 1 2 4 fcore Layers×Units φq Nh = 4 8 16 4 8 16 4 8 16 (a) fff 1 × 512 BoW 21.5 4.7 1.2 40.0 9.2 1.9 45.1 12.9 2.9 (b) frec 1 × 512 BoW 22.0 5.1 1.7 41.1 9.2 2.1 44.8 13.3 3.6 (c) frec 8 × 2048 BoW 17.7 10.9 8.0 35.8 19.9 13.9 39.5 28.1 21.9 (d) frec 8 × 2048 Att 22.9 15.8 12.5 41.7 24.5 17.8 46.8 34.2 28.2 (e) Humans 14.5 8.8 5.0 choose up to the same maximum number of explored edges per node Nn as the NeuAgents (that is, Nn = 4), and also were given the option to give up. The average reward was computed as the fraction of correct trials over all the queries presented. 8 Results and Analysis 8.1 WikiNav We report in Table 4 the performance of the NeuAgent-FF and NeuAgent-Rec models on the test set of all nine WikiNav-{4, 8, 16}-{1, 2, 4} datasets. In addition to the proposed NeuAgents, we also report the results of the human evaluation. We clearly observe that the level of difficulty is indeed negatively correlated with the query length Nq but is positively correlated with the maximum number of allowed hops Nh. The latter may be considered trivial, as the size of the search space grows exponentially with respect to Nh, but the former is not. The former negative correlation confirms that it is indeed easier to solve the task with more information in a query. We conjecture that the agent requires more in-depth understanding of natural languages and planning to overcome the lack of information in the query to find a path toward a target node. The NeuAgent-FF and NeuAgent-Rec shares similar performance when the maximum number of allowed hops is small (Nh = 4), but NeuAgent-Rec ((a) vs. (b)) performs consistently better for higher Nh, which indicates that having access to history helps in long-term planning tasks. We also observe that the larger and deeper NeuAgent-Rec ((b) vs (c)) significantly outperforms the smaller one, when a target node is further away from the starting node sS. The best performing model in (d) used the attention-based query representation, especially as the difficulty of the task increased (Nq ↓and Nh ↑), which supports our claim that the proposed task of goal-driven web navigation is a challenging benchmark for evaluating future progress. In Fig. 2, we present an example of how the attention weights over the query words dynamically evolve as the model navigates toward a target node. The human participants generally performed worse than the NeuAgents. We attribute this to a number of reasons. First, the NeuAgents are trained specifically on the target domain (Wikipedia), while the human participants have not been. Second, we observed that the volunteers were rapidly exhausted from reading multiple articles in sequence. In other words, we find the proposed benchmark, WebNav, as a good benchmark for machine intelligence but not for comparing it against human intelligence. 1918 Kentuchy Derby Category: Kentuchy Derby Races Category: Kentuchy Derby Category: Sports events in Louisville, Kentuchy Category: Sports Events by City Category: Sports Events Category: Sports Category: Main Topic Classifications The Kentuchy Derby was the running of the [[ Kentuchy Derby The race took place May 1918 . Full Results Payout The winner received a purse of $ 15,000 . Figure 2: Visualization of the attention weights over a test query. The horizontal axis corresponds to the query words, and the vertical axis to the articles titles visited. 7 8.2 WikiNav-Jeopardy Settings We test the best model from the previous experiment (NeuAgent-Rec with 8 layers of 2048 LSTM units and the attention-based query representation) on the WikiNav-Jeopardy. We evaluate two training strategies. The first strategy is straightforward supervise learning, in which we train a NeuAgent-Rec on WikiNav-Jeopardy from scratch. In the other strategy, we pretrain a NeuAgent-Rec first on the WikiNav-16-4 and finetune it on WikiNav-Jeopardy. We compare the proposed NeuAgent against three search strategies. The first one, SimpleSearch, is a simple inverted index based strategy. SimpleSearch scores each Wikipedia article by the TF-IDF weighted sum of words that co-occur in the articles and a query and returns top-K articles. Second, we use Lucene, a popular open source information retrieval library, in its default configuration on the whole Wikipedia dump. Lastly, we use Google Search API5, while restricting the domain to wikipedia.org. Each system is evaluated by document recall at K (Recall@K). We vary K to be 1, 4 or 40. In the case of the NeuAgent, we run beam search with width set to K and returns all the K final nodes to compute the document recall. Since there is only one correct document/answer per query, Precision@K = Recall@K / K and therefore we do not show this measure in the results. Table 5: Recall on WikiNav-Jeopardy. (⋆) Pretrained on WikiNav-16-4. Model Pre⋆ Recall@1 Recall@4 Recall@40 NeuAgent 13.9 20.2 33.2 NeuAgent ✓ 18.9 23.6 38.3 SimpleSearch 5.4 12.6 28.4 Lucene 6.3 14.7 36.3 Google 14.0 22.1 25.9 Result and Analysis In Table 5, we report the results on WikiNav-Jeopardy. The proposed NeuAgent clearly outperforms all the three search-based strategies, when it was pretrained on the WikiNav-16-4. The superiority of the pretrained NeuAgent is more apparent when the number of candidate documents is constrained to be small, implying that the NeuAgent is able to accurately rank a correct target article. Although the NeuAgent performs comparably to the other search-based strategy even without pretraining, the benefit of pretraining on the much larger WikiNav is clear. We emphasize that these search-based strategies have access to all the nodes for each input query. The NeuAgent, on the other hand, only observes the nodes as it visits during navigation. This success clearly demonstrates a potential in using the proposed NeuAgent pretrained with a dataset compiled by the proposed WebNav for the task of focused crawling [3, 1], which is an interesting problem on its own, as much of the content available on the Internet is either hidden or dynamically generated [1]. 9 Conclusion In this work, we describe a large-scale goal-driven web navigation task and argue that it serves as a useful test bed for evaluating the capabilities of artificial agents on natural language understanding and planning. We release a software tool, called WebNav, that compiles a given website into a goal-driven web navigation task. As an example, we construct WikiNav from Wikipedia using WebNav. We extend WikiNav with Jeopardy! questions, thus creating WikiNav-Jeopardy. We evaluate various neural net based agents on WikiNav and WikiNav-Jeopardy. Our results show that more sophisticated agents have better performance, thus supporting our claim that this task is well suited to evaluate future progress in natural language understanding and planning. Furthermore, we show that our agent pretrained on WikiNav outperforms two strong inverted-index based search engines on the WikiNav-Jeopardy. These empirical results support our claim on the usefulness of the proposed task and agents in challenging applications such as focused crawling and question-answering. 5 https://cse.google.com/cse 8 References [1] Manuel Álvarez, Juan Raposo, Alberto Pan, Fidel Cacheda, Fernando Bellas, and Víctor Carneiro. Deepbot: a focused crawler for accessing hidden web content. In Proceedings of the 3rd international workshop on Data enginering issues in E-commerce and services: In conjunction with ACM Conference on Electronic Commerce (EC’07), pages 18–25. ACM, 2007. [2] Dzmitry Bahdanau, Kyunghyun Cho, and Yoshua Bengio. Neural machine translation by jointly learning to align and translate. In ICLR 2015, 2014. [3] Soumen Chakrabarti, Martin Van den Berg, and Byron Dom. Focused crawling: a new approach to topic-specific web resource discovery. Computer Networks, 31(11):1623–1640, 1999. [4] Ji He, Jianshu Chen, Xiaodong He, Jianfeng Gao, Lihong Li, Li Deng, and Mari Ostendorf. Deep reinforcement learning with an unbounded action space. arXiv preprint arXiv:1511.04636, 2015. [5] Sepp Hochreiter and Jürgen Schmidhuber. Long short-term memory. Neural computation, 9(8): 1735–1780, 1997. [6] Jan Koutník, Jürgen Schmidhuber, and Faustino Gomez. Evolving deep unsupervised convolutional networks for vision-based reinforcement learning. In Proceedings of the 2014 conference on Genetic and evolutionary computation, pages 541–548. ACM, 2014. [7] Tomas Mikolov, Kai Chen, Greg Corrado, and Jeffrey Dean. Efficient estimation of word representations in vector space. arXiv preprint arXiv:1301.3781, 2013. [8] Volodymyr Mnih, Koray Kavukcuoglu, David Silver, Andrei A Rusu, Joel Veness, Marc G Bellemare, Alex Graves, Martin Riedmiller, Andreas K Fidjeland, Georg Ostrovski, et al. Human-level control through deep reinforcement learning. Nature, 518(7540):529–533, 2015. [9] Karthik Narasimhan, Tejas Kulkarni, and Regina Barzilay. Language understanding for textbased games using deep reinforcement learning. arXiv preprint arXiv:1506.08941, 2015. [10] Sebastian Risi and Julian Togelius. Neuroevolution in games: State of the art and open challenges. arXiv preprint arXiv:1410.7326, 2014. [11] David Rumelhart, Geoffrey Hinton, and Ronald Williams. Learning representations by backpropagating errors. Nature, pages 323–533, 1986. [12] Robert West and Jure Leskovec. Automatic versus human navigation in information networks. In ICWSM, 2012. [13] Robert West and Jure Leskovec. Human wayfinding in information networks. In 21st International World Wide Web Conference, pages 619–628. ACM, 2012. [14] Robert West, Joelle Pineau, and Doina Precup. Wikispeedia: An online game for inferring semantic distances between concepts. In IJCAI, pages 1598–1603, 2009. 9 | 2016 | 54 |
6,483 | Linear Contextual Bandits with Knapsacks Shipra Agrawal∗ Nikhil R. Devanur† Abstract We consider the linear contextual bandit problem with resource consumption, in addition to reward generation. In each round, the outcome of pulling an arm is a reward as well as a vector of resource consumptions. The expected values of these outcomes depend linearly on the context of that arm. The budget/capacity constraints require that the total consumption doesn’t exceed the budget for each resource. The objective is once again to maximize the total reward. This problem turns out to be a common generalization of classic linear contextual bandits (linContextual) [8, 11, 1], bandits with knapsacks (BwK) [3, 9], and the online stochastic packing problem (OSPP) [4, 14]. We present algorithms with near-optimal regret bounds for this problem. Our bounds compare favorably to results on the unstructured version of the problem [5, 10] where the relation between the contexts and the outcomes could be arbitrary, but the algorithm only competes against a fixed set of policies accessible through an optimization oracle. We combine techniques from the work on linContextual, BwK and OSPP in a nontrivial manner while also tackling new difficulties that are not present in any of these special cases. 1 Introduction In the contextual bandit problem [8, 2], the decision maker observes a sequence of contexts (or features). In every round she needs to pull one out of K arms, after observing the context for that round. The outcome of pulling an arm may be used along with the contexts to decide future arms. Contextual bandit problems have found many useful applications such as online recommendation systems, online advertising, and clinical trials, where the decision in every round needs to be customized to the features of the user being served. The linear contextual bandit problem [1, 8, 11] is a special case of the contextual bandit problem, where the outcome is linear in the feature vector encoding the context. As pointed by [2], contextual bandit problems represent a natural half-way point between supervised learning and reinforcement learning: the use of features to encode contexts and the models for the relation between these feature vectors and the outcome are often inherited from supervised learning, while managing the exploration-exploitation tradeoff is necessary to ensure good performance in reinforcement learning. The linear contextual bandit problem can thus be thought of as a midway between the linear regression model of supervised learning, and reinforcement learning. Recently, there has been a significant interest in introducing multiple “global constraints” in the standard bandit setting [9, 3, 10, 5]. Such constraints are crucial for many important real-world applications. For example, in clinical trials, the treatment plans may be constrained by the total availability of medical facilities, drugs and other resources. In online advertising, there are budget constraints that restrict the number of times an ad is shown. Other applications include dynamic pricing, dynamic procurement, crowdsourcing, etc.; see [9, 3] for many such examples. In this paper, we consider the linear contextual bandit with knapsacks (henceforth, linCBwK) problem. In this problem, the context vectors are generated i.i.d. in every round from some unknown distribution, and on picking an arm, a reward and a consumption vector is observed, which depend ∗Columbia University. sa3305@columbia.edu. †Microsoft Research. nikdev@microsoft.com. 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. linearly on the context vector. The aim of the decision maker is to maximize the total reward while ensuring that the total consumption of every resource remains within a given budget. Below, we give a more precise definition of this problem. We use the following notational convention throughout: vectors are denoted by bold face lower case letters, while matrices are denoted by regular face upper case letters. Other quantities such as sets, scalars, etc. may be of either case, but never bold faced. All vectors are column vectors, i.e., a vector in n dimensions is treated as an n × 1 matrix. The transpose of matrix A is A⊤. Definition 1 (linCBwK). There are K “arms”, which we identify with the set [K]. The algorithm is initially given as input a budget B ∈R+. In every round t, the algorithm first observes context xt(a) ∈[0, 1]m for every arm a, and then chooses an arm at ∈[K], and finally observes a reward rt(at) ∈[0, 1] and a d-dimensional consumption vector vt(at) ∈[0, 1]d. The algorithm has a “no-op” option, which is to pick none of the arms and get 0 reward and 0 consumption. The goal of the algorithm is to pick arms such that the total reward PT t=1 rt(at) is maximized, while ensuring that the total consumption does not exceed the budget, i.e., P t vt(at) ≤B1. We make the following stochastic assumption for context, reward, and consumption vectors. In every round t, the tuple {xt(a), rt(a), vt(a)}K a=1 is generated from an unknown distribution D, independent of everything in previous rounds. Also, there exists an unknown vector µ∗∈[0, 1]m and a matrix W∗∈[0, 1]m×d such that for every arm a, given contexts xt(a), and history Ht−1 before time t, E[rt(a)|xt(a), Ht−1] = µ⊤ ∗xt(a), E[vt(a)|xt(a), Ht−1] = W ⊤ ∗xt(a). (1) For succinctness, we will denote the tuple of contexts for K arms at time t as matrix Xt ∈[0, 1]m×K, with xt(a) being the ath column of this matrix. Similarly, rewards and consumption vectors at time t are represented as the vector rt ∈[0, 1]K and the matrix Vt ∈[0, 1]d×K respectively. As we discuss later in the text, the assumption in equation (1) forms the primary distinction between our linear contextual bandit setting and the general contextual bandit setting considered in [5]. Exploiting this linearity assumption will allow us to generate regret bounds which do not depend on the number of arms K, rendering it to be especially useful when the number of arms is large. Some examples of this include recommendation systems with large number of products (e.g., retail products, travel packages, ad creatives, sponsored facebook posts). Another advantage over using the general contextual bandit setting of [5] is that we don’t need an oracle access to a certain optimization problem, which in this case is required to solve an NP-Hard problem. (See Section 1.1 for a more detailed discussion.) We compare the performance of an algorithm to that of an optimal adaptive policy that knows the distribution D and the parameters (µ∗, W∗), and can take into account the history up to that point, as well as the current context, to decide (possibly with randomization) which arm to pull at time t. However, it is easier to work with an upper bound on this, which is the optimal expected reward of a static policy that is required to satisfy the constraints only in expectation. This technique has been used in several related problems and is standard by now [14, 9]. Definition 2 (Optimal Static Policy). A context-dependent non-adaptive policy π is a mapping from context space [0, 1]m×K to Ω= {p ∈[0, 1]K : ∥p∥1 ≤1}, where π(X)i denotes the probability of playing arm i when the context is X, and 1 −PK i=1 π(X)i is the probability of no-op. Define r(π) and v(π) to be the expected reward and consumption vector of policy π, respectively, i.e. r(π) := E(X,r,V )∼D[rπ(X)] = EX∼D[µ⊤ ∗Xπ(X)]. (2) v(π) := E(X,r,V )∼D[V π(X)] = EX∼D[W ⊤ ∗Xπ(X)]. (3) Let π∗ := arg maxπ T r(π) such that T v(π) ≤B1 (4) be the optimal static policy. Note that since no-op is allowed, a feasible policy always exists. We denote the value of this optimal static policy by OPT := T r(π∗). The following lemma proves that OPT upper bounds the value of an optimal adaptive policy. Proof is in Appendix B in the supplement. Lemma 1. Let OPT denote the value of an optimal adaptive policy that knows the distribution D and parameters µ∗, W∗. Then OPT ≥OPT. 2 Definition 3 (Regret). Let at be the arm played at time t by the algorithm. Then, regret is defined as regret(T) := OPT − T X t=1 rt(at). 1.1 Main results Our main result is an algorithm with near-optimal regret bound for linCBwK. Theorem 1. There is an algorithm for linCBwK such that if B > m1/2T 3/4, then with probability at least 1 −δ, regret(T) = O ( OPT B + 1)m p Tlog(dT/δ) log(T) . Relation to general contextual bandits. There have been recent papers [5, 10] that solve problems similar to linCBwK but for general contextual bandits. In these papers the relation between contexts and outcome vectors is arbitrary and the algorithms compete with an arbitrary fixed set of context dependent policies Π accessible via an optimization oracle, with regret bounds being O ( OPT B + 1) p KT log(dT|Π|/δ) . These approaches could potentially be applied to the linear setting using a set Π of linear context dependent policies. Comparing their bounds with ours, in our results, essentially a p K log(|Π|) factor is replaced by a factor of m. Most importantly, we have no dependence on K,3 which enables us to consider problems with large action spaces. Further, suppose that we want to use their result with the set of linear policies, i.e., policies of the form, for some fixed θ ∈ℜm, arg max a∈[K]{xt(a)⊤θ}. Then, their algorithms would require access to an “Arg-Max Oracle” that can find the best such policy (maximizing total reward) for a given set of contexts and rewards (no resource consumption). In fact, by a reduction from the problem of learning halfspaces with noise [16], we can show that the optimization problem underlying such an “Arg-Max Oracle” problem is NP-Hard, making such an approach computationally expensive. The proof of this is in Appendix C in the supplement. The only downside to our results is that we need the budget B to be Ω(m1/2T 3/4). Getting similar bounds for budgets as small as B = Θ(m √ T) is an interesting open problem. (This also indicates that this is indeed a harder problem than all the special cases.) Near-optimality of regret bounds. In [12], it was shown that for the linear contextual bandits problem, no online algorithm can achieve a regret bound better than Ω(m √ T). In fact, they prove this lower bound for linear contextual bandits with static contexts. Since that problem is a special case of the linCBwK problem with d = 1, this shows that the dependence on m and T in the above regret bound is optimal upto log factors. For general contextual bandits with resource constraints, the bounds of [5, 10] are near optimal. Relation to BwK [3] and OSPP [4]. It is easy to see that the linCBwK problem is a generalization of the linear contextual bandits problem [1, 8, 11]. There, the outcome is scalar and the goal is to simply maximize the sum of these. Remarkably, the linCBwK problem also turns out to be a common generalization of the bandits with knapsacks (BwK) problem considered in [9, 3], and the online stochastic packing problem (OSPP) studied by [13, 6, 15, 14, 4]. In both BwK and OSPP, the outcome of every round t is a reward rt and a vector vt and the goal of the algorithm is to maximize PT t=1 rt while ensuring that PT t=1 vt ≤B1. The problems differ in how these rewards and vectors are picked. In the OSPP problem, in every round t, the algorithm may pick any reward,vector pair from a given set At of d + 1-dimensional vectors. The set At is drawn i.i.d. from an unknown distribution over sets of vectors. This corresponds to the special case of linCBwK, where m = d + 1 and the context xt(a) itself is equal to (rt(a), vt(a)). In the BwK problem, there is a fixed set of arms, and for each arm there is an unknown distribution over reward,vector pairs. The algorithm picks an arm and a reward,vector pair is drawn from the corresponding distribution for that arm. This 3Similar to the regret bounds for linear contextual bandits [8, 1, 11]. 3 corresponds to the special case of linCBwK, where m = K and the context Xt = I, the identity matrix, for all t. We use techniques from all three special cases: our algorithms follow the primal-dual paradigm and use an online learning algorithm to search the dual space, as was done in [3]. In order to deal with linear contexts, we use techniques from [1, 8, 11] to estimate the weight matrix W∗, and define “optimistic estimates” of W∗. We also use the technique of combining the objective and the constraints using a certain tradeoff parameter and that was introduced in [4]. Further new difficulties arise, such as in estimating the optimum value from the first few rounds, a task that follows from standard techniques in each of the special cases but is very challenging here. We develop a new way of exploration that uses the linear structure, so that one can evaluate all possible choices that could have led to an optimum solution on the historic sample. This technique might be of independent interest in estimating optimum values. One can see that the problem is indeed more than the sum of its parts, from the fact that we get the optimal bound for linCBwK only when B ≥˜Ω(m1/2T 3/4), unlike either special case for which the optimal bound holds for all B (but is meaningful only for B = ˜Ω(m √ T)). The approach in [3] (for BwK) extends to the case of “static” contexts,4 where each arm has a context that doesn’t change over time. The OSPP of [4] is not a special case of linCBwK with static contexts; this is one indication of the additional difficulty of dynamic over static contexts. Other related work. Recently, [17] showed an O( √ T) regret in the linear contextual setting with a single budget constraint, when costs depend only on contexts and not arms. Due to space constraints, we have moved many proofs from the main part of the paper to the supplement. 2 Preliminaries 2.1 Confidence Ellipsoid Consider a stochastic process which in each round t, generates a pair of observations (rt, yt), such that rt is an unknown linear function of yt plus some 0-mean bounded noise, i.e., rt = µ⊤ ∗yt + ηt, where yt, µ∗∈Rm, |ηt| ≤2R, and E[ηt|y1, r1, . . . , yt−1, rt−1, yt] = 0. At any time t, a high confidence estimate of the unknown vector µ∗can be obtained by building a “confidence ellipsoid” around the ℓ2-regularized least-squares estimate ˆµt constructed from the observations made so far. This technique is common in prior work on linear contextual bandits (e.g., in [8, 11, 1]). For any regularization parameter λ > 0, let Mt := λI + Pt−1 i=1 yiy⊤ i , and ˆµt := M −1 t Pt−1 i=1 yiri. The following result from [1] shows that µ∗lies with high probability in an ellipsoid with center ˆµt. For any positive semi-definite (PSD) matrix M, define the M-norm as ∥µ∥M := p µ⊤Mµ. The confidence ellipsoid at time t is defined as Ct := n µ ∈Rm : ∥µ −ˆµt∥Mt ≤R p m log ((1+tm/λ)/δ) + √ λm o . Lemma 2 (Theorem 2 of [1]). If ∀t, ∥µ∗∥2 ≤√m and ∥yt∥2 ≤√m, then with prob. 1 −δ, µ∗∈Ct. Another useful observation about this construction is stated below. It first appeared as Lemma 11 of [8], and was also proved as Lemma 3 in [11]. Lemma 3 (Lemma 11 of [8]). PT t=1 ∥yt∥M −1 t ≤ p mT log(T). As a corollary of the above two lemmas, we obtain a bound on the total error in the estimate provided by “any point” from the confidence ellipsoid. (Proof is in Appendix D in the supplement.) 4It was incorrectly claimed in [3] that the approach can be extended to dynamic contexts without much modifications. 4 Corollary 1. For t = 1, . . . , T, let ˜µt ∈Ct be a point in the confidence ellipsoid, with λ = 1 and 2R = 1. Then, with probability 1 −δ, PT t=1 |˜µ⊤ t yt −µ⊤ ∗yt| ≤2m p T log ((1+T m)/δ) log(T). 2.2 Online Learning Consider a T round game played between an online learner and an adversary, where in round t, the learner chooses a θt ∈Ω:= {θ : ∥θ∥1 ≤1, θ ≥0}, and then observes a linear function gt : Ω→[−1, 1] picked by the adversary. The learner’s choice θt may only depend on learner’s and adversary’s choices in previous rounds. The goal of the learner is to minimize regret defined as the difference between the learner’s objective value and the value of the best single choice in hindsight: R(T) := maxθ∈Ω PT t=1 gt(θ) −PT t=1 gt(θt). The multiplicative weight update (MWU) algorithm (generalization by [7]) is a fast and efficient online learning algorithm for this problem. Let gt,j := gt(1j). Then, given a parameter ǫ > 0, in round t + 1, the choice of this algorithm takes the following form, θt+1,j = wt,j 1 + P j wt,j , where wt,j = wt−1,j(1 + ǫ)gt,j if gt,j > 0, wt−1,j(1 −ǫ)−gt,j if gt,j ≤0. (5) with initialization w0,j = 1, for all j = 1, . . . , K. Lemma 4. [7] For any 0 < ǫ ≤1 2, the MWU algorithm provides the following regret bound for the online learning problem described above: R(T) ≤ǫT + log(d+1) ǫ . In particular, for ǫ = q log(d+1) T , we have R(T) ≤ p log(d + 1)T For the rest of the paper, we refer to the MWU algorithm with ǫ = q log(d+1) T as the online learning (OL) algorithm, and the update in (5) as the OL update at time t + 1. 3 Algorithm 3.1 Optimistic estimates of unknown parameters Let at denote the arm played by the algorithm at time t. In the beginning of every round, we use the outcomes and contexts from previous rounds to construct a confidence ellipsoid for µ∗and every column of W∗. The construction of confidence ellipsoid for µ∗follows directly from the techniques in Section 2.1 with yt = xt(at) and rt being reward at time t. To construct a confidence ellipsoid for a column j of W∗, we use the techniques in Section 2.1 while substituting yt = xt(at) and rt = vt(at)j for every j. As in Section 2.1, let Mt := I + Pt−1 i=1 xi(ai)xi(ai)⊤, and construct the regularized least squares estimate for µ∗, W∗, respectively, as ˆµt := M −1 t Pt−1 i=1 xi(ai)ri(ai)⊤ (6) ˆWt := M −1 t Pt−1 i=1 xi(ai)vi(ai)⊤. (7) Define confidence ellipsoid for parameter µ∗as Ct,0 := n µ ∈Rm : ∥µ −ˆµ∥Mt ≤ p m log ((d+tmd)/δ) + √m o , and for every arm a, the optimistic estimate of µ∗as: ˜µt(a) := arg maxµ∈Ct,0 xt(a)⊤µ. (8) Let wj denote the jth column of a matrix W. We define a confidence ellipsoid for each column j, as Ct,j := n w ∈Rm : ∥w −ˆwtj∥Mt ≤ p m log ((d+tmd)/δ) + √m o , 5 and denote by Gt, the Cartesian product of all these ellipsoids: Gt := {W ∈Rm×d : wj ∈Ct,j}. Note that Lemma 2 implies that W∗∈Gt with probability 1 −δ. Now, given a vector θt ∈Rd, we define the optimistic estimate of the weight matrix at time t w.r.t. θt, for every arm a ∈[K], as : ˜Wt(a) := arg minW ∈Gt xt(a)⊤Wθt. (9) Intuitively, for the reward, we want an upper confidence bound and for the consumption we want a lower confidence bound as an optimistic estimate. This intuition aligns with the above definitions, where the maximizer was used in case of reward and a minimizer was used for consumption. The utility and precise meaning of θt will become clearer when we describe the algorithm and present the regret analysis. Using the definition of ˜µt, ˜Wt, along with the results in Lemma 2 and Corollary 1 about confidence ellipsoids, the following can be derived. Corollary 2. With probability 1 −δ, for any sequence of θ1, θ2, . . . , θT , 1. xt(a)⊤˜µt(a) ≥xt(a)⊤µ∗, for all arms a ∈[K], for all time t. 2. xt(a)⊤˜Wt(a)θt ≤xt(a)⊤W∗θt, for all arms a ∈[K], for all time t. 3. | PT t=1(˜µt(at) −µ∗)⊤xt(at)| ≤ 2m p T log ((1+tm)/δ) log(T) . 4. ∥PT t=1( ˜Wt(at) −W∗)⊤xt(at)∥≤∥1d∥ 2m p T log ((d+tmd)/δ) log(T) . Essentially, the first two claims ensure that we have optimistic estimates, and the last two claims ensure that the estimates quickly converge to the true parameters. 3.2 The core algorithm In this section, we present an algorithm and its analysis, under the assumption that a parameter Z satisfying certain properties is given. Later, we show how to use the first T0 rounds to compute such a Z, and also bound the additional regret due to these T0 rounds. We define Z now. Assumption 1. Let Z be such that for some universal constants c, c′, OPT B ≤Z ≤c OPT B + c′. The algorithm constructs estimates ˆµt and ˆWt as in Section 3.1. It also runs the OL algorithm for an instance of the online learning problem. The vector played by the OL algorithm in time step t is θt. After observing the context, the optimistic estimates for each arm are then constructed using θt, as defined in (8) and (9). Intuitively, θt is used here as a multiplier to combine different columns of the weight matrix, to get an optimistic weight vector for every arm. An adjusted estimated reward for arm a is then defined by using Z to linearly combine the optimistic estimate of the reward with the optimistic estimate of the consumption, as (xt(a)⊤˜µt(a)) −Z(xt(a)⊤˜Wt(a)θt). The algorithm chooses the arm which appears to be the best according to the adjusted estimated reward. After observing the resulting reward and consumption vectors, the estimates are updated. The online learning algorithm is advanced by one step, by defining the profit vector to be vt(at) −B T 1. The algorithm ends either after T time steps or as soon as the total consumption exceeds the budget along some dimension. Theorem 2. Given a Z as per Assumption 1, Algorithm 1 achieves the following, with prob. 1 −δ: regret(T) ≤O ( OPT B + 1)m p T log(dT/δ) log(T) . (Proof Sketch) We provide a sketch of the proof here, with a full proof given in Appendix E in the supplement. Let τ be the stopping time of the algorithm. The proof is in 3 steps: Step 1: Since E[vt(at)|Xt, at, Ht−1] = W ⊤ ∗xt(at), we apply Azuma-Hoeffding inequality to get that with high probability
Pτ t=1 vt(at) −W ⊤ ∗xt(at)
∞is small. Therefore, we can work with Pτ t=1 W ⊤ ∗xt(at) instead of Pτ t=1 vt(at). A similar application of Azuma-Hoeffding inequality is used to bound the gap | Pτ t=1 rt(at) −µ⊤ ∗xt(at)|, so that a lower bound on Pτ t=1 µ⊤ ∗xt(at) is sufficient to lower bound the total reward Pτ t=1 rt(at). 6 Algorithm 1 Algorithm for linCBwK, with given Z Initialize θ1 as per the online learning (OL) algorithm. Initialize Z that satisfies Assumption 1. for all t = 1, ..., T do Observe Xt. For every a ∈[K], compute ˜µt(a) and ˜Wt(a) as per (8) and (9) respectively. Play the arm at := arg maxa∈[K] xt(a)⊤(˜µt(a) −Z ˜Wt(a)θt). Observe rt(at) and vt(at). If for some j = 1..d, P t′≤t vt′(at′) · ej ≥B then EXIT. Use xt(at), rt(at) and vt(at) to obtain ˆµt+1, ˆWt+1 and Gt+1. Choose θt+1 using the OL update (refer to (5)) with gt(θt) := θt · vt(at) −B T 1 . end for Step 2: Using Corollary 2, with high probability, we can bound
PT t=1(W∗−˜Wt(at))⊤xt(at)
∞. It is therefore sufficient to work with the sum of vectors ˜Wt(at)⊤xt(at) instead of W ⊤ ∗xt(at), and similarly with ˜µt(at)⊤xt(at) instead of µ⊤ ∗xt(at). Step 3: The proof is completed by showing the desired bound on OPT −Pτ t=1 ˜µt(at)⊤xt(at). This part is similar to the online stochastic packing problem; if the actual reward and consumption vectors were ˜µt(at)⊤xt(at) and ˜Wt(at)⊤xt(at), then it would be exactly that problem. We adapt techniques from [4]: use the OL algorithm and the Z parameter to combine constraints into the objective. If a dimension is being consumed too fast, then the multiplier for that dimension should increase, making the algorithm to pick arms that are not likely to consume too much along this dimension. Regret is then bounded by a combination of the online learning regret and the error in the optimistic estimates. 3.3 Algorithm with Z computation In this section, we present a modification of Algorithm 1 which computes the required parameter Z that satisfies Assumption 1, and therefore does not need to be provided with a Z as input. The algorithm computes Z using observations from the first T0 rounds. Once Z is computed, Algorithm 1 can be run for the remaining time steps. However, it needs to be modified slightly to take into account the budget consumed during the first T0 rounds. We handle this by using a smaller budget B′ = B −T0 in the computations for the remaining rounds. The modified algorithm is given below. Algorithm 2 Algorithm for linCBwK, with Z computation Inputs: B, T0, B′ = B −T0 Using observations from first T0 rounds, compute a Z that satisfies Assumption 1. Run Algorithm 1 for T −T0 rounds and budget B′. Next, we provide the details of how to compute Z from observations in the first T0 rounds, and how to choose T0. We provide a method that takes advantage of the linear structure of the problem, and explores in the m-dimensional space of contexts and weight vectors to obtain bounds independent of K. In every round t = 1, . . . , T0, after observing Xt, let pt ∈∆[K] be pt := arg max p∈∆[K] ∥Xtp∥M −1 t , (10) where Mt := I + Pt−1 i=1(Xipi)(Xipi)⊤. (11) Select arm at = a with probability pt(a). In fact, since Mt is a PSD matrix, due to convexity of the function ∥Xtp∥2 M −1 t , it is the same as playing at = arg maxa∈[K] ∥xt(a)∥M −1 t . Construct estimates ˆµ, ˆWt of µ∗, W∗at time t as ˆµt := M −1 t Pt−1 i=1(Xipi)ri(ai), ˆWt := M −1 t Pt−1 i=1(Xipi)vi(ai)⊤. 7 And, for some value of γ defined later, obtain an estimate ˆ OPT γ of OPT as: ˆ OPT γ := maxπ T T0 PT0 i=1 ˆµ⊤ i Xiπ(Xi) such that T T0 PT0 i=1 ˆW ⊤ i Xiπ(Xi) ≤B + γ. (12) For an intuition about the choice of arm in (10), observe from the discussion in Section 2.1 that every column w∗j of W∗is guaranteed to lie inside the confidence ellipsoid centered at column ˆwtj of ˆWt, namely the ellipsoid, ∥w −ˆwtj∥2 Mt ≤4m log(Tm/δ). Note that this ellipsoid has principle axes as eigenvectors of Mt, and the length of the semi-principle axes is given by the inverse eigenvalues of Mt. Therefore, by maximizing ∥Xtp∥M −1 t we are choosing the context closest to the direction of the longest principal axis of the confidence ellipsoid, i.e. in the direction of the maximum uncertainty. Intuitively, this corresponds to pure exploration: by making an observation in the direction where uncertainty is large we can reduce the uncertainty in our estimate most effectively. A more algebraic explanation is as follows. In order to get a good estimate of OPT by ˆ OPT γ, we want the estimates ˆWt and W∗(and, ˆµ and µ∗) to be close enough so that ∥PT0 t=1( ˆWt−ˆW∗)⊤Xtπ(Xt)∥∞ (and, | PT0 t=1(ˆµt −µ∗)⊤Xtπ(Xt)|) is small for all policies π, and in particular for sample optimal policies. Now, using Cauchy-Schwartz these are bounded by PT0 t=1 ∥ˆµt −µ∗∥Mt∥Xtπ(Xt))∥M −1 t , and PT0 t=1 ∥ˆWt −W∗∥Mt∥Xtπ(Xt))∥M −1 t , where we define ∥W∥M, the M-norm of matrix W to be the max of column-wise M-norms. Using Lemma 2, the term ∥ˆµt−µ∗∥Mt is bounded by 2 p m log(T0m/δ) , and ∥ˆWt−W∗∥Mt is bounded by 2 p m log(T0md/δ), with probability 1−δ. Lemma 3 bounds the second term PT0 t=1 ∥Xtπ(Xt)∥M −1 t but only when π is the played policy. This is where we use that the played policy pt was chosen to maximize ∥Xtpt∥M −1 t , so that PT0 t=1 ∥Xtπ(Xt)∥M −1 t ≤PT0 t=1 ∥Xtpt∥M −1 t and the bound PT0 t=1 ∥Xtpt∥M −1 t ≤ p mT0 log(T0) given by Lemma 3 actually bounds PT0 t=1 ∥Xtπ(Xt)∥M −1 t for all π. Combining, we get a bound of 2m p T0log(T0) log(T0d/δ) on deviations ∥PT0 t=1( ˆWt − ˆW∗)⊤Xtπ(Xt)∥∞and | PT0 t=1(ˆµt −µ∗)⊤Xtπ(Xt)| for all π. We prove the following lemma. Lemma 5. For γ = T T0 2m p T0log(T0) log(T0d/δ), with probability 1 −O(δ), OPT −2γ ≤ ˆ OPT 2γ ≤OPT + 9γ( OPT B + 1). Corollary 3. Set Z = ( ˆ OPT 2γ+2γ) B + 1, with the above value of γ. Then, with probability 1 −O(δ), OPT B + 1 ≤Z ≤(1 + 11γ B )( OPT B + 1). Corollary 3 implies that as long as B ≥γ, i.e., B ≥˜Ω( mT √T0 ), Z is a constant factor approximation of OPT B + 1 ≥Z∗, therefore Theorem 2 should provide an ˜O ( OPT B + 1)m √ T regret bound. However, this bound does not account for the budget consumed in the first T0 rounds. Considering that (at most) T0 amount can be consumed from the budget in the first T0 rounds, we have an additional regret of OPT B T0. Further, since we have B′ = B −T0 budget for remaining T −T0 rounds, we need a Z that satisfies the required assumption for B′ instead of B (i.e., we need OPT B′ ≤Z ≤O(1) OPT B′ + 1 ). If B ≥2T0, then, B′ ≥B/2, and using 2 times the Z computed in Corollary 3 would satisfy the required assumption. Together, these observations give Theorem 3. Theorem 3. Using Algorithm 2 with T0 such that B > max{2T0, mT/√T0}, and twice the Z given by Corollary 3, we get a high probability regret bound of ˜O OPT B + 1 T0 + m √ T . In particular, for B > m1/2T 3/4 and m ≤ √ T, we can use T0 = m √ T to get a regret bound of ˜O OPT B + 1 m √ T . 8 References [1] Y. Abbasi-Yadkori, D. P´al, and C. Szepesv´ari. Improved algorithms for linear stochastic bandits. In NIPS, 2012. [2] A. Agarwal, D. Hsu, S. Kale, J. Langford, L. Li, and R. E. Schapire. Taming the monster: A fast and simple algorithm for contextual bandits. In ICML 2014, June 2014. [3] S. Agrawal and N. R. Devanur. Bandits with concave rewards and convex knapsacks. In Proceedings of the Fifteenth ACM Conference on Economics and Computation, EC ’14, 2014. [4] S. Agrawal and N. R. Devanur. Fast algorithms for online stochastic convex programming. In SODA, pages 1405–1424, 2015. [5] S. Agrawal, N. R. Devanur, and L. Li. An efficient algorithm for contextual bandits with knapsacks, and an extension to concave objectives. In COLT, 2016. [6] S. Agrawal, Z. Wang, and Y. Ye. A dynamic near-optimal algorithm for online linear programming. Operations Research, 62:876 – 890, 2014. [7] S. Arora, E. Hazan, and S. Kale. The multiplicative weights update method: a meta-algorithm and applications. Theory of Computing, 8(6):121–164, 2012. [8] P. Auer. Using confidence bounds for exploitation-exploration trade-offs. J. Mach. Learn. Res., 3, Mar. 2003. [9] A. Badanidiyuru, R. Kleinberg, and A. Slivkins. Bandits with knapsacks. In FOCS, pages 207–216, 2013. [10] A. Badanidiyuru, J. Langford, and A. Slivkins. Resourceful contextual bandits. In Proceedings of The Twenty-Seventh Conference on Learning Theory (COLT-14), pages 1109–1134, 2014. [11] W. Chu, L. Li, L. Reyzin, and R. E. Schapire. Contextual Bandits with Linear Payoff Functions. In AISTATS, 2011. [12] V. Dani, T. P. Hayes, and S. M. Kakade. Stochastic Linear Optimization under Bandit Feedback. In COLT, 2008. [13] N. R. Devanur and T. P. Hayes. The adwords problem: online keyword matching with budgeted bidders under random permutations. In EC, 2009. [14] N. R. Devanur, K. Jain, B. Sivan, and C. A. Wilkens. Near optimal online algorithms and fast approximation algorithms for resource allocation problems. In EC, 2011. [15] J. Feldman, M. Henzinger, N. Korula, V. S. Mirrokni, and C. Stein. Online stochastic packing applied to display ad allocation. In Proceedings of the 18th Annual European Conference on Algorithms: Part I, ESA’10, 2010. [16] V. Guruswami and P. Raghavendra. Hardness of learning halfspaces with noise. SIAM Journal on Computing, 39(2):742–765, 2009. [17] H. Wu, R. Srikant, X. Liu, and C. Jiang. Algorithms with logarithmic or sublinear regret for constrained contextual bandits. In Proceedings of the 28th International Conference on Neural Information Processing Systems (NIPS), 2015. 9 | 2016 | 540 |
6,484 | High resolution neural connectivity from incomplete tracing data using nonnegative spline regression Kameron Decker Harris Applied Mathematics, U. of Washington kamdh@uw.edu Stefan Mihalas Allen Institute for Brain Science Applied Mathematics, U. of Washington stefanm@alleninstitute.org Eric Shea-Brown Applied Mathematics, U. of Washington Allen Institute for Brain Science etsb@uw.edu Abstract Whole-brain neural connectivity data are now available from viral tracing experiments, which reveal the connections between a source injection site and elsewhere in the brain. These hold the promise of revealing spatial patterns of connectivity throughout the mammalian brain. To achieve this goal, we seek to fit a weighted, nonnegative adjacency matrix among 100 µm brain “voxels” using viral tracer data. Despite a multi-year experimental effort, injections provide incomplete coverage, and the number of voxels in our data is orders of magnitude larger than the number of injections, making the problem severely underdetermined. Furthermore, projection data are missing within the injection site because local connections there are not separable from the injection signal. We use a novel machine-learning algorithm to meet these challenges and develop a spatially explicit, voxel-scale connectivity map of the mouse visual system. Our method combines three features: a matrix completion loss for missing data, a smoothing spline penalty to regularize the problem, and (optionally) a low rank factorization. We demonstrate the consistency of our estimator using synthetic data and then apply it to newly available Allen Mouse Brain Connectivity Atlas data for the visual system. Our algorithm is significantly more predictive than current state of the art approaches which assume regions to be homogeneous. We demonstrate the efficacy of a low rank version on visual cortex data and discuss the possibility of extending this to a whole-brain connectivity matrix at the voxel scale. 1 Introduction Although the study of neural connectivity is over a century old, starting with pioneering neuroscientists who identified the importance of networks for determining brain function, most knowledge of anatomical neural network structure is limited to either detailed description of small subsystems [2, 9, 14, 26] or to averaged connectivity between larger regions [7, 21]. We focus our attention on spatial, structural connectivity at the mesoscale: a coarser scale than that of single neurons or cortical columns but finer than whole brain regions. Thanks to the development of new tracing techniques, image processing algorithms, and high-throughput methods, data at this resolution are now accessible in animals such as the fly [12, 19] and mouse [15, 18]. We present a novel regression technique tailored to the challenges of learning spatially refined mesoscale connectivity from neural tracing experiments. We have designed this technique with neural data in mind and will use this 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. + + + + VISp Figure 1: A, We seek to fit a matrix W which reproduces neural tracing experiments. Each column of W represents the expected signal in target voxels given an injection of one unit into a single source voxel. B, In the work of Oh et al. [18], a regionally homogeneous connectivity matrix was fit using a predefined regional parcellation to constrain the problem. We propose that smoothness of W is a better prior. C, The mouse’s visual field can be represented in azimuth/altitude coordinates. This representation is maintained in the retinotopy, a smoothly varying map replicated in many visual areas (e.g. [8]). D, Assuming locations in VISp (the primary visual area) project most strongly to positions which represent the same retinotopic coordinates in a secondary visual area, then we expect the mapping between upstream and downstream visual areas to be smooth. language to describe our method, but it is a general technique to assimilate spatial network data or infer smooth kernels of integral equations. Obtaining a spatially-resolved mesoscale connectome will reveal detailed features of connectivity, for example unlocking cell-type specific connectivity and microcircuit organization throughout the brain [13]. In mesoscale anterograde tracing experiments, a tracer virus is first injected into the brain. This infects neurons primarily at their cell bodies and dendrites and causes them to express a fluorescent protein in their cytoplasm, including in their axons. Neurons originating in the source injection site are then imaged to reveal their axonal projections throughout the brain. Combining many experiments with different sources then reveals the pathways that connect those sources throughout the brain. This requires combining data across multiple animals, which appears justified at the mesoscale [18]. We assume there exists some underlying nonnegative, weighted adjacency matrix W ⪰0 that is common across animals. Each experiment can be thought of as an injection x, and its projections y, so that y ≈Wx as in Fig. 1A. Uncovering the unknown W from multiple experiments (xi, yi) for i = 1, . . . , ninj is then a multivariate regression problem: Each xi is an image of the brain which represents the strength of the signal within the injection site. Likewise, every yi is an image of the strength of signal elsewhere, which arises due to the axonal projections of neurons with cell bodies in the injection site. The unknown matrix W is a linear operator which takes images of the brain (injections) and returns images of the brain (projections). In a previous paper, Oh et al. [18] were able to obtain a 213 × 213 regional weight matrix using 469 experiments with mice (Fig. 1B). They used nonnegative least squares to find the unknown regional weights in an overdetermined regression problem. Our aim is to obtain a much higher-resolution connectivity map on the scale of voxels, and this introduces many more challenges. First, the number of voxels in the brain is much larger than the number of injection experiments we can expect to perform; for mouse with 100 µm voxels this is O(105) versus O(103) [15, 18]. Also, the injections that are performed will inevitably leave gaps in their coverage of the brain. Thus specifying W is underdetermined. Second, there is no way to separately image the injections and projections. In order to construct them, experimenters image the brain once by serial tomography and fluorescence 2 microscopy. The injection sites can be annotated by finding infected cell bodies, but there is no way to disambiguate fluorescence from the cell bodies and dendrites from that of local injections. Projection strength is thus unknown within the injection sites and the neighborhood occupied by dendrites. Third, fitting full-brain voxel-wise connectivity is challenging since the number of elements in W is the square of the number of voxels in the brain. Thus we need compressed representations of W as well as efficient algorithms to perform inference. The paper proceeds as follows. In Section 2, we describe our assumption that the mesoscale connectivity W is smoothly-varying in space, as could be expected from to the presence of topographic maps across much of cortex. Later, we show that using this assumption as a prior yields connectivity maps with improved cross-validation performance. In Section 3, we present an inference algorithm designed to tackle the difficulties of underdetermination, missing data, and size of the unknown W. To deal with the gaps and ill-conditioning, we use smoothness as a regularization on W. We take an agnostic approach, similar to matrix completion [5], to the missing projection data and use a regression loss function that ignores residuals within the injection site. Finally, we present a low rank version of the estimator that will allow us to scale to large matrices. In Section 4, we test our method on synthetic data and show that it performs well for sparse data that is consistent with the regression priors. This provides evidence that it is a consistent estimator. We demonstrate the necessity of both the matrix completion and smoothing terms for good reconstruction. In Section 5, we then apply the spline-smoothing method to recently available Allen Institute for Brain Science (Allen Institute) connectivity data from mouse visual cortex [15, 18]. We find that our method is able to outperform current spatially uniform regional models, with significantly reduced cross-validation errors. We also find that a low rank version is able to achieve approximately 23× compression of the original data, with the optimal solution very close to the full rank optimum. Our method is a superior predictor to the existing regional model for visual system data, and the success of the low rank version suggests that this approach will be able to reveal whole-brain structural connectivity at unprecedented scale. All of our supplemental material and data processing and optimization code is available for download from: https://github.com/kharris/high-res-connectivity-nips-2016. 2 Spatial smoothness of mesoscale connectivity The visual cortex is a collection of relatively large cortical areas in the posterior part of the mammalian brain. Visual stimuli sensed in the retina are relayed through the thalamus into primary visual cortex (VISp), which projects to higher visual areas. We know this partly due to tracing projections between these areas, but also because neurons in the early visual areas respond to visual stimuli in a localized region of the visual field called their receptive fields [11]. An interesting and important feature of visual cortex is the presence of topographic maps of the visual field called the retinotopy [6, 8, 10, 20, 25]. Each eye sees a 2-D image of the world, where two coordinates, such as azimuth and altitude, define a point in the visual field (Fig. 1C). Retinotopy refers to the fact that cells are organized in cortical space by the position of their receptive fields; nearby cells have similar receptive field positions. Furthermore, these retinotopic maps reoccur in multiple visual areas, albeit with varying orientation and magnification. Retinotopy in other areas downstream from VISp, which do not receive many projections directly from thalamus, are likely a function of projections from VISp. It is reasonable to assume that areas which code for similar visual locations are most strongly connected. Then, because retinotopy is smoothly varying in cortical space and similar retinotopic coordinates are the most strongly connected between visual areas, the connections between those areas should be smooth in cortical space (Fig. 1C and D). Retinotopy is a specific example of topography, which extends to other sensory systems such as auditory and somatosensory cortex [22]. For this reason, connectivity may be spatially smooth throughout the brain, at least at the mesoscale. This idea can be evaluated via the methods we introduce below: if a smooth model is more predictive of held-out data than another model, then this supports the assumption. 3 3 Nonnegative spline regression with incomplete tracing data We consider the problem of fitting an adjacency operator W : T × S →R+ to data arising from ninj injections into a source space S which projects to a target space T. Here S and T are compact subsets of the brain, itself a compact subset of R3. In this mathematical setting, S and T could be arbitrary sets, but typically S = T for the ipsilateral data we present here.1 The source S and target T are discretized into nx and ny cubic voxels, respectively. The discretization of W is then an adjacency matrix W ∈Rny×nx + . Mathematically, we define the tracing data as a set of pairs xi ∈Rnx + and yi ∈Rny + , the source and target tracer signals at each voxel for experiments i = 1, . . . , ninj. We would like to fit a linear model, a matrix W such that yi ≈Wxi. We assume an observation model yi = Wxi + ηi with ηi iid ∼N(0, σ2I) multivariate Gaussian random variables with zero mean and covariance matrix σ2I ∈Rny×ny. The true data are not entirely linear, due to saturation effects of the fluorescence signal, but the linear model provides a tractable way of “credit assignment” of individual source voxels’ contributions to the target signal [18]. Finally, we assume that the target projections are unknown within the injection site. In other words, we only know yj outside the support of xj, which we denote supp xj, and we wish to only evaluate error for the observable voxels. Let Ω∈Rny×ninj, where the jth column Ωj = 1 −1supp xj, the indicator of the complement of the support. We define the orthogonal projector PΩ: Rny×ninj →Rny×ninj as PΩ(A) = A ◦Ω, the entrywise product of A and Ω. This operator zeros elements of A which correspond to the voxels within each experiment’s injection site. The operator PΩis similar to what is used in matrix completion [5], here in the context of regression rather than recovery. These assumptions lead to a loss function which is the familiar ℓ2-loss applied to the projected residuals: 1 σ2ninj ∥PΩ(WX −Y )∥2 F (1) where Y = y1, . . . , yninj and X = x1, . . . , xninj are data matrices. Here ∥· ∥F is the Frobenius norm, i.e. the ℓ2-norm of the matrix as a vector: ∥A∥F = ∥vec(A)∥2, where vec(A) takes a matrix and converts it to a vector by stacking consecutive columns. We next construct a regularization penalty. The matrix W represents the spatial discretization of a two-point kernel W. An important assumption for W is that it is spatially smooth. Function space norms of the derivatives of W, viewed as a real-valued function on T × S, are a natural way to measure the roughness of this function. For this study, we chose the squared L2-norm of the Laplacian Z T ×S |∆W|2 dydx, which is called the thin plate spline bending energy [24]. In the discrete setting, this becomes the squared ℓ2-norm of a discrete Laplacian applied to W: ∥L vec(W)∥2 2 =
LyW + WLT x
2 F . (2) The operator L : Rnynx →Rnynx is the discrete Laplacian operator or second finite difference matrix on T × S. The equality in Eqn. (2) results from the fact that the Laplacian on the product space T ×S can be decomposed as L = Lx ⊗Iny +Inx ⊗Ly [17]. Using the well-known Kronecker product identity for linear matrix equations BT ⊗A vec(X) = vec(Y ) ⇐⇒AXB = Y (3) gives the result in Eqn. (2) [23], which allows us to efficiently evaluate the Laplacian action. As for boundary conditions, we do not want to impose any particular values at the boundary, so we choose the finite difference matrix corresponding to a homogeneous Neumann (zero derivative) boundary condition. 2 1Ipsilateral refers to connections within the same cerebral hemisphere. For contralateral (opposite hemisphere) connectivity, S and T are disjoint subsets of the brain corresponding to the two hemispheres. 2It is straightforward to avoid smoothing across region boundaries by imposing Neumann boundary conditions at the boundaries; this is an option in our code available online. 4 Combining the loss and penalty terms, Eqn. (1) and (2), gives a convex optimization problem for inferring the connectivity: W ∗= arg min W ⪰0 ∥PΩ(WX −Y )∥2 F + λninj nx
LyW + WLT x
2 F . (P1) In the final form, we absorb the noise variance σ2 into the regularization hyperparameter λ and rescale the penalty so that it has the same dependence on the problem size nx, ny, and ninj as the loss. We solve the optimization (P1) using the L-BFGS-B projected quasi-Newton method, implemented in C++ [3, 4]. The gradient is efficiently computed using matrix algebra. Note that (P1) is a type of nonnegative least squares problem, since we can use Eqn. (3) to convert it into w∗= arg min w⪰0 ∥Aw −y∥2 2 + λninj nx ∥L w∥2 2 , where A = diag (vec(Ω)) XT ⊗Iny , y = diag (vec(Ω)) vec(Y ), and w = vec(W). Furthermore, without the nonnegativity constraint the estimator is linear and has an explicit solution. However, the design matrix A will have dimension (nyninj) × (nynx), with O(ny3ninj) entries if nx = O(ny). The dimensionality of the problem prevents us from working directly in the tensor product space. And since the model is a structured matrix regression problem [1], the usual representer theorems [24], which reduce the dimensionality of the estimator to effectively the number of data points, do not immediately apply. However, we hope to elucidate the connection to reproducing kernel Hilbert spaces in future work. 3.1 Low rank version The largest object in our problem is the unknown connectivity W, since in the underconstrained setting ninj ≪nx, ny. In order to improve the scaling of our problem with the number of voxels, we reformulate it with a compressed version of W: (U ∗, V ∗) = arg min U,V ⪰0 ∥PΩ(UV T X −Y )∥2 F + λninj nx
LyUV T + UV T LT x
2 F . (P2) Here, U ∈Rny×r + and V ∈Rnx×r + for some fixed rank r, so that the optimal connectivity W ∗= U ∗V ∗T is given in low rank, factored form. Note that we use nonnegative factors rather than constrain UV T ⪰0, since this is a nonlinear constraint. This has the advantage of automatically computing a nonnegative matrix factorization (NMF) of W. The NMF is of separate scientific interest, to be pursued in future work, since it decomposes the connectivity into a relatively small number of projection patterns, which has interpretations as a clustering of the connectivity itself. In going from the full rank problem (P1) to the low rank version (P2), we lose convexity. So the usual optimization methods are not guaranteed to find a global optimimum, and the clustering just mentioned is not unique. However, we have also reduced the size of the unknowns to the potentially much smaller matrices U and V , if r ≪ny, nx. If nx = O(ny), we have only O(nyr) unknowns instead of O(ny2). Evaluating the penalty term still requires computation of nynx terms, but this can be performed without storing them in memory. We use a simple projected gradient method with Nesterov acceleration in Matlab to find a local optimum for (P2) [3], and will present and compare these results to the solution of (P1) below. As before, computing the gradients is efficient using matrix algebra. This method has been used before for NMF [16]. 4 Test problem We next apply our algorithms to a test problem consisting of a one-dimensional “brain,” where the source and target space S = T = [0, 1]. The true connectivity kernel corresponds to a Gaussian profile about the diagonal plus a bump: Wtrue(x, y) = exp ( − x −y 0.4 2) + 0.9 exp ( −(x −0.8)2 + (y −0.1)2 (0.2)2 ) . 5 Wtrue 0 0.2 0.4 0.6 0.8 1 0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1 0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1 Wfull without Ω 0 0.2 0.4 0.6 0.8 1 −0.1 0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 0 1 2 3 4 5 6 Wfull with λ=0 0 0.2 0.4 0.6 0.8 1 −0.1 0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1 Wrank 20 0 0.2 0.4 0.6 0.8 1 −0.1 0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1 Figure 2: Comparison of the true (far left) and inferred connectivity from 5 injections. Unless noted, λ = 100. Second from left, we show the what happens when we solve (P1) without the matrix completion term PΩ. The holes in the projection data cause patchy and incorrect output. Note the colorbar range is 6× that in the other cases. Second from right is the result with PΩbut without regularization, solving (P1) for λ = 0. There, the solution does not interpolate between injections. Far right is a rank r = 20 result using (P2), which captures the diagonal band and off-diagonal bump that make up Wtrue. In this case, the low rank result has less relative error (9.6%) than the full rank result (11.1%, not shown). See the left panel of Fig. 2. The input and output spaces were discretized using nx = ny = 200 points. Injections are delivered at random locations within S, with a width of 0.12 + 0.1ϵ where ϵ ∼Uniform(0, 1). The values of x are set to 1 within the injection region and 0 elsewhere, y is set to 0 within the injection region, and we take noise level σ = 0.1. The matrices Lx = Ly are the 5-point finite difference Laplacians for the rectangular lattice. Example output of (P1) and (P2) is given for 5 injections in Fig. 2. Unless stated otherwise, λ = 100. The injections, depicted as black bars in the bottom of each sub-figure, do not cover the whole space S but do provide good coverage of the bump, otherwise there is no information about that feature. We depict the result of the full rank algorithm (P1) without the matrix completion term PΩ, the result including PΩbut without smoothing (λ = 0), and the result of (P2) with rank r = 20. The full rank solution is not shown, but is similar to the low rank one. Figure 2 shows the necessity of each term within the algorithm. Leaving out the matrix completion PΩleads to dramatically biased output since the algorithm uses incorrect values ysupp(x) = 0. If we include PΩbut neglect the smoothing term by setting λ = 0, we also get incorrect output: without smoothing, the algorithm cannot fill in the injection site holes nor can it interpolate between injections. However, the low rank result accurately approximates the true connectivity Wtrue, including the diagonal profile and bump, achieving 9.6% relative error measured as ∥W ∗−Wtrue∥F /∥Wtrue∥F . The full rank version is similar, but in fact has slightly higher 11.1% relative error. 5 Finding a voxel-scale connectivity map for mouse cortex We next apply our method to the latest data from the Allen Institute Mouse Brain Connectivity Atlas, obtained with the API at http://connectivity.brain-map.org. Briefly, in each experiment mice were injected with adeno-associated virus expressing a fluorescent protein. The virus infects neurons in the injection site, causing them to produce the protein, which is transported throughout the axonal and dendritic processes. The mouse brains for each experiment were then sliced, imaged, and aligned onto the common coordinates in the Allen Reference Atlas version 3 [15, 18]. These coordinates divide the brain volume into 100 µm × 100 µm × 100 µm voxels, with approximately 5 × 105 voxels in the whole brain. The fluorescent pixels in each aligned image were segmented from the background, and we use the fraction of segmented versus total pixels in a voxel to build the vectors x and y. Since cortical dendrites project locally, the signal outside the injection site is mostly axonal, and so the method reveals anterograde axonal projections from the injection site. From this dataset, we selected 28 experiments which have 95% of their injection volumes contained within the visual cortex (atlas regions VISal, VISam, VISl, VISp, VISpl, VISpm, VISli, VISpor, VISrl, and VISa) and injection volume less than 0.7 mm3. For this study, we present only the results for ipsilateral connectivity, where S = T and nx = ny = 7497. To compute the smoothing penalty, we used the 7-point finite-difference Laplacian on the cubic voxel lattice. 6 Model Voxel MSErel Regional MSErel Regional 107% (70%) 48% (6.8%) Voxel 33% (10%) 16% (2.3%) Table 1: Model performance on Allen Institute Mouse Brain Connectivity Atlas data. Cross-validation errors of the voxel model (P1) and regionally homogeneous models are shown, with training errors in parentheses. The errors are computed in both voxel space and regional space, using the relative mean squared error MSErel, Eqn. (4). In either space, the voxel model shows reduced training and cross-validation errors relative to the regional model. In order to evaluate the performance of the estimator, we employ nested cross-validation with 5 inner and outer folds. The full rank estimator (P1) was fit for λ = 103, 104, . . . , 1012 on the training data. Using the validation data, we then selected the λopt that minimized the mean square error relative to the average squared norm of the prediction WX and truth Y , evaluating errors outside the injection sites: MSErel = 2∥PΩ(WX −Y )∥2 F ∥PΩ(WX)∥2 F + ∥PΩ(Y )∥2 F . (4) This choice of normalization prevents experiments with small ∥Y ∥from dominating the error. This error metric as well as the ℓ2-loss adopted in Eqn. (P1) both more heavily weight the experiments with larger signal. After selection of λopt, the model was refit to the combined training and validation data. In our dataset, λopt = 105 was selected for all outer folds. The final errors were computed with the test datasets in each outer fold. For comparison, we also fit a regional model within the cross-validation framework, using nonnegative least squares. To do this, similar to the study by Oh et al. [18], we constrained the connectivity Wkl = WRiRj to be constant for all voxels k in region Ri and l in region Rj. The results are shown in Table 1. Errors were computed according to both voxels and regions. For the latter, we integrated the residual over voxels within the regions before computing the error. The voxel model is more predictive of held-out data than the regional model, reducing the voxel and regional MSErel by 69% and 67%, respectively. The regional model is designed for inter-region connectivity. To allow an easier comparison with the voxel model, we here include within region connections. We find that the regional model is a poor predictor of voxel scale projections, with over 100% relative voxel error, but it performs okay at the regional scale. The training errors, which reflect goodness of fit, were also reduced significantly with the voxel model. We conclude that the more flexible voxel model is a better estimator for these Allen Institute data, since it improves both the fits to training data as well as cross-validation skill. The inferred visual connectivity also exhibits a number of features that we expect. There are strong local projections (similar to the diagonal in the test problem, Fig. 2) along with spatially organized projections to higher visual areas. See Fig. 3, which shows example projections from source voxels within VISp. These are just two of 7497 voxels in the full matrix, and we depict only a 2-D projection of 3-D images. The connectivity exhibits strong local projections, which must be filled in by the smoothing since within the injection sites the projection data are unknown; it is surprising how well the algorithm does at capturing short-range connectivity that is translationally invariant. There are also long-range bumps in the higher visual areas, medial and lateral, which move with the source voxel. This is a result of retinotopic maps between VISp and downstream areas. The supplementary material presents a view of this high-dimensional matrix in movie form, allowing one to see the varying projections as the seed voxel moves. We encourage the reader to view the supplemental movies, where movement of bumps in downstream regions hints at the underlying retinotopy: https://github.com/kharris/high-res-connectivity-nips-2016. 5.1 Low rank inference successfully approximates full rank solution for visual system We next use these visual system data, for which the full rank solution was computed, to test whether the low rank approximation can be applied. This is an important stepping stone to an eventual inference of spatial connectivity for the full brain. First, we note that the singular value spectrum of the fitted W ∗ full (now using all 28 injections and λ = 105) is heavily skewed: 95% of the energy can be captured with 21 of 7497 components, and 99% with 67 components. However, this does not directly imply that a nonnegative factorization will 7 Figure 3: Inferred connectivity using all 28 selected injections from visual system data. Left, Projections from a source voxel (blue) located in VISp to all other voxels in the visual areas. The view is integrated over the superior-inferior axis. The connectivity shows strong local connections and weaker connections to higher areas, in particular VISam, VISal, and VISl. Movies of the inferred connectivity (full, low rank, and the low rank residual) for varying source voxel are available in the supplementary material. Center, For a source 800 µm voxels away, the pattern of anterograde projections is similar, but the distal projection centers are shifted, as expected from retinotopy. Right, The residuals between the full rank and rank 160 result from solving (P2), for the same source voxel as in the center. The residuals are an order of magnitude less than typical features of the connectivity. perform as well. To test this, we fit a low rank decomposition directly to all 28 visual injection data using (P2) with rank r = 160 and λ = 105. The output of the optimization procedure yields U ∗and V ∗, and we find that the low rank output is very similar to the full result W ∗ full fit to the same data (see also Fig. 3, which visualizes the residuals): ∥U ∗V ∗T −W ∗ full∥F ∥W ∗ full∥F = 13%. This close approximation is despite the fact that the low rank solution achieves a roughly 23× compression of the 7497 × 7497 matrix. Assuming similar compressibility for the whole brain, where the number of voxels is 5 × 105, would mean a rank of approximately 104. This is still a problem in O(109) unknowns, but these bring the memory requirements of storing one matrix iterate in double precision from approximately 1.9 TB to 75 GB, which is within reach of commonly available large memory machines. 6 Conclusions We have developed and implemented a new inference algorithm that uses modern machine learning ideas—matrix completion loss, a smoothing penalty, and low rank factorization—to assimilate sparse connectivity data into complete, spatially explicit connectivity maps. We have shown that this method can be applied to the latest Allen Institute data from multiple visual cortical areas, and that it significantly improves cross-validated predictions over the current state of the art and unveils spatial patterning of connectivity. Finally, we show that a low rank version of the algorithm produces very similar results on these data while compressing the connectivity map, potentially opening the door to the inference of whole brain connectivity from viral tracer data at the voxel scale. Acknowledgements We acknowledge the support of the UW NIH Training Grant in Big Data for Neuroscience and Genetics (KDH), Boeing Scholarship (KDH), NSF Grant DMS-1122106 and 1514743 (ESB & KDH), and a Simons Fellowship in Mathematics (ESB). We thank Liam Paninski for helpful insights at the outset of this project. We wish to thank the Allen Institute founders, Paul G. Allen and Jody Allen, for their vision, encouragement, and support. This work was facilitated though the use of advanced computational, storage, and networking infrastructure provided by the Hyak supercomputer system at the University of Washington. References [1] Argyriou, A., Micchelli, C. A., and Pontil, M. (2009). When Is There a Representer Theorem? Vector Versus Matrix Regularizers. J. Mach. Learn. Res., 10:2507–2529. 8 [2] Bock, D. D., Lee, W.-C. A., Kerlin, A. M., Andermann, M. L., Hood, G., Wetzel, A. W., Yurgenson, S., Soucy, E. R., Kim, H. S., and Reid, R. C. (2011). Network anatomy and in vivo physiology of visual cortical neurons. Nature, 471(7337):177–182. [3] Boyd, S. and Vandenberghe, L. (2004). Convex Optimization. Cambridge University Press, New York, NY, USA. [4] Byrd, R., Lu, P., Nocedal, J., and Zhu, C. (1995). A Limited Memory Algorithm for Bound Constrained Optimization. SIAM Journal on Scientific Computing, 16(5):1190–1208. [5] Candes, E. and Tao, T. (2010). The Power of Convex Relaxation: Near-Optimal Matrix Completion. IEEE Transactions on Information Theory, 56(5):2053–2080. [6] Chaplin, T. A., Yu, H.-H., and Rosa, M. G. (2013). Representation of the visual field in the primary visual area of the marmoset monkey: Magnification factors, point-image size, and proportionality to retinal ganglion cell density. Journal of Comparative Neurology, 521(5):1001–1019. [7] Felleman, D. J. and Van Essen, D. C. (1991). Distributed Hierarchical Processing in the Primate. Cerebral Cortex, 1(1):1–47. [8] Garrett, M. E., Nauhaus, I., Marshel, J. H., and Callaway, E. M. (2014). Topography and Areal Organization of Mouse Visual Cortex. Journal of Neuroscience, 34(37):12587–12600. [9] Glickfeld, L. L., Andermann, M. L., Bonin, V., and Reid, R. C. (2013). Cortico-cortical projections in mouse visual cortex are functionally target specific. Nature Neuroscience, 16(2). [10] Goodman, C. S. and Shatz, C. J. (1993). Developmental mechanisms that generate precise patterns of neuronal connectivity. Cell, 72, Supplement:77–98. [11] Hubel, D. H. and Wiesel, T. N. (1962). Receptive fields, binocular interaction and functional architecture in the cat’s visual cortex. The Journal of Physiology, 160(1):106–154.2. [12] Jenett, A., Rubin, G. M., Ngo, T.-T. B., Shepherd, D., Murphy, C., Dionne, H., Pfeiffer, B. D., Cavallaro, A., Hall, D., Jeter, J., Iyer, N., Fetter, D., Hausenfluck, J. H., Peng, H., Trautman, E. T., Svirskas, R. R., Myers, E. W., Iwinski, Z. R., Aso, Y., DePasquale, G. M., Enos, A., Hulamm, P., Lam, S. C. B., Li, H.-H., Laverty, T. R., Long, F., Qu, L., Murphy, S. D., Rokicki, K., Safford, T., Shaw, K., Simpson, J. H., Sowell, A., Tae, S., Yu, Y., and Zugates, C. T. (2012). A GAL4-Driver Line Resource for Drosophila Neurobiology. Cell Reports, 2(4):991–1001. [13] Jonas, E. and Kording, K. (2015). Automatic discovery of cell types and microcircuitry from neural connectomics. eLife, 4:e04250. [14] Kleinfeld, D., Bharioke, A., Blinder, P., Bock, D. D., Briggman, K. L., Chklovskii, D. B., Denk, W., Helmstaedter, M., Kaufhold, J. P., Lee, W.-C. A., Meyer, H. S., Micheva, K. D., Oberlaender, M., Prohaska, S., Reid, R. C., Smith, S. J., Takemura, S., Tsai, P. S., and Sakmann, B. (2011). Large-Scale Automated Histology in the Pursuit of Connectomes. The Journal of Neuroscience, 31(45):16125–16138. [15] Kuan, L., Li, Y., Lau, C., Feng, D., Bernard, A., Sunkin, S. M., Zeng, H., Dang, C., Hawrylycz, M., and Ng, L. (2015). Neuroinformatics of the Allen Mouse Brain Connectivity Atlas. Methods, 73:4–17. [16] Lin, C.-J. (2007). Projected Gradient Methods for Nonnegative Matrix Factorization. Neural Computation, 19(10):2756–2779. [17] Lynch, R. E., Rice, J. R., and Thomas, D. H. (1964). Tensor product analysis of partial difference equations. Bulletin of the American Mathematical Society, 70(3):378–384. [18] Oh, S. W., Harris, J. A., Ng, L., Winslow, B., Cain, N., Mihalas, S., Wang, Q., Lau, C., Kuan, L., Henry, A. M., Mortrud, M. T., Ouellette, B., Nguyen, T. N., Sorensen, S. A., Slaughterbeck, C. R., Wakeman, W., Li, Y., Feng, D., Ho, A., Nicholas, E., Hirokawa, K. E., Bohn, P., Joines, K. M., Peng, H., Hawrylycz, M. J., Phillips, J. W., Hohmann, J. G., Wohnoutka, P., Gerfen, C. R., Koch, C., Bernard, A., Dang, C., Jones, A. R., and Zeng, H. (2014). A mesoscale connectome of the mouse brain. Nature, 508(7495):207–214. [19] Peng, H., Tang, J., Xiao, H., Bria, A., Zhou, J., Butler, V., Zhou, Z., Gonzalez-Bellido, P. T., Oh, S. W., Chen, J., Mitra, A., Tsien, R. W., Zeng, H., Ascoli, G. A., Iannello, G., Hawrylycz, M., Myers, E., and Long, F. (2014). Virtual finger boosts three-dimensional imaging and microsurgery as well as terabyte volume image visualization and analysis. Nature Communications, 5. [20] Rosa, M. G. and Tweedale, R. (2005). Brain maps, great and small: Lessons from comparative studies of primate visual cortical organization. Philosophical Transactions of the Royal Society B: Biological Sciences, 360(1456):665–691. [21] Sporns, O. (2010). Networks of the Brain. The MIT Press, 1st edition. [22] Udin, S. B. and Fawcett, J. W. (1988). Formation of Topographic Maps. Annual Review of Neuroscience, 11(1):289–327. [23] Van Loan, C. F. (2000). The ubiquitous Kronecker product. Journal of Computational and Applied Mathematics, 123(1–2):85–100. [24] Wahba, G. (1990). Spline Models for Observational Data. SIAM. [25] Wang, Q. and Burkhalter, A. (2007). Area map of mouse visual cortex. The Journal of Comparative Neurology, 502(3):339–357. [26] White, J. G., Southgate, E., Thomson, J. N., and Brenner, S. (1986). The Structure of the Nervous System of the Nematode Caenorhabditis elegans. Philosophical Transactions of the Royal Society of London B: Biological Sciences, 314(1165):1–340. 9 | 2016 | 541 |
6,485 | Learning and Forecasting Opinion Dynamics in Social Networks Abir De∗ Isabel Valera† Niloy Ganguly∗ Sourangshu Bhattacharya∗ Manuel Gomez-Rodriguez† IIT Kharagpur∗ MPI for Software Systems† {abir.de,niloy,sourangshu}@cse.iitkgp.ernet.in {ivalera,manuelgr}@mpi-sws.org Abstract Social media and social networking sites have become a global pinboard for exposition and discussion of news, topics, and ideas, where social media users often update their opinions about a particular topic by learning from the opinions shared by their friends. In this context, can we learn a data-driven model of opinion dynamics that is able to accurately forecast users’ opinions? In this paper, we introduce SLANT, a probabilistic modeling framework of opinion dynamics, which represents users’ opinions over time by means of marked jump diffusion stochastic differential equations, and allows for efficient model simulation and parameter estimation from historical fine grained event data. We then leverage our framework to derive a set of efficient predictive formulas for opinion forecasting and identify conditions under which opinions converge to a steady state. Experiments on data gathered from Twitter show that our model provides a good fit to the data and our formulas achieve more accurate forecasting than alternatives. 1 Introduction Social media and social networking sites are increasingly used by people to express their opinions, give their “hot takes”, on the latest breaking news, political issues, sports events, and new products. As a consequence, there has been an increasing interest on leveraging social media and social networking sites to sense and forecast opinions, as well as understand opinion dynamics. For example, political parties routinely use social media to sense people’s opinion about their political discourse1; quantitative investment firms measure investor sentiment and trade using social media [18]; and, corporations leverage brand sentiment, estimated from users’ posts, likes and shares in social media and social networking sites, to design their marketing campaigns2. In this context, multiple methods for sensing opinions, typically based on sentiment analysis [21], have been proposed in recent years. However, methods for accurately forecasting opinions are still scarce [7, 8, 19], despite the extensive literature on theoretical models of opinion dynamics [6, 9]. In this paper, we develop a novel modeling framework of opinion dynamics in social media and social networking sites, SLANT3, which allows for accurate forecasting of individual users’ opinions. The proposed framework is based on two simple intuitive ideas: i) users’ opinions are hidden until they decide to share it with their friends (or neighbors); and, ii) users may update their opinions about a particular topic by learning from the opinions shared by their friends. While the latter is one of the main underlying premises used by many well-known theoretical models of opinion dynamics [6, 9, 22], the former has been ignored by models of opinion dynamics, despite its relevance on closely related processes such as information diffusion [12]. 1http://www.nytimes.com/2012/10/08/technology/campaigns-use-social-media-to-lure-younger-voters.html 2http://www.nytimes.com/2012/07/31/technology/facebook-twitter-and-foursquare-as-corporate-focus-groups.html 3Slant is a particular point of view from which something is seen or presented. 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. More in detail, our proposed model represents users’ latent opinions as continuous-time stochastic processes driven by a set of marked jump stochastic differential equations (SDEs) [14]. Such construction allows each user’s latent opinion to be modulated over time by the opinions asynchronously expressed by her neighbors as sentiment messages. Here, every time a user expresses an opinion by posting a sentiment message, she reveals a noisy estimate of her current latent opinion. Then, we exploit a key property of our model, the Markov property, to develop: I. An efficient estimation procedure to find the parameters that maximize the likelihood of a set of (millions of) sentiment messages via convex programming. II. A scalable simulation procedure to sample millions of sentiment messages from the proposed model in a matter of minutes. III. A set of novel predictive formulas for efficient and accurate opinion forecasting, which can also be used to identify conditions under which opinions converge to a steady state of consensus or polarization. Finally, we experiment on both synthetic and real data gathered from Twitter and show that our model provides a good fit to the data and our predictive formulas achieve more accurate opinion forecasting than several alternatives [7, 8, 9, 15, 26]. Related work. There is an extensive line of work on theoretical models of opinion dynamics and opinion formation [3, 6, 9, 15, 17, 26]. However, previous models typically share the following limitations: (i) they do not distinguish between latent opinion and sentiment (or expressed opinion), which is a noisy observation of the opinion (e.g., thumbs up/down, text sentiment); (ii) they consider users’ opinions to be updated synchronously in discrete time, however, opinions may be updated asynchronously following complex temporal patterns [12]; (iii) the model parameters are difficult to learn from real fine-grained data and instead are set arbitrarily, as a consequence, they provide inaccurate fine-grained predictions; and, (iv) they focus on analyzing only the steady state of the users’ opinions, neglecting the transient behavior of real opinion dynamics which allows for opinion forecasting methods. More recently, there have been some efforts on designing models that overcome some of the above limitations and provide more accurate predictions [7, 8]. However, they do not distinguish between opinion and sentiment and still consider opinions to be updated synchronously in discrete time. Our modeling framework addresses the above limitations and, by doing so, achieves more accurate opinion forecasting than alternatives. 2 Proposed model In this section, we first formulate our model of opinion dynamics, starting from the data it is designed for, and then introduce efficient methods for model parameter estimation and model simulation. Opinions data. Given a directed social network G = (V, E), we record each message as e := (u, m, t), where the triplet means that the user u ∈V posted a message with sentiment m at time t. Given a collection of messages {e1 = (u1, m1, t1), . . . , en = (un, mn, tn)}, the history Hu(t) gathers all messages posted by user u up to but not including time t, i.e., Hu(t) = {ei = (ui, mi, ti)|ui = u and ti < t}, (1) and H(t) := ∪u∈VHu(t) denotes the entire history of messages up to but not including time t. Generative process. We represent users’ latent opinions as a multidimensional stochastic process x∗(t), in which the u-th entry, x∗ u(t) ∈R, represents the opinion of user u at time t and the sign ∗ means that it may depend on the history H(t). Then, every time a user u posts a message at time t, we draw its sentiment m from a sentiment distribution p(m|x∗ u(t)). Here, we can also think of the sentiment m of each message as samples from a noisy stochastic process mu(t) ∼p(mu(t)|x∗ u(t)). Further, we represent the message times by a set of counting processes. In particular, we denote the set of counting processes as a vector N(t), in which the u-th entry, Nu(t) ∈{0} ∪Z+, counts the number of sentiment messages user u posted up to but not including time t. Then, we can characterize the message rate of the users using their corresponding conditional intensities as E[dN(t) | H(t)] = λ∗(t) dt, (2) where dN(t) := ( dNu(t) )u∈V denotes the number of messages per user in the window [t, t + dt) and λ∗(t) := ( λ∗ u(t) )u∈V denotes the associated user intensities, which may depend on the history H(t). We denote the set of user that u follows by N(u). Next, we specify the the intensity functions λ∗(t), the dynamics of the users’ opinions x∗(t), and the sentiment distribution p(m|x∗ u(t)). 2 Intensity for messages. There is a wide variety of message intensity functions one can choose from to model the users’ intensity λ∗(t) [1]. In this work, we consider two of the most popular functional forms used in the growing literature on social activity modeling using point processes [10, 24, 5]: I. Poisson process. The intensity is assumed to be independent of the history H(t) and constant, i.e., λ∗ u(t) = µu. II. Multivariate Hawkes processes. The intensity captures a mutual excitation phenomena between message events and depends on the whole history of message events ∪v∈{u∪N (u)}Hv(t) before t: λ∗ u(t) = µu + X v∈u∪N (u) bvu X ei∈Hv(t) κ(t −ti) = µu + X v∈u∪N (u) bvu (κ(t) ⋆dNv(t)), (3) where the first term, µu ⩾0, models the publication of messages by user u on her own initiative, and the second term, with bvu ⩾0, models the publication of additional messages by user u due to the influence that previous messages posted by the users she follows have on her intensity. Here, κ(t) = e−νt is an exponential triggering kernel modeling the decay of influence of the past events over time and ⋆denotes the convolution operation. In both cases, the couple (N(t), λ∗(t)) is a Markov process, i.e., future states of the process (conditional on past and present states) depends only upon the present state, and we can express the users’ intensity more compactly using the following jump stochastic differential equation (SDE): dλ∗(t) = ν(µ −λ∗(t))dt + BdN(t), where the initial condition is λ∗(0) = µ. The Markov property will become important later. Stochastic process for opinion. The opinion x∗ u(t) of a user u at time t adopts the following form: x∗ u(t) = αu + X v∈N (u) avu X ei∈Hv(t) mig(t −ti) = αu + X v∈N (u) avu (g(t) ⋆(mv(t)dNv(t))), (4) where the first term, αu ∈R, models the original opinion a user u starts with, the second term, with avu ∈R, models updates in user u’s opinion due to the influence that previous messages with opinions mi posted by the users that u follows has on her opinion. Here, g(t) = e−ωt (where ω ⩾0) denotes an exponential triggering kernel, which models the decay of influence over time. The greater the value of ω, the greater the user’s tendency to retain her own opinion αu. Under this form, the resulting opinion dynamics are Markovian and can be compactly represented by a set of coupled marked jumped stochastic differential equations (proven in Appendix A): Proposition 1 The tuple (x∗(t), λ∗(t), N(t)) is a Markov process, whose dynamics are defined by the following marked jumped stochastic differential equations (SDE): dx∗(t) = ω(α −x∗(t))dt + A(m(t) ⊙dN(t)) (5) dλ∗(t) = ν(µ −λ∗(t))dt + B dN(t) (6) where the initial conditions are λ∗(0) = µ and x∗(0) = α, the marks are the sentiment messages m(t) = ( mu(t) )u∈V, with mu(t) ∼p(m|x∗ u(t)), and the sign ⊙denotes pointwise product. The above mentioned Markov property will be the key to the design of efficient model parameter estimation and model simulation algorithms. Sentiment distribution. The particular choice of sentiment distribution p(m|x∗ u(t)) depends on the recorded marks. For example, one may consider: I. Gaussian Distribution The sentiment is assumed to be a real random variable m ∈R, i.e., p(m|xu(t)) = N(xu(t), σu). This fits well scenarios in which sentiment is extracted from text using sentiment analysis [13]. II. Logistic. The sentiment is assumed to be a binary random variable m ∈{−1, 1}, i.e., p(m|xu(t)) = 1/(1 + exp(−m · xu(t))). This fits well scenarios in which sentiment is measured by means of up votes, down votes or likes. Our model estimation method can be easily adapted to any log-concave sentiment distribution. However, in the remainder of the paper, we consider the Gaussian distribution since, in our experiments, sentiment is extracted from text using sentiment analysis. 3 2.1 Model parameter estimation Given a collection of messages H(T) = {(ui, mi, ti)} recorded during a time period [0, T) in a social network G = (V, E), we can find the optimal parameters α, µ, A and B by solving a maximum likelihood estimation (MLE) problem4. To do so, it is easy to show that the log-likelihood of the messages is given by L(α, µ, A, B) = X ei∈H(T ) log p(mi|x∗ ui(ti)) | {z } message sentiments + X ei∈H(T ) log λ∗ ui(ti) − X u∈V Z T 0 λ∗ u(τ) dτ | {z } message times . (7) Then, we can find the optimal parameters (α, µ, A, B) using MLE as maximize α,µ≥0,A,B≥0 L(α, µ, A, B). (8) Note that, as long as the sentiment distributions are log-concave, the MLE problem above is concave and thus can be solved efficiently. Moreover, the problem decomposes in 2|V| independent subproblems, two per user u, since the first term in Eq. 7 only depends on (α, A) whereas the last two terms only depend on (µ, B), and thus can be readily parallelized. Then, we find (µ∗, B∗) using spectral projected gradient descent [4], which works well in practice and achieves ε accuracy in O(log(1/ε)) iterations, and find (α∗, A∗) analytically, since, for Gaussian sentiment distributions, the problem reduces to a least-square problem. Fortunately, in each subproblem, we can use the Markov property from Proposition 1 to precompute the sums and integrals in (8) in linear time, i.e., O(|Hu(T)| + | ∪v∈N (u) Hv(T)|). Appendix H summarizes the overall estimation algorithm. 2.2 Model simulation We leverage the efficient sampling algorithm for multivariate Hawkes introduced by Farajtabar et al. [11] to design a scalable algorithm to sample opinions from our model. The two key ideas that allow us to adapt the procedure by Farajtabar et al. to our model of opinion dynamics, while keeping its efficiency, are as follows: (i) the opinion dynamics, defined by Eqs. 5 and 6, are Markovian and thus we can update individual intensities and opinions in O(1) – let ti and ti+1 be two consecutive events, then, we can compute λ∗(ti+1) as (λ∗(ti) −µ) exp(−ν(ti+1 −ti)) + µ and x∗(ti+1) as (x∗(ti) −α) exp(−ω(ti+1 −ti)) + α, respectively; and, (ii) social networks are typically sparse and thus both A and B are also sparse, then, whenever a node expresses its opinion, only a small number of opinions and intensity functions in its local neighborhood will change. As a consequence, we can reuse the majority of samples from the intensity functions and sentiment distributions for the next new sample. Appendix I summarizes the overall simulation algorithm. 3 Opinion forecasting Our goal here is developing efficient methods that leverage our model to forecast a user u’s opinion xu(t) at time t given the history H(t0) up to time t0<t. In the context of our probabilistic model, we will forecast this opinion by efficiently computing the conditional expectation EH(t)\H(t0)[x∗ u(t)|H(t0)], where H(t)\H(t0) denotes the average across histories from t0 to t, while conditioning on the history up to H(t0). To this aim, we will develop analytical and sampling based methods to compute the above conditional expectation. Moreover, we will use the former to identify under which conditions users’ average opinion converges to a steady state and, if so, find the steady state opinion. In this section, we write Ht = H(t) to lighten the notation and denote the eigenvalues of a matrix X by ξ(X). 3.1 Analytical forecasting In this section, we derive a set of formulas to compute the conditional expectation for both Poisson and Hawkes messages intensities. However, since the derivation of such formulas for general multivariate Hawkes is difficult, we focus here on the case when bvu = 0 for all v, u ∈G, v ̸= u, and rely on the efficient sampling based method for the general case. I. Poisson intensity. Consider each user’s messages follow a Poisson process with rate µu. Then, the conditional average opinion is given by (proven in Appendix C): 4Here, if one decides to model the message intensities with a Poisson process, B = 0. 4 Theorem 2 Given a collection of messages Ht0 recorded during a time period [0, t0) and λ∗ u(t) = µu for all u ∈G, then, EHt\Ht0 [x∗(t)|Ht0] = e(AΛ1−ωI)(t−t0)x(t0) + ω(AΛ1 −ωI)−1 e(AΛ1−ωI)(t−t0) −I α, (9) where Λ1 := diag[µ] and (x(t0))u∈V = αu + P v∈N (u) auv P ti∈Hv(t0) e−ω(t0−ti)mv(ti). Remarkably, we can efficiently compute both terms in Eq. 9 by using the iterative algorithm by AlMohy et al. [2] for the matrix exponentials and the well-known GMRES method [23] for the matrix inversion. Given this predictive formula, we can easily study the stability condition and, for stable systems, find the steady state conditional average opinion (proven in Appendix D): Theorem 3 Given the conditions of Theorem 2, if Re[ξ(AΛ1)] < ω, then, lim t→∞EHt\Ht0 [x∗(t)|Ht0] = I −AΛ1 w −1 α. (10) The above results indicate that the conditional average opinions are nonlinearly related to the parameter matrix A, which depends on the network structure, and the message rates µ, which in this case are assumed to be constant and independent on the network structure. Figure 1 provides empirical evidence of these results. II. Multivariate Hawkes Process. Consider each user’s messages follow a multivariate Hawkes process, given by Eq. 3, and bvu = 0 for all v, u ∈G, v ̸= u. Then, the conditional average opinion is given by (proven in Appendix E): Theorem 4 Given a collection of messages Ht0 recorded during a time period [0, t0) and λ∗ u(t) = µu + buu P ei∈Hu(t) e−ν(t−ti) for all u ∈G, then, the conditional average satisfies the following differential equation: dEHt\Ht0 [x∗(t)|Ht0] dt = [−ωI + AΛ(t)]EHt\Ht0 [x∗(t)|Ht0] + ωα, (11) where Λ(t) = diag EHt\Ht0 [λ∗(t)|Ht0] , EHt\Ht0 [λ∗(t)|Ht0] = e(B−νI)(t−t0)η(t0) + ν(B −νI)−1 e(B−νI)(t−t0) −I µ ∀t ≥t0, (η(t0))u∈V = µu + X v∈N (u) buv X ti∈Hv(t0) e−ν(t0−ti), B = diag [b11, . . . , b|V||V|]⊤ . Here, we can compute the conditional average by solving numerically the differential equation above, which is not stochastic, where we can efficiently compute the vector EHt[λ∗(t)] by using again the algorithm by Al-Mohy et al. [2] and the GMRES method [23]. In this case, the stability condition and the steady state conditional average opinion are given by (proven in Appendix F): Theorem 5 Given the conditions of Theorem 4, if the transition matrix Φ(t) associated to the timevarying linear system described by Eq. 11 satisfies that ||Φ(t)|| ≤γe−ct ∀t > 0, where γ, c > 0, then, lim t→∞EHt\Ht0 [x∗(t)|Ht0] = I −AΛ2 w −1 α, (12) where Λ2 := diag h I −B ν −1 µ i The above results indicate that the conditional average opinions are nonlinearly related to the parameter matrices A and B. This suggests that the effect of the temporal influence on the opinion evolution, by means of the parameter matrix B of the multivariate Hawkes process, is non trivial. We illustrate this result empirically in Figure 1. 5 Network G1 Time Opinion-Trajectory→ Experimental Theoretical 0.005 0.01 0.015 0.5 1.5 0 0 1 P: P u∈V± E[xu(t)] |V ±| Time Opinion-Trajectory→ Hawkes (-) Hawkes (+) 0.005 0.01 0.015 -4 -2 2 4 0 0 H: P u∈V± E[xu(t)] |V ±| 0.01 0.005 0.015 00 10 20 30 40 50 Time Node-ID P: Temporal evolution 0.005 0.01 0.015 Node-ID Time 10 20 30 40 50 00 H: Temporal evolution Network G2 Time Opinion-Trajectory→ Experimental Theoretical 0.005 0.01 0.015 -1.5 -0.5 -2 -1 0 0 P: P u∈V E[xu(t)] |V | Time Opinion-Trajectory→ Hawkes (-) Hawkes (+) 0.005 0.01 0.015 -20 -10 10 20 30 40 0 0 H: P u∈V E[xu(t)] |V | 0.01 0.005 0.015 00 10 20 30 40 50 Time Node-ID P: Temporal evolution 0.005 0.01 0.015 Node-ID Time 10 20 30 40 50 00 H: Temporal evolution Figure 1: Opinion dynamics on two 50-node networks G1 (top) and G2 (bottom) for Poisson (P) and Hawkes (H) message intensities. The first column visualizes the two networks and opinion of each node at t = 0 (positive/negative opinions in red/blue). The second column shows the temporal evolution of the theoretical and empirical average opinion for Poisson intensities. The third column shows the temporal evolution of the empirical average opinion for Hawkes intensities, where we compute the average separately for positive (+) and negative (−) opinions in the steady state. The fourth and fifth columns shows the polarity of average opinion per user over time. 3.2 Simulation based forecasting Given the efficient simulation procedure described in Section 2.2, we can readily derive a general simulation based formula for opinion forecasting: EHt\Ht0 [x∗(t)|Ht0] ≈ˆx∗(t) = 1 n n X l=1 x∗ l (t), (13) where n is the number of times that we simulate the opinion dynamics and x∗ l (t) gathers the users’ opinion at time t for the l-th simulation. Moreover, we have the following theoretical guarantee (proven in Appendix G): Theorem 6 Simulate the opinion dynamics up to time t > t0 the following number of times: n ≥ 1 3ϵ2 (6σ2 max + 4xmaxϵ) log(2/δ), (14) where σ2 max = maxu∈G σ2 Ht\Ht0 (x∗ u(t)|Ht0) is the maximum variance of the users’ opinions, which we analyze in Appendix G, and xmax ≥|xu(t)|, ∀u ∈G is an upper bound on the users’ (absolute) opinions. Then, for each user u ∈G, the error between her true and estimated average opinion satisfies that |ˆx∗ u(t) −EHt\Ht0 [x∗ u(t)|Ht0]| ≤ϵ with probability at least 1 −δ. 4 Experiments 4.1 Experiments on synthetic data We first provide empirical evidence that our model is able to produce different types of opinion dynamics, which may or may not converge to a steady state of consensus or polarization. Then, we show that our model estimation and simulation algorithms as well as our predictive formulas scale to networks with millions of users and events. Appendix J contains an evaluation of the accuracy of our model parameter estimation method. Different types of opinion dynamics. We first simulate our model on two different small networks using Poisson intensities, i.e., λ∗ u(t) = µu, µu ∼U(0, 1) ∀u, and then simulate our model on the same networks while using Hawkes intensities with bvu ∼U(0, 1) on 5% of the nodes, chosen at random, and the original Poisson intensities on the remaining nodes. Figure 1 summarizes the results, which show that (i) our model is able to produce opinion dynamics that converge to consensus (second column) and polarization (third column); (ii) the opinion forecasting formulas described in Section 3 closely match an simulation based estimation (second column); and, (iii) the evolution of 6 Informational Temporal Nodes Time (s) 101 102 103 104 105 106 10−2 10−1 100 101 102 103 104 105 (a) Estimation vs # nodes Nodes Time(s) 101 102 103 104 105 106 10−2 10−1 101 101 102 103 104 105 (b) Simulation vs # nodes Poisson Hawkes Nodes Time (s) 102 103 104 105 106 107 10−2 10−1 100 101 102 103 104 105 (c) Forecast vs # nodes 02 4 5 6 8 10 10 15 Poisson Hawkes Forecast-Time[T(hr)] Time (s) (d) Forecast vs T Figure 2: Panels (a) and (b) show running time of our estimation and simulation procedures against number of nodes, where the average number of events per node is 10. Panels (c) and (d) show the running time needed to compute our analytical formulas against number of nodes and time horizon T = t−t0, where the number of nodes is 103. In Panel (c), T = 6 hours. For all panels, the average degree per node is 30. The experiments are carried out in a single machine with 24 cores and 64 GB of main memory. the average opinion and whether opinions converge to a steady state of consensus or polarization depend on the functional form of message intensity5. Scalability. Figure 2 shows that our model estimation and simulation algorithms, described in Sections 2.1 and 2.2, and our analytical predictive formulas, described in Section 3.1, scale to networks with millions of users and events. For example, our algorithm takes 20 minutes to estimate the model parameters from 10 million events generated by one million nodes using a single machine with 24 cores and 64 GB RAM. 4.2 Experiments on real data We use real data gathered from Twitter to show that our model can forecast users’ opinions more accurately than six state of the art methods [7, 8, 9, 15, 19, 26] (see Appendix L). Experimental Setup. We experimented with five Twitter datasets about current real-world events (Politics, Movie, Fight, Bollywood and US), in which, for each recorded message i, we compute its sentiment value mi using a popular sentiment analysis toolbox, specially designed for Twitter [13]. Here, the sentiment takes values m ∈(−1, 1) and we consider the sentiment polarity to be simply sign(m). Appendix K contains further details and statistics about these datasets. Opinion forecasting. We first evaluate the performance of our model at predicting sentiment (expressed opinion) at a message level. To do so, for each dataset, we first estimate the parameters of our model, SLANT, using messages from a training set containing the (chronologically) first 90% of the messages. Here, we set the decay parameters of the exponential triggering kernels κ(t) and g(t) by cross-validation. Then, we evaluate the predictive performance of our opinion forecasting formulas using the last 10% of the messages6. More specifically, we predict the sentiment value m for each message posted by user u in the test set given the history up to T hours before the time of the message as ˆm = EHt\Ht−T [x∗ u(t)|Ht−T ]. We compare the performance of our model with the asynchronous linear model (AsLM) [8], DeGroot’s model [9], the voter model [26], the biased voter model [7], the flocking model [15], and the sentiment prediction method based on collaborative filtering by Kim et al. [19], in terms of: (i) the mean squared error between the true (m) and the estimated ( ˆm) sentiment value for all messages in the held-out set, i.e., E[(m −ˆm)2], and (ii) the failure rate, defined as the probability that the true and the estimated polarity do not coincide, i.e., P(sign(m) ̸= sign( ˆm)). For the baselines algorithms, which work in discrete time, we simulate NT rounds in (t −T, t), where NT is the number of posts in time T. Figure 3 summarizes the results, which show that: (i) our opinion forecasting formulas consistently outperform others both in terms of MSE (often by an order of magnitude) and failure rate;7 (ii) its forecasting performance degrades gracefully with respect to T, in contrast, competing methods often fail catastrophically; and, (iii) it achieves an additional mileage by using Hawkes processes instead of Poisson processes. To some extent, we believe SLANT’s superior performance is due to its ability to leverage historical data to learn its model parameters and then simulate realistic temporal patterns. Finally, we look at the forecasting results at a network level and show that our forecasting formulas can also predict the evolution of opinions macroscopically (in terms of the average opinion across users). Figure 4 summarizes the results for two real world datasets, which show that the forecasted 5For these particular networks, Poisson intensities lead to consensus while Hawkes intensities lead to polarization, however, we did find other examples in which Poisson intensities lead to polarization and Hawkes intensities lead to consensus. 6Here, we do not distinguish between analytical and sampling based forecasting since, in practice, they closely match each other. 7The failure rate is very close to zero for those datasets in which most users post messages with the same polarity. 7 Collab-Filter Flocking BiasedVoter Linear Voter DeGroot SLANT (P) SLANT (H) 0 2 4 6 8 10 T, hours MSE 10−2 10−1 100 101 0 2 4 6 8 10 T, hours 0 2 4 6 8 10 T, hours 0 2 4 6 8 10 T, hours 0 2 4 6 8 10 T, hours 00 1 2 4 6 8 10 0.2 0.4 0.6 0.8 T, hours Failure-Rate (a) Politics 0 2 4 6 8 10 T, hours (b) Movie 0 2 4 6 8 10 T, hours (c) Fight 0 2 4 6 8 10 T, hours (d) Bollywood 0 2 4 6 8 10 T, hours (e) US Figure 3: Sentiment prediction performance using a 10% held-out set for each real-world dataset. Performance is measured in terms of mean squared error (MSE) on the sentiment value, E[(m − ˆm)2], and failure rate on the sentiment polarity, P(sign(m) ̸= sign( ˆm)). For each message in the held-out set, we predict the sentiment value m given the history up to T hours before the time of the message, for different values of T. Nowcasting corresponds to T = 0 and forecasting to T > 0. The sentiment value m ∈(−1, 1) and the sentiment polarity sign (m) ∈{−1, 1}. 0.4 0.5 0.6 0.7 0.8 ¯m(t) ¯x(t) T = 1h T = 3h T = 5h Time Average Opinion→ 28 April 2 May 5 May (a) Tw: Movie (Hawkes) 0.4 0.5 0.6 0.7 0.8 ¯m(t) ¯x(t) T = 1h T = 3h T = 5h Time Average Opinion→ 28 April 2 May 5 May (b) Tw: Movie (Poisson) -0.4 -0.2 0.2 0.4 0.6 0.8 ¯m(t) ¯x(t) T = 1h T = 3h T = 5h Time Average Opinion→ 7 April 10 April 13 April 0 (c) Tw: US (Hawkes) -0.4 -0.2 0.2 0.4 0.6 0.8 ¯m(t) ¯x(t) T = 1h T = 3h T = 5h Time Average Opinion→ 7 April 10 April 13 April 0 (d) Tw: US (Poisson) Figure 4: Macroscopic sentiment prediction given by our model for two real-world datasets. The panels show the observed sentiment ¯m(t) (in blue, running average), inferred opinion ¯x(t) on the training set (in red), and forecasted opinion EHt\Ht−T [xu(t)|Ht−T ] for T = 1, 3, and 5 hours on the test set (in black, green and gray, respectively), where the symbol¯denotes average across users. opinions become less accurate as the time T becomes larger, since the average is computed on longer time periods. As expected, our model is more accurate when the message intensities are modeled using multivariate Hawkes. We found qualitatively similar results for the remaining datasets. 5 Conclusions We proposed a modeling framework of opinion dynamics, whose key innovation is modeling users’ latent opinions as continuous-time stochastic processes driven by a set of marked jump stochastic differential equations (SDEs) [14]. Such construction allows each user’s latent opinion to be modulated over time by the opinions asynchronously expressed by her neighbors as sentiment messages. We then exploited a key property of our model, the Markov property, to design efficient parameter estimation and simulation algorithms, which scale to networks with millions of nodes. Moreover, we derived a set of novel predictive formulas for efficient and accurate opinion forecasting and identified conditions under which opinions converge to a steady state of consensus or polarization. Finally, we experimented with real data gathered from Twitter and showed that our framework achieves more accurate opinion forecasting than state-of-the-arts. Our model opens up many interesting venues for future work. For example, in Eq. 4, our model assumes a linear dependence between users’ opinions, however, in some scenarios, this may be a coarse approximation. A natural follow-up to improve the opinion forecasting accuracy would be considering nonlinear dependences between opinions. It would be interesting to augment our model to jointly consider correlations between different topics. One could leverage our modeling framework to design opinion shaping algorithms based on stochastic optimal control [14, 25]. Finally, one of the key modeling ideas is realizing that users’ expressed opinions (be it in the form of thumbs up/down or text sentiment) can be viewed as noisy discrete samples of the users’ latent opinion localized in time. It would be very interesting to generalize this idea to any type of event data and derive sampling theorems and conditions under which an underlying general continuous signal of interest (be it user’s opinion or expertise) can be recovered from event data with provable guarantees. Acknowledgement: Abir De is partially supported by Google India under the Google India PhD Fellowship Award, and Isabel Valera is supported by a Humboldt post-doctoral fellowship. 8 References [1] O. Aalen, Ø. Borgan, and H. Gjessing. Survival and event history analysis: a process point of view. Springer Verlag, 2008. [2] A. H. Al-Mohy and N. J. Higham. Computing the action of the matrix exponential, with an application to exponential integrators. SIAM journal on scientific computing, 33(2):488–511, 2011. [3] R. Axelrod. The dissemination of culture a model with local convergence and global polarization. Journal of conflict resolution, 41(2):203–226, 1997. [4] E. G. Birgin, J. M. Mart´ınez, and M. Raydan. Nonmonotone spectral projected gradient methods on convex sets. SIAM Journal on Optimization, 10(4), 2000. [5] C. Blundell, J. Beck, and K. A. Heller. Modelling reciprocating relationships with hawkes processes. In Advances in Neural Information Processing Systems, pages 2600–2608, 2012. [6] P. Clifford and A. Sudbury. A model for spatial conflict. Biometrika, 60(3):581–588, 1973. [7] A. Das, S. Gollapudi, and K. Munagala. Modeling opinion dynamics in social networks. In WSDM, 2014. [8] A. De, S. Bhattacharya, P. Bhattacharya, N. Ganguly, and S. Chakrabarti. Learning a linear influence model from transient opinion dynamics. In CIKM, 2014. [9] M. H. DeGroot. Reaching a consensus. Journal of the American Statistical Association, 69(345), 1974. [10] M. Farajtabar, N. Du, M. Gomez-Rodriguez, I. Valera, L. Song, and H. Zha. Shaping social activity by incentivizing users. In NIPS, 2014. [11] M. Farajtabar, Y. Wang, M. Gomez-Rodriguez, S. Li, H. Zha, and L. Song. Coevolve: A joint point process model for information diffusion and network co-evolution. In NIPS, 2015. [12] M. Gomez-Rodriguez, D. Balduzzi, and B. Sch¨olkopf. Uncovering the Temporal Dynamics of Diffusion Networks. In ICML, 2011. [13] A. Hannak, E. Anderson, L. F. Barrett, S. Lehmann, A. Mislove, and M. Riedewald. Tweetin’in the rain: Exploring societal-scale effects of weather on mood. In ICWSM, 2012. [14] F. B. Hanson. Applied Stochastic Processes and Control for Jump-Diffusions. SIAM, 2007. [15] R. Hegselmann and U. Krause. Opinion dynamics and bounded confidence models, analysis, and simulation. Journal of Artificial Societies and Social Simulation, 5(3), 2002. [16] D. Hinrichsen, A. Ilchmann, and A. Pritchard. Robustness of stability of time-varying linear systems. Journal of Differential Equations, 82(2):219 – 250, 1989. [17] P. Holme and M. E. Newman. Nonequilibrium phase transition in the coevolution of networks and opinions. Physical Review E, 74(5):056108, 2006. [18] T. Karppi and K. Crawford. Social media, financial algorithms and the hack crash. TC&S, 2015. [19] J. Kim, J.-B. Yoo, H. Lim, H. Qiu, Z. Kozareva, and A. Galstyan. Sentiment prediction using collaborative filtering. In ICWSM, 2013. [20] J. Leskovec, D. Chakrabarti, J. M. Kleinberg, C. Faloutsos, and Z. Ghahramani. Kronecker graphs: An approach to modeling networks. JMLR, 2010. [21] B. Pang and L. Lee. Opinion mining and sentiment analysis. F&T in information retrieval, 2(1-2), 2008. [22] B. H. Raven. The bases of power: Origins and recent developments. Journal of social issues, 49(4), 1993. [23] Y. Saad and M. H. Schultz. Gmres: A generalized minimal residual algorithm for solving nonsymmetric linear systems. SIAM Journal on scientific and statistical computing, 7(3):856–869, 1986. [24] I. Valera and M. Gomez-Rodriguez. Modeling adoption and usage of competing products. In Proceedings of the 2015 IEEE International Conference on Data Mining, 2015. [25] Y. Wang, E. Theodorou, A. Verma, and L. Song. Steering opinion dynamics in information diffusion networks. arXiv preprint arXiv:1603.09021, 2016. [26] M. E. Yildiz, R. Pagliari, A. Ozdaglar, and A. Scaglione. Voting models in random networks. In Information Theory and Applications Workshop, pages 1–7, 2010. 9 | 2016 | 542 |
6,486 | Lifelong Learning with Weighted Majority Votes Anastasia Pentina IST Austria apentina@ist.ac.at Ruth Urner Max Planck Institute for Intelligent Systems rurner@tuebingen.mpg.de Abstract Better understanding of the potential benefits of information transfer and representation learning is an important step towards the goal of building intelligent systems that are able to persist in the world and learn over time. In this work, we consider a setting where the learner encounters a stream of tasks but is able to retain only limited information from each encountered task, such as a learned predictor. In contrast to most previous works analyzing this scenario, we do not make any distributional assumptions on the task generating process. Instead, we formulate a complexity measure that captures the diversity of the observed tasks. We provide a lifelong learning algorithm with error guarantees for every observed task (rather than on average). We show sample complexity reductions in comparison to solving every task in isolation in terms of our task complexity measure. Further, our algorithmic framework can naturally be viewed as learning a representation from encountered tasks with a neural network. 1 Introduction Machine learning has made significant progress in understanding both theoretical and practical aspects of solving a single prediction problem from a set of annotated examples. However, if we aim at building autonomous agents, capable to persist in the world, we need to establish methods for continuously learning various tasks over time [25, 26]. There is no hope to initially provide, for example, an autonomous robot with sufficiently rich prior knowledge to solve any problem that it may encounter during the course of its life. Therefore, an important goal of machine learning research is to replicate humans’ ability to learn from experience and to reuse knowledge from previously encountered tasks for solving new ones more efficiently. This is aimed at in lifelong learning or learning to learn, where a learning algorithm is assumed to encounter a stream of tasks and is aiming to exploit commonalities between them by transferring information from earlier tasks to later ones. The first theoretical formulation of this framework was proposed by Baxter [4]. In that model, tasks are generated by a probability distribution and the goal, given a sample of tasks from this distribution, is to perform well in expectation over tasks. Under certain assumptions, such as a shared good hypothesis set, this model allows for sample complexity savings [4]. However, good performance in expectation is often too weak a requirement. To stay with the robot example, failure on a single task may cause severe malfunction – and the end of the robot’s life. Moreover, the theoretical analysis of this model relies on the assumption that the learner maintains access to training data for all previously observed tasks, which allows to formulate a joint optimization problem. However, it is unlikely that an autonomous robot is able to keep all this data. Thus, we instead focus on a streaming setting for lifelong learning, where the learner can only retain learned models from previously encountered tasks. These models have a much more compact description than the joint training data. Specifically, we are interested in analysis and performance guarantees in the scenario that 1) tasks arrive one at a time without distributional or i.i.d. assumptions, 2) the learner can only keep the learned hypotheses from previously observed tasks, 3) error bounds are required for every single task, rather than on average. 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. The first analysis of this challenging setting was recently provided by Balcan et al. [3]. That work demonstrates sample complexity improvements for learning linear halfspaces (and some boolean function classes) in the lifelong learning setting in comparison to solving each task in isolation under the assumption that the tasks share a common low dimensional representation. However, the analysis relies on the marginal distributions of all tasks being isotropic log-concave. It was stated as an open challenge in that work whether similar guarantees (error bounds for every task, while only keeping limited information from earlier tasks) were possible under less restrictive distributional assumptions. In this work, we (partially) answer this question in the positive. We do so by proposing to learn with weighted majority votes rather than linear combinations over linear predictors. We show that the shift from linear combinations to majority votes introduces stability to the learned ensemble that allows exploiting it for later tasks. Additionally, we show that this stability is achieved for any ground hypothesis class. We formulate a relatedness assumption on the sequence of tasks (similar to one used in [3]) that captures how suitable to lifelong learning a sequence of tasks is. With this, we prove that sample complexity savings through lifelong learning are obtained for arbitrary marginal distributions (provided that these marginal distributions are related in terms of their discrepancy [5, 17]). This is a significant generalization towards more practically relevant scenarios. Summary of our work We employ a natural algorithmic paradigm, similar to the one in [3]. The algorithm maintains a set of base hypotheses from some fixed ground hypothesis class H. These base hypotheses are predictors learned on previous tasks. For each new task, the algorithm first attempts to achieve good prediction performance with a weighted majority vote over the current base hypotheses, and uses this predictor for the task if successful. Otherwise (if no majority vote classifier achieves high accuracy), the algorithm resorts to learning a classifier from the ground class for this task. This classifier is then added to the set of base hypotheses, to be used for subsequent tasks. We describe this algorithm Section 4.1. If the ground class is the class of linear predictors, this algorithm is actually learning a neural network. Each base classifier becomes a node in a hidden middle layer, which represents a learned feature representation of the neural net. A new task is then either solved by employing the representation learned from previous tasks (the current middle layer), and just learning task specific weights for the last layer, or, in case this is not possible, it extends the current representation. See also Section 4.2. This paradigm yields sample complexity savings, if the tasks encountered are related in the sense that for many tasks, good classification accuracy can be achieved with a weighted majority vote over previously learned models. We formally capture this property as an effective dimension of the sequence of tasks. We prove in Section 4.3 that if this effective dimension is bounded by k, then the total sample complexity for learning n tasks with this paradigm is upper bounded by ˜O (nk + VC(H)k2)/ϵ , a reduction from ˜O (nVC(H)/ϵ), the sample complexity of learning n tasks individually without retaining information from previous tasks. The main technical difficulty is to control the propagation of errors. Since every task is represented by a finite training set, the learner has access only to approximations of the true labeling functions, which may degrade the quality of this collection of functions as a “basis” for new tasks. Balcan et al. [3] control this error propagation using elegant geometric arguments for linear predictors under isotropic log-concave distributions. We show that moving from linear combinations to majority votes yields the required stability for the quality of the representation under arbitrary distributions. Finally, while we first present our algorithm and results for known upper bounds of k base tasks and n tasks in total, we also provide a variation of the algorithm that does not need to know the number of tasks and the complexity parameter of the task sequence. We show that similar sample complexity improvements are achievable in this setting in Section 5. 2 Related Work Lifelong learning. While there are many ways in which prediction tasks may be related [20], most of the existing approaches to transfer or lifelong learning are exploiting possible similarities between the optimal predictors for the considered tasks. In particular, one widely used relatedness assumption is that these predictors can be described as linear or sparse combinations of some common metafeatures and the corresponding methods aim at learning this representations [10, 2, 15, 3]. Though this idea was originally used in the multi-task setting, it was later extended to lifelong learning by 2 Eaton et al. [9], who proposed a method for sequentially updating the underlying representation as new tasks arrive. These settings were theoretically analyzed in a series of works [18, 19, 23, 21] that have demonstrated that information transfer can lead to provable sample complexity reductions compared to solving each task independently. However, all these results rely on Baxter’s model of lifelong learning and therefore assume access to the training data for all (observed) tasks and provide guarantees only on average performance over all tasks. An exception is [6], where the authors provide error guarantees for every task in the multi-task scenario. However, these guarantees are due to the relatedness assumption used which implies that all tasks have the same expected error. The task relatedness assumption that we employ is related to the one used in [1] for multi-task learning with expert advice. There the authors consider a setting where there exists a small subset of experts that perform well on all tasks. Similarly, we assume that there is a small subset of base tasks, such that the remaining ones can be solved well using majority votes over the corresponding base hypotheses. Majority votes. Weighted majority votes are a theoretically well understood and widely used in practice type of ensemble predictor. In particular, they are employed in boosting [11]. They are also often considered in works that utilize PAC-Bayesian techniques [22, 12]. Majority votes are also used in the concept drift setting [14]. The corresponding method, conceptually similar to the one proposed here, dynamically updates a set of experts and uses their weighted majority votes for making predictions. 3 Formal Setting 3.1 General notation and background We let X ⊆Rd denote a domain set and let Y denote a label set. A hypothesis is a function h : X →Y, and a hypothesis class H is a set of hypotheses. We model learning tasks as pairs ⟨D, h∗⟩of a distribution D over X and a labeling function h∗: X →Y. The quality of a hypothesis is measured by a loss function ℓ: Y × Y →R+. We deal with binary classification tasks, that is, Y = {−1, 1}, under the 0/1-loss function, that is, ℓ(y, y′) = Jy ̸= y′K (we let J·K denote the indicator function). The risk of a hypothesis h with respect to task ⟨D, h∗⟩is defined as its expected loss: LD,h∗(h) := Ex∼D[ℓ(h(x), h∗(x))]. Given a sample S = {(x1, y1), (x2, y2), . . . , (xn, yn)}, the empirical risk of h with respect to S is LS(h) := 1 n n X i=1 ℓ(h(xi), yi). For binary classification, the sample complexity of learning a hypothesis class is characterized (that is, upper and lower bounded), by the VC-dimension of the class [27]. We will employ the following generalization bounds for classes of finite VC-dimension: Theorem 1 (Corollaries 5.2 and 5.3 in [7]). Let H be a class of binary functions with a finite VC-dimension. There exists a constant C, such that for any δ ∈(0, 1), for any task ⟨D, h∗⟩, with probability at least 1 −δ over a training set S of size n, sampled i.i.d. from ⟨D, h∗⟩: LD,h∗(ˆh) ≤LS(ˆh) + q LS(ˆh) · ∆+ ∆, (1) LS(ˆh) ≤LD,h∗(ˆh) + q LD,h∗(ˆh) · ∆+ ∆, (2) LD,h∗(ˆh) ≤inf h∈H LD(h) + q inf h∈H LD(h) · ∆+ ∆, (3) where ˆh ∈arg minh∈H LS(h) is an empirical risk minimizer and ∆= C VC(H) log(n) + log(1/δ) n . (4) In the realizable case (h∗∈H), the above bounds imply that the sample complexity is upper bounded by ˜O VC(H)+log(1/δ) ϵ . 3 Weighted majority votes Given a hypothesis class H, we define the class of k-majority votes as MV(H, k) = ( g : X →Y | ∃h1, . . . , hk ∈H, ∃w1, . . . , wk ∈R : g(x) = sign k X i=1 wihi(x) !) . We will omit k in the above notation if clear from the context. The VC-dimension of MV(H, k) is upper bounded as VC(MV(H, k)) ≤k(VC(H) + 1)(3 log(VC(H) + 1) + 2) (5) (see Theorem 10.3 in [24]). This implies in particular, that the VC-dimension of majority votes over a fixed set of k functions is upper bounded by ˜O(k log(k)). 3.2 Lifelong learning In the lifelong learning setting the learner encounters a stream of prediction problems ⟨D1, h∗ 1⟩, . . . , ⟨Dn, h∗ n⟩, one at a time. In this work we focus on the realizable case, i.e. h∗ i ∈H for every i and some fixed H. In contrast to most works on lifelong learning, we assume that the only information the learner is able to store about the already observed tasks is the obtained predictors, i.e. it does not have access to the training data of already solved tasks. The need to keep little information from previous tasks has also been argued for in the context of domain adaptation [16]. Possible benefits of information transfer depend on how related or, in other words, how diverse the observed tasks are. Moreover, since we do not make any assumptions on the task generation process (in contrast to Baxter’s i.i.d. model [4]), we will formulate our relatedness assumption in terms of a sequence of tasks. Intuitively, one would expect that the information transfer is beneficial if only a few times throughout the course of learning information obtained from the already solved tasks will not be sufficient to solve the current one. In order to formalize this intuition, we use the following (pseudo-)metric over the hypothesis class with respect to a marginal distribution D: dD(h, h′) = E x∼DJh(x) ̸= h′(x)K. (6) Further, we can define a distance of a hypothesis to a hypothesis space as dD(h, H′) = min h′∈H′ dD(h, h′) (7) and the distance between two sets of hypotheses as dD(H, H′) = max h∈H dD(h, H′) = max h∈H min h′∈H′ dD(h, h′). (8) Note that the latter is not necessarily a metric over subsets of the hypothesis space. However, it does satisfy the triangle inequality (see Section 1 in the supplementary material). Now we can formulate the diversity measure for a sequence of learning tasks that we will employ. Note that the concepts below are closely related to the ones used in [3] for the case of linear predictors and linear combinations over these. Definition 1. A sequence of learning tasks ⟨D1, h∗ 1⟩, . . . , ⟨Dn, h∗ n⟩is γ-separated, if for every i dDi(h∗ i , MV(h∗ 1, . . . , h∗ i−1)) > γ. Definition 2. A sequence of learning tasks ⟨D1, h∗ 1⟩, . . . , ⟨Dn, h∗ n⟩has γ-effective dimension k, if the largest γ-separated subsequence of these tasks has length k. Formally, we will assume that the γ-effective dimension k of the observed sequence of tasks is relatively small for a sufficiently small γ. Note that this assumption can also be seen as a relaxation of the one used in [8]. There the authors assumed that there exists a set of k hypothesis such that every task can be well solved by one of them. This would correspond to substituting the sets of weighted majority votes MV(h∗ 1, . . . , h∗ i−1) by just the collections {h∗ 1, . . . , h∗ i−1} in the above definitions. Moreover, we will assume that the marginal distributions have small discrepancy with respect to the hypothesis set H: discH(Di, Dj) = max h,h′∈H |dDi(h, h′) −dDj(h, h′)|. (9) This is a measure of task relatedness that has been introduced in [13] and shown to be beneficial in the context of domain adaptation [5, 17]. Note, however, that we do not make any assumptions on the marginal distributions D1, . . . , Dn themselves. 4 4 Algorithm and complexity guarantees 4.1 The algorithm We employ a natural algorithmic paradigm, which is similar to the one in [3]. Algorithm 1 below provides pseudocode for our procedure. The algorithm takes as parameters a class H, which we call the ground class, accuracy and confidence parameters ϵ and δ, as well as a task horizon n (the number of tasks to be solved) and a parameter k (a guessed upper bound on the number of tasks that will not be solvable as majority votes over earlier tasks). In Section 5 we present a version that does not need to know n and k in advance. Algorithm 1 Lifelong learning of majority votes 1: Input parameters H, n, k, ϵ, δ 2: set δ′ = δ/(2n), ϵ′ = ϵ/(8k) 3: draw a training set S1 from ⟨D1, h∗ 1⟩, such that ∆1 := ∆(VC(H), δ′, |S1|) ≤ϵ′ 4: g1 = arg minh∈H LS1(h) 5: set ˜k = 1, i1 = 1, ˜h1 = g1 6: for i = 2 to n do 7: draw a training set Si from ⟨Di, h∗ i ⟩, such that ∆i := ∆(VC(MV(˜h1, . . . , ˜h˜k)), δ′, |Si|) ≤ ϵ 40 8: gi = arg minh∈MV(˜h1,...,˜h˜k) LSi(h) 9: if LSi(gi) + p LSi(gi) · ∆i + ∆i > ϵ then 10: draw a training set Si from ⟨Di, h∗ i ⟩, such that ∆i := ∆(VC(H), δ′, |Si|) ≤ϵ′ 11: gi = arg minh∈H LSi(h) 12: set ˜k = ˜k + 1, ˜h˜k = gi, i˜k = i 13: end if 14: end for 15: return g1, . . . , gn During the course of its “life”, the algorithm maintains a set of base hypotheses (˜h1, . . . , ˜h˜k) from the ground class, which are predictors learned on previous tasks. In order to solve the first task, it uses the hypothesis set H and a large enough training set S1 to ensure the error guarantee ϵ′ ≤ϵ/8k with probability at least 1 −δ′, where δ′ = δ/2n. The learned hypothesis ˜h1 ∈H is the first member of the set of base hypotheses. For each new task i, the algorithm first attempts to achieve good prediction performance (up to error ϵ) with a weighted majority vote over the base hypotheses, i.e. it attempts to learn this task using the class MV(˜h1, . . . , ˜h˜k), and uses the obtained predictor for the task if successful. Otherwise (if no majority vote classifier achieves high accuracy), the algorithm resorts to learning a classifier from the base class for this task, which is then added to the set of base hypotheses, to be used for subsequent tasks. The error guarantees are ensured with Theorem 1 by choosing the training sets Si large enough so that ∆i := ∆(VC(Hi), δ′, |Si|) := C VC(Hi) log(|Si|) + log(1/δ′) |Si| ≤cϵ, where Hi is either the ground class H or the set of weighted majority votes over the current set of base hypotheses MV(˜h1, . . . , ˜h˜k), and constant c is set according to case, see pseudocode. While this approach is very natural, the challenge is to analyze it and to specify the parameters. In particular, we need to ensure that the algorithm will not have to search over (potentially large) hypothesis set H too often and, consequently, will lead to provable sample complexity reductions over solving each task independently. The following theorem summarizes the performance guarantees for Algorithm 1 (the proof is in Section 4.3). Theorem 2. Consider running Algorithm 1 on a sequence of tasks with γ-effective dimension at most k and discH(Di, Dj) ≤ξ for all i, j. Then, if γ ≤ϵ/4 and kξ < ϵ/8, with probability at least 1 −δ: • The error of every task is bounded: LDi,h∗ i (gi) ≤ϵ for every i = 1, . . . , n. • The total number of labeled examples used is ˜O nk+VC(H)k2 ϵ . 5 Discussion Note that if we assume that all tasks are realizable by H, independently learning them up to error ϵ would have sample complexity ˜O VC(H)n ϵ . The sample complexity of learning n tasks in the lifelong learning regime with our paradigm in contrast is ˜O nk+VC(H)k2 ϵ . This is a significant reduction if the effective dimension of the task sequence k is small in comparison to the total number n of tasks, as well as the complexity measure VC(H) of the ground class. That is, if most tasks are learnable as combination of previously stored base predictors, much less data is required overall. Note that for all those tasks that are solved as majority votes, our algorithm and analysis actually require realizability only by the class of k-majority votes over H and not by the ground class H. Learning the n tasks independently under this assumption, has sample complexity ˜O VC(H)k ϵ + (n−k)VC(H)k ϵ . In contrast, the lifelong learning method gradually identifies the relevant set of base predictors and thereby reduces the number of required examples. 4.2 Neural networks If the ground class is the class of linear predictors, our algorithm is actually learning a neural network (with sign() as the activation function). Each base classifier becomes a new node in a hidden middle layer. Thus, the maintained set of base classifiers can be viewed as feature representation in the neural net, which was learned based on the encountered tasks. A new task is then either solved by employing the representation learned from previous tasks (the current middle layer), and just learning task specific weights for the last layer; or, in case this is not possible, a fresh linear classifier is learned, and added as a node to the middle layer. Thus, in this case, the feature representation is extended. 4.3 Analysis We start with presenting the following two lemmas that show how to control the error propagation of the learned representations (sets of base classifiers). We then proceed to the proof of Theorem 2. Lemma 1. Let V =MV(h1, . . . , hk, g) and ˜V =MV(h1, . . . , hk, ˜g). Then, for any distribution D: dD(V, ˜V ) ≤dD(g, ˜g). (10) Proof. By the definition of dD(V, ˜V ) there exists u ∈V such that: dD(V, ˜V ) = dD(u, ˜V ). (11) We can represent u as u = sign(Pk i=1 αihi + αg) and let u1 = Pk i=1 αihi. Note that while all hi-s, g and ˜g are assumed to take values in {−1, 1}, u1 can take values in R. Then: dD(u, ˜V ) = min ˜h∈˜V dD(u, ˜h) ≤ min ˜h∈MV(u1,˜g) dD(u, ˜h) ≤ max h∈MV(u1,g) min ˜h∈MV(u1,˜g) dD(h, ˜h) = dD(MV(u1, g), MV(u1, ˜g)). Now we show that for any α1u1 + α2g ∈MV(u1, g) there exists a close hypothesis in MV(u1, ˜g). In particular, this hypothesis is α1u1 + α2˜g: dD(α1u1 + α2g, α1u1 + α2˜g) = E x∼DJsign(α1u1(x) + α2g(x)) ̸= sign(α1u1(x) + α2˜g(x))K = E x∼DJα2 1u2 1(x) + α1α2u1(x)g(x) + α1α2u1(x)˜g(x) + α2 2g(x)˜g(x) < 0K. Note that for every x on which g and ˜g agree, i.e. g(x)˜g(x) = 1, we obtain: α2 1u2 1(x) + α1α2u1(x)g(x) + α1α2u1(x)˜g(x) + α2 2g(x)˜g(x) = (α1u1(x) + α2g(x))2 ≥0. Therefore: dD(α1u1 + α2g, α1u1 + α2˜g) ≤ E x∼DJg(x) ̸= ˜g(x)K = dD(g, ˜g). (12) 6 Lemma 2. Let Vk = MV(h1, . . . , hk) and ˜Vk = MV(˜h1, . . . , ˜hk). For any distribution D, if dD(hi, ˜hi) ≤ϵi for every i = 1, . . . , k, then dD(Vk, ˜Vk) ≤Pk i=1 ϵi. For the proof see Section 2 in the supplementary material. Proof of Theorem 2. 1. First, note that for every task Algorithm 1 solves at most 2 estimation problems with a probability of failure δ′ for each of them. Therefore, with a union bound argument, the probability of any of these estimations being wrong is at most 2 · n · δ′ = δ. Thus, from now we assume that all the estimations were correct, that is, the high probability events of Theorem 1 hold. 2. To see that the error of every encountered task is bounded by ϵ, note that there are two cases. For tasks i that are solved by a majority vote over previous tasks, we have LSi(gi) + p LSi(gi) · ∆i + ∆i ≤ϵ. In this case, Equation (1) in Theorem 1 implies LDi,h∗ i (gi) ≤ϵ. For tasks i that are not solved as a majority vote over previous tasks, we have ∆i = ∆(VC(MV(˜h1, . . . , ˜h˜k)), δ′, m) ≤ϵ/8k. Since task i is realizable by the base class H, we have infh∈H LDi,h∗ i (h) = 0, and thus Equation (3) of Theorem 1 implies LDi,h∗ i (gi) ≤ϵ/8k < ϵ. 3. To upper bound the sample complexity we first prove that the number ˜k of tasks, which are not learned as majority votes over previous tasks, is at most k. For that we use induction showing that for every ˆk ≤˜k, when we create a new ˜hˆk from the iˆk-th task, we have that dDiˆk (h∗ iˆk, MV(h∗ i1, . . . , h∗ iˆk−1)) > γ. (13) This implies ˜k ≤k by invoking that the γ-effective dimension of the sequence of encountered tasks is at most k. To proceed to the induction, note that for ˆk = 1, the claim follows immediately. Consider ˆk > 1. If we create a new ˜hˆk, it means that the condition in line 9 is true, which is: LSiˆk (giˆk) + q LSiˆk (giˆk) · ∆i + ∆i > ϵ. (14) Therefore LSiˆk (giˆk) > 0.83ϵ. Consequently, due to (2), LDiˆk ,h∗ iˆk (giˆk) > 0.67ϵ. Finally, by (3), infg LDiˆk ,h∗ iˆk (g) > 0.5ϵ. Therefore there is no majority vote predictor based on ˜h1, . . . , ˜hˆk−1 that leads to error less than ϵ/2 on the problem iˆk. In other words: dDiˆk (h∗ iˆk, MV(˜h1, . . . , ˜hˆk−1)) > ϵ/2. (15) Now, by way of contradiction, suppose that dDiˆk (h∗ iˆk, MV(h∗ i1, . . . , h∗ iˆk−1)) ≤γ. By construction for every j = 1, . . . , ˆk −1 dDij (h∗ ij, ˜hj) ≤ϵ′ ≤ϵ/8k. By the definition of discrepancy and the assumption on the marginal distributions it follows that for all j: dDiˆk (h∗ ij, ˜hj) ≤dDij (h∗ ij, ˜hj) + discH(Dij, Diˆk) ≤ϵ′ + ξ. (16) Therefore by Lemma 2: dDiˆk (MV(h∗ i1, . . . , h∗ iˆk−1), MV(˜h1, . . . , ˜hˆk)) ≤k(ϵ′ + ξ). (17) Consequently, by using the triangle inequality: dDiˆk (h∗ iˆk, MV(˜h1, . . . , ˜hˆk−1)) ≤γ + k(ϵ′ + ξ) ≤ϵ/4 + ϵ/8 + ϵ/8 = ϵ/2, (18) which is in contradiction with (15). 4. The total sample complexity of Algorithm 1 consists of two parts. First, for every task Algorithm 1 checks, whether it can be solved by a majority vote over the base, at most ˜k predictors. For that it employs Theorem 1 and therefore needs the following number of samples: ˜O n˜k log ˜k log(˜k log ˜k) log(2n/δ) ϵ ! = ˜O nk ϵ . (19) Second, there are at most ˜k tasks that satisfy the condition in line 9 and are learned using the hypothesis set H with estimation error ϵ′ = ϵ/(8k). Therefore the corresponding sample complexity is: O ˜kVC(H) log(2n/δ) ϵ/(8k) = ˜O VC(H)k2 ϵ . 7 5 Lifelong learning with unknown horizon In this section we present a modification of Algorithm 1 for the case when the total number of tasks n and the complexity of the task sequence k are not known in advance. The main difference between Algorithm 2 and Algorithm 1 is that with unknown n and k the learner has to adopt the parameters δ′ and ϵ′ on the fly. We show that this can be done by the doubling trick that is often used in online learning. Theorem 3 summarizes the resulting guarantees (the proof can be found in the supplementary material, Section 3). Algorithm 2 Lifelong learning of majority votes with unkown horizon 1: Input parameters H, ϵ, δ 2: set δ1 = δ/2, ϵ′ 1 = ϵ/16 3: draw a training set S1 from ⟨D1, h∗ 1⟩of size m, such that ∆(VC(H), δ1, m) ≤ϵ′ 1 (see (4)) 4: g1 = arg minh∈H LS1(h) 5: set ˜k = 1, i1 = 1, ˜h1 = g1 6: for i = 2 to n do 7: set l = ⌊log i⌋, m = ⌊log ˜k + 1⌋ 8: set δi = δ 22l+2 , ϵ′ i = ϵ 22m+4 9: draw a training set Si from ⟨Di, h∗ i ⟩of size m, such that ∆(VC(MV(˜h1, . . . , ˜h˜k)), δi, m) ≤ ϵ/40 (see (4)) 10: gi = arg minh∈MV(˜h1,...,˜h˜k) LSi(h) 11: if LSi(gi) + p LSi(gi) · ∆+ ∆> ϵ then 12: draw a training set Si from ⟨Di, h∗ i ⟩of size m, such that ∆(VC(H), δi, m) ≤ϵ′ i (see (4)) 13: gi = arg minh∈H LSi(h) 14: set ˜k = ˜k + 1, ˜h˜k = gi, i˜k = i 15: end if 16: end for 17: return g1, . . . , gn Theorem 3. Consider running Algorithm 2 on a sequence of tasks with γ-effective dimension at most k and discH(Di, Dj) ≤ξ for all i, j. Then, if γ ≤ϵ/4 and kξ < ϵ/8, with probability at least 1 −δ: • The error of every task is bounded: LDi,h∗ i (gi) ≤ϵ for every i = 1, . . . , n. • The total number of labeled examples used is ˜O nk+VC(H)k3 ϵ . 6 Conclusion In this work, we have shown sample complexity improvements with lifelong learning in the challenging, yet as argued important setting, where tasks arrive in a stream (without assumptions on the tasks generating process), where the learner is only allowed to maintain limited amounts of information from previously encountered tasks, and where high performance is required for every single task, rather than on average. While such improvements have been established in very specific settings [3], our work shows they are possible in much more general and realistic scenarios. We hope that this will open the door for more work in this area of machine lifelong learning and lead to better understanding of how and when learning machines can benefit from past experience. An intriguing direction is to investigate whether there exists a more general characterization of ensemble methods and/or data distributions that would lead to benefits with lifelong learning. Another one is to better understand lifelong learning with neural networks, analyzing cases of more complex network structures and activation functions, an area where current machine learning practice yields exciting successes, but little is understood. Acknowledgments This work was in parts funded by the European Research Council under the European Union’s Seventh Framework Programme (FP7/2007-2013)/ERC grant agreement no 308036. 8 References [1] J. Abernethy, P. Bartlett, and A. Rakhlin. Multitask learning with expert advice. In Workshop on Computational Learning Theory (COLT), 2007. [2] A. Argyriou, T. Evgeniou, and M. Pontil. Convex multi-task feature learning. Machine Learning (ML), 2008. [3] M.-F. Balcan, A. Blum, and S. Vempala. Efficient representations for lifelong learning and autoencoding. In Workshop on Computational Learning Theory (COLT), 2015. [4] J. Baxter. A model of inductive bias learning. Journal of Artificial Intelligence Research (JAIR), 12, 2000. [5] S. Ben-David, J. Blitzer, K. Crammer, A. Kulesza, F. Pereira, and J. W. Vaughan. A theory of learning from different domains. Machine Learning (ML), 2010. [6] S. Ben-David and R. Schuller. Exploiting task relatedness for multiple task learning. 2003. [7] S. Boucheron, O. Bousquet, and G. Lugosi. Theory of classification: a survey of some recent advances. ESAIM: Probability and Statistics, 9:323–375, 11 2005. [8] K. Crammer and Y. Mansour. Learning multiple tasks using shared hypotheses. In Conference on Neural Information Processing Systems (NIPS), 2012. [9] E. Eaton and P. L. Ruvolo. ELLA: An efficient lifelong learning algorithm. In International Conference on Machine Learning (ICML), 2013. [10] A. Evgeniou and M. Pontil. Multi-task feature learning. In Conference on Neural Information Processing Systems (NIPS), 2007. [11] Y. Freund and R. E. Schapire. Experiments with a new boosting algorithm. In International Conference on Machine Learning (ICML), 1996. [12] P. Germain, A. Habrard, F. Laviolette, and E. Morvant. A New PAC-Bayesian Perspective on Domain Adaptation. In International Conference on Machine Learning (ICML), 2016. [13] D. Kifer, S. Ben-David, and J. Gehrke. Detecting change in data streams. In International Conference on Very Large Data Bases (VLDB), 2004. [14] J. Z. Kolter and M. A. Maloof. Dynamic weighted majority: An ensemble method for drifting concepts. Journal of Machine Learning Research (JMLR), 8:2755–2790, Dec. 2007. [15] A. Kumar and H. Daumé III. Learning task grouping and overlap in multi-task learning. In International Conference on Machine Learning (ICML), 2012. [16] I. Kuzborskij and F. Orabona. Stability and hypothesis transfer learning. In International Conference on Machine Learning (ICML), 2013. [17] Y. Mansour, M. Mohri, and A. Rostamizadeh. Domain adaptation: Learning bounds and algorithms. In Workshop on Computational Learning Theory (COLT), 2009. [18] A. Maurer. Transfer bounds for linear feature learning. Machine Learning, 75(3):327–350, 2009. [19] A. Maurer, M. Pontil, and B. Romera-Paredes. Sparse coding for multitask and transfer learning. In International Conference on Machine Learning (ICML), 2013. [20] S. J. Pan and Q. Yang. A survey on transfer learning. IEEE Transactions on Knowledge and Data Engineering, 22(10):1345–1359, Oct. 2010. [21] A. Pentina and S. Ben-David. Multi-task and lifelong learning of kernels. In Algorithmic Learning Theory (ALT), 2015. [22] A. Pentina and C. H. Lampert. A PAC-Bayesian bound for lifelong learning. In International Conference on Machine Learning (ICML), 2014. [23] M. Pontil and A. Maurer. Excess risk bounds for multitask learning with trace norm regularization. In Workshop on Computational Learning Theory (COLT), 2013. [24] S. Shalev-Shwartz and S. Ben-David. Understanding Machine Learning: From Theory to Algorithms. Cambridge University Press, New York, NY, USA, 2014. [25] S. Thrun and T. M. Mitchell. Lifelong robot learning. Robotics and Autonomous Systems, 15(1–2):25 – 46, 1995. The Biology and Technology of Intelligent Autonomous Agents. [26] S. Thrun and L. Pratt. Learning to learn. Kluwer Academic Publishers, 1998. [27] V. N. Vapnik and A. J. Chervonenkis. On the uniform convergence of relative frequencies of events to their probabilities. Theory of Probability & Its Applications, 16(2):264–280, 1971. 9 | 2016 | 543 |
6,487 | Depth from a Single Image by Harmonizing Overcomplete Local Network Predictions Ayan Chakrabarti TTI-Chicago Chicago, IL ayanc@ttic.edu Jingyu Shao Dept. of Statistics, UCLA∗ Los Angeles, CA shaojy15@ucla.edu Gregory Shakhnarovich TTI-Chicago Chicago, IL gregory@ttic.edu Abstract A single color image can contain many cues informative towards different aspects of local geometric structure. We approach the problem of monocular depth estimation by using a neural network to produce a mid-level representation that summarizes these cues. This network is trained to characterize local scene geometry by predicting, at every image location, depth derivatives of different orders, orientations and scales. However, instead of a single estimate for each derivative, the network outputs probability distributions that allow it to express confidence about some coefficients, and ambiguity about others. Scene depth is then estimated by harmonizing this overcomplete set of network predictions, using a globalization procedure that finds a single consistent depth map that best matches all the local derivative distributions. We demonstrate the efficacy of this approach through evaluation on the NYU v2 depth data set. 1 Introduction In this paper, we consider the task of monocular depth estimation—i.e., recovering scene depth from a single color image. Knowledge of a scene’s three-dimensional (3D) geometry can be useful in reasoning about its composition, and therefore measurements from depth sensors are often used to augment image data for inference in many vision, robotics, and graphics tasks. However, the human visual system can clearly form at least an approximate estimate of depth in the absence of stereo and parallax cues—e.g., from two-dimensional photographs—and it is desirable to replicate this ability computationally. Depth information inferred from monocular images can serve as a useful proxy when explicit depth measurements are unavailable, and be used to refine these measurements where they are noisy or ambiguous. The 3D co-ordinates of a surface imaged by a perspective camera are physically ambiguous along a ray passing through the camera center. However, a natural image often contains multiple cues that can indicate aspects of the scene’s underlying geometry. For example, the projected scale of a familiar object of known size indicates how far it is; foreshortening of regular textures provide information about surface orientation; gradients due to shading indicate both orientation and curvature; strong edges and corners can correspond to convex or concave depth boundaries; and occluding contours or the relative position of key landmarks can be used to deduce the coarse geometry of an object or the whole scene. While a given image may be rich in such geometric cues, it is important to note that these cues are present in different image regions, and each indicates a different aspect of 3D structure. We propose a neural network-based approach to monocular depth estimation that explicitly leverages this intuition. Prior neural methods have largely sought to directly regress to depth [1, 2]—with some additionally making predictions about smoothness across adjacent regions [4], or predicting relative ∗Part of this work was done while JS was a visiting student at TTI-Chicago. 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. Figure 1: To recover depth from a single image, we first use a neural network trained to characterize local depth structure. This network produces distributions for values of various depth derivatives—of different orders, at multiple scales and orientations—at every pixel, using global scene features and those from a centered local image patch (top left). A distributional output allows the network to determine different derivatives at different locations with different degrees of certainty (right). An efficient globalization algorithm is then used to produce a single consistent depth map estimate. depth ordering between pairs of image points [7]. In contrast, we train a neural network with a rich distributional output space. Our network characterizes various aspects of the local geometric structure by predicting values of a number of derivatives of the depth map—at various scales, orientations, and of different orders (including the 0th derivative, i.e., the depth itself)—at every image location. However, as mentioned above, we expect different image regions to contain cues informative towards different aspects of surface depth. Therefore, instead of over-committing to a single value, our network outputs parameterized distributions for each derivative, allowing it to effectively characterize the ambiguity in its predictions. The full output of our network is then this set of multiple distributions at each location, characterizing coefficients in effectively an overcomplete representation of the depth map. To recover the depth map itself, we employ an efficient globalization procedure to find the single consistent depth map that best agrees with this set of local distributions. We evaluate our approach on the NYUv2 depth data set [11], and find that it achieves state-of-the-art performance. Beyond the benefits to the monocular depth estimation task itself, the success of our approach suggests that our network can serve as a useful way to incorporate monocular cues in more general depth estimation settings—e.g., when sparse or noisy depth measurements are available. Since the output of our network is distributional, it can be easily combined with partial depth cues from other sources within a common globalization framework. Moreover, we expect our general approach—of learning to predict distributions in an overcomplete respresentation followed by globalization—to be useful broadly in tasks that involve recovering other kinds of scene value maps that have rich structure, such as optical or scene flow, surface reflectances, illumination environments, etc. 2 Related Work Interest in monocular depth estimation dates back to the early days of computer vision, with methods that reasoned about geometry from cues such as diffuse shading [12], or contours [13, 14]. However, the last decade has seen accelerated progress on this task [1–10], largely owing to the availability of cheap consumer depth sensors, and consequently, large amounts of depth data for training learningbased methods. Most recent methods are based on training neural networks to map RGB images to geometry [1–7]. Eigen et al. [1, 2] set up their network to regress directly to per-pixel depth values, although they provide deeper supervision to their network by requiring an intermediate layer 2 to explicitly output a coarse depth map. Other methods [3, 4] use conditional random fields (CRFs) to smooth their neural estimates. Moreover, the network in [4] also learns to predict one aspect of depth structure, in the form of the CRF’s pairwise potentials. Some methods are trained to exploit other individual aspects of geometric structure. Wang et al. [6] train a neural network to output surface normals instead of depth (Eigen et al. [1] do so as well, for a network separately trained for this task). In a novel approach, Zoran et al. [7] were able to train a network to predict the relative depth ordering between pairs of points in the image—whether one surface is behind, in front of, or at the same depth as the other. However, their globalization scheme to combine these outputs was able to achieve limited accuracy at estimating actual depth, due to the limited information carried by ordinal pair-wise predictions. In contrast, our network learns to reason about a more diverse set of structural relationships, by predicting a large number of coefficients at each location. Note that some prior methods [3, 5] also regress to coefficients in some basis instead of to depth values directly. However, their motivation for this is to reduce the complexity of the output space, and use basis sets that have much lower dimensionality than the depth map itself. Our approach is different—our predictions are distributions over coefficients in an overcomplete representation, motivated by the expectation that our network will be able to precisely characterize only a small subset of the total coefficients in our representation. Our overall approach is similar to, and indeed motivated by, the recent work of Chakrabarti et al. [15], who proposed estimating a scene map (they considered disparity estimation from stereo images) by first using local predictors to produce distributional outputs from many overlapping regions at multiple scales, followed by a globalization step to harmonize these outputs. However, in addition to the fact that we use a neural network to carry out local inference, our approach is different in that inference is not based on imposing a restrictive model (such as planarity) on our local outputs. Instead, we produce independent local distributions for various derivatives of the depth map. Consequently, our globalization method need not explicitly reason about which local predictions are “outliers” with respect to such a model. Moreover, since our coefficients can be related to the global depth map through convolutions, we are able to use Fourier-domain computations for efficient inference. 3 Proposed Approach We formulate our problem as that of estimating a scene map y(n) ∈R, which encodes point-wise scene depth, from a single RGB image x(n) ∈R3, where n ∈Z2 indexes location on the image plane. We represent this scene map y(n) in terms of a set of coefficients {wi(n)}K i=1 at each location n, corresponding to various spatial derivatives. Specifically, these coefficients are related to the scene map y(n) through convolution with a bank of derivative filters {ki}K i=1, i.e., wi(n) = (y ∗ki)(n). (1) For our task, we define {ki} to be a set of 2D derivative-of-Gaussian filters with standard deviations 2s pixels, for scales s = {1, 2, 3}. We use the zeroth order derivative (i.e., the Gaussian itself), first order derivatives along eight orientations, as well as second order derivatives—along each of the orientations, and orthogonal orientations (see Fig. 1 for examples). We also use the impulse filter which can be interpreted as the zeroth derivative at scale 0, with the corresponding coefficients wi(n) = y(n)—this gives us a total of K = 64 filters. We normalize the first and second order filters to be unit norm. The zeroth order filters coefficients typically have higher magnitudes, and in practice, we find it useful to normalize them as ∥ki∥2 = 1/4 to obtain a more balanced representation. To estimate the scene map y(n), we first use a convolutional neural network to output distributions for the coefficients p (wi(n)), for every filter i and location n. We choose a parametric form for these distributions p(·), with the network predicting the corresponding parameters for each coefficient. The network is trained to produce these distributions for each set of coefficients {wi(n)} by using as input a local region centered around n in the RGB image x. We then form a single consistent estimate of y(n) by solving a global optimization problem that maximizes the likelihood of the different coefficients of y(n) under the distributions provided by our network. We now describe the different components of our approach (which is summarized in Fig. 1)—the parametric form for our local coefficient distributions, the architecture of our neural network, and our globalization method. 3 Figure 2: We train a neural network to output distributions for K depth derivatives {wi(n)} at each location n, using a color image as input. The distributions are parameterized as Gaussian mixtures, and the network produces the M mixture weights for each coefficient. Our network includes a local path (green) with a cascade of convolution layers to extract features from a 97×97 patch around each location n; and a scene path (red) with pre-trained VGG-19 layers to compute a single scene feature vector. We learn a linear map (with x32 upsampling) from this scene vector to per-location features. The local and scene features are concatenated and used to generate the final distributions (blue). 3.1 Parameterizing Local Distributions Our neural network has to output a distribution, rather than a single estimate, for each coefficient wi(n). We choose Gaussian mixtures as a convenient parametric form for these distributions: pi,n (wi(n)) = M X j=1 ˆpj i(n) 1 √ 2πσi exp −|wi(n) −cj i|2 2σ2 i ! , (2) where M is the number of mixture components (64 in our implementation), σ2 i is a common variance for all components for derivative i, and {cj i} the individual component means. A distribution for a specific coefficient wi(n) can then characterized by our neural network by producing the mixture weights {ˆpj i(n)}, P j ˆpj i(n) = 1, for each wi(n) from the scene’s RGB image. Prior to training the network, we fix the means {cj i} and variances {σ2 i } based on a training set of ground truth depth maps. We use one-dimensional K-means clustering on sets of training coefficient values {wi} for each derivative i, and set the means cj i in (2) above to the cluster centers. We set σ2 i to the average in-cluster variance—however, since these coefficients have heavy-tailed distributions, we compute this average only over clusters with more than a minimum number of assignments. 3.2 Neural Network-based Local Predictions Our method uses a neural network to predict the mixture weights ˆpj i(n) of the parameterization in (2) from an input color image. We train our network to output K × M numbers at each pixel location n, which we interpret as a set of M-dimensional vectors corresponding to the weights {ˆpj i(n)}j, for each of the K distributions of the coefficients {wi(n)}i. This training is done with respect to a loss between the predicted ˆpj i(n), and the best fit of the parametric form in (2) to the ground truth derivative value wi(n). Specifically, we define qj i (n) in terms of the true wi(n) as: qj i (n) ∝exp −|wi(n) −cj i|2 2σ2 i ! , X j qj i (n) = 1, (3) and define the training loss L in terms of the KL-divergence between these vectors qj i (n) and the network predictions ˆpj i(n), weighting the loss for each derivative by its variance σ2 i : L = −1 NK X i,n σ2 i M X j=1 qj i (n) log ˆpj i(n) −log qj i (n) , (4) 4 where N is the total number of locations n. Our network has a fairly high-dimensional output space—corresponding to K × M numbers, with (M −1) × K degrees of freedom, at each location n. Its architecture, detailed in Fig. 2, uses a cascade of seven convolution layers (each with ReLU activations) to extract a 1024-dimensional local feature vector from each 97 × 97 local patch in the input image. To further add scene-level semantic context, we include a separate path that extracts a single 4096-dimensional feature vector from the entire image—using pre-trained layers (upto pool5) from the VGG-19 [16] network, followed downsampling with averaging by a factor of two, and a fully connected layer with a ReLU activation that is trained with dropout. This global vector is used to derive a 64-dimensional vector for each location n—using a learned layer that generates a feature map at a coarser resolution, that is then bi-linearly upsampled by a factor of 32 to yield an image-sized map. The concatenated local and scene-level features are passed through two more hidden layers (with ReLU activations). The final layer produces the K × M-vector of mixture weights ˆpj i(n), applying a separate softmax to each of the M-dimensional vector {pj i(n)}j. All layers in the network are learned end-to-end, with the VGG-19 layers finetuned with a reduced learning rate factor of 0.1 compared to the rest of the network. The local path of the network is applied in a “fully convolutional” way [17] during training and inference, allowing efficient reuse of computations between overlapping patches. 3.3 Global Scene Map Estimation Applying our neural network to a given input image produces a dense set of distributions pi,n(wi(n)) for all derivative coefficients at all locations. We combine these to form a single coherent estimate by finding the scene map y(n) whose coefficients {wi(n)} have high likelihoods under the corresponding distributions {pi,n(·)}. We do this by optimizing the following objective: y = arg max y X i,n σ2 i log pi,n ((ki ∗y)(n)) , (5) where, like in (4), the log-likelihoods for different derivatives are weighted by their variance σ2 i . The objective in (5) is a summation over a large (K times image-size) number of non-convex terms, each of which depends on scene values y(n) at multiple locations n in a local neighborhood— based on the support of filter ki. Despite the apparent complexity of this objective, we find that approximate inference using an alternating minimization algorithm, like in [15], works well in practice. Specifically, we create explicit auxiliary variables wi(n) for the coefficients, and solve the following modified optimization problem: y = arg min y min {wi(n)} − X i,n σ2 i log pi,n (wi(n)) + β 2 X i,n (wi(n) −(ki ∗y)(n))2 + 1 2R(y). (6) Note that the second term above forces coefficients of y(n) to be equal to the corresponding auxiliary variables wi(n), as β →∞. We iteratively compute (6), by alternating between minimizing the objective with respect to y(n) and to {wi(n)}, keeping the other fixed, while increasing the value of β across iterations. Note that there is also a third regularization term R(y) in (6), which we define as R(y) = X r X n ∥(∇r ∗y)(n)∥2, (7) using 3 × 3 Laplacian filters, at four orientations, for {∇r}. In practice, this term only affects the computation of y(n) in the initial iterations when the value of β is small, and in later iterations is dominated by the values of wi(n). However, we find that adding this regularization allows us to increase the value of β faster, and therefore converge in fewer iterations. Each step of our alternating minimization can be carried out efficiently. When y(n) fixed, the objective in (6) can be minimized with respect to each coefficient wi(n) independently as: wi(n) = arg min w −log pi,n(w) + β 2σ2 i (w −¯wi(n))2, (8) 5 where ¯wi(n) = (ki ∗y)(n) is the corresponding derivative of the current estimate of y(n). Since pi,n(·) is a mixture of Gaussians, the objective in (8) can also be interpreted as the (scaled) negative log-likelihood of a Gaussian-mixture, with “posterior” mixture means ¯wj i (n) and weights ¯pj i(n): ¯wj i (n) = ci j + β ¯wi(n) 1 + β , ¯pj i(n) ∝ˆpj i(n) exp − β β + 1 (cj i −¯wi(n))2 2σ2 i ! . (9) While there is no closed form solution to (8), we find that a reasonable approximation is to simply set wi(n) to the posterior mean value ¯wj i (n) for which weight ¯pj i(n) is the highest. The second step at each iteration involves minimizing (6) with respect to y given the current estimates of wi(n). This is a simple least-squares minimization given by y = arg min y β X i,n ((ki ∗y)(n) −w(n))2 + X r,n ∥(∇r ∗y)(n)∥2. (10) Note that since all terms above are related to y by convolutions with different filters, we can carry out this minimization very efficiently in the Fourier domain. We initialize our iterations by setting wi(n) simply to the component mean cj i for which our predicted weight ˆpj i(n) is highest. Then, we apply the y and {wi(n)} minimization steps alternatingly, while increasing β from 2−10 to 27, by a factor of 21/8 at each iteration. 4 Experimental Results We train and evaluate our method on the NYU v2 depth dataset [11]. To construct our training and validation sets, we adopt the standard practice of using the raw videos corresponding to the training images from the official train/test split. We randomly select 10% of these videos for validation, and use the rest for training our network. Our training set is formed by sub-sampling video frames uniformly, and consists of roughly 56,000 color image-depth map pairs. Monocular depth estimation algorithms are evaluated on their accuracy in the 561 × 427 crop of the depth map that contains a valid depth projection (including filled-in areas within this crop). We use the same crop of the color image as input to our algorithm, and train our network accordingly. We let the scene map y(n) in our formulation correspond to the reciprocal of metric depth, i.e., y(n) = 1/z(n). While other methods use different compressive transform (e.g., [1, 2] regress to log z(n)), our choice is motivated by the fact that points on the image plane are related to their world co-ordinates by a perspective transform. This implies, for example, that in planar regions the first derivatives of y(n) will depend only on surface orientation, and that second derivatives will be zero. 4.1 Network Training We use data augmentation during training, applying random rotations of ±5◦and horizontal flips simultaneously to images and depth maps, and random contrast changes to images. We use a fully convolutional version of our architecture during training with a stride of 8 pixels, yielding nearly 4000 training patches per image. We train the network using SGD for a total of 14 epochs, using a batch size of only one image and a momentum value of 0.9. We begin with a learning rate of 0.01, and reduce it after the 4th, 8th, 10th, 12th, and 13th epochs, each time by a factor of two. This schedule was set by tracking the post-globalization depth accuracy on a validation set. 4.2 Evaluation First, we analyze the informativeness of individual distributional outputs from our neural network. Figure 3 visualizes the accuracy and confidence of the local per-coefficient distributions produced by our network on a typical image. For various derivative filters, we display maps of the absolute error between the true coefficient values wi(n) and the mean of the corresponding predicted distributions {pi,n(·)}. Alongside these errors, we also visualize the network’s “confidence” in terms of a map of the standard deviations of {pi,n(·)}. We see that the network makes high confidence predictions for different derivatives in different regions, and that the number of such high confidence predictions is least for zeroth order derivatives. Moreover, we find that all regions with high predicted confidence 6 Table 1: Effect of Individual Derivatives on Global Estimation Accuracy (on 100 validation images) Lower Better Higher Better Filters RMSE (lin.) RMSE(log) Abs Rel. Sqr Rel. δ < 1.25 δ < 1.252 δ < 1.253 Full 0.6921 0.2533 0.1887 0.1926 76.62% 91.58% 96.62% Scale 0,1 (All orders) 0.7471 0.2684 0.2019 0.2411 75.33% 90.90% 96.28% Scale 0,1,2 (All orders) 0.7241 0.2626 0.1967 0.2210 75.82% 91.12% 96.41% Order 0 (All scales) 0.7971 0.2775 0.2110 0.2735 73.64% 90.40% 95.99% Order 0,1 (All scales) 0.6966 0.2542 0.1894 0.1958 76.56% 91.53% 96.62% Scale 0 (Pointwise Depth) 0.7424 0.2656 0.2005 0.2177 74.50% 90.66% 96.30% Figure 3: We visualize the informativeness of the local predictions from our network (on an image from the validation set). We show the accuracy and confidence of the predicted distributions for coefficients of different derivative filters (shown inset), in terms of the error between the distribution mean and true coefficient value, and the distribution standard deviation respectively. We find that errors are always low in regions of high confidence (low standard deviation). We also find that despite the fact that individual coefficients have many low-confidence regions, our globalization procedure is able to combine them to produce an accurate depth map. (i.e., low standard deviation) also have low errors. Figure 3 also displays the corresponding global depth estimates, along with their accuracy relative to the ground truth. We find that despite having large low-confidence regions for individual coefficients, our final depth map is still quite accurate. This suggests that the information from different coefficients’ predicted distributions is complementary. To quantitatively characterize the contribution of the various components of our overcomplete representation, we conduct an ablation study on 100 validation images. With the same trained network, we include different subsets of filter coefficients for global estimation—leaving out either specific derivative orders, or scales—and report their accuracy in Table 1. We use the standard metrics from [2] for accuracy between estimated and true depth values ˆz(n) and z(n) across all pixels in all images: root mean square error (RMSE) of both z and log z, mean relative error (|z(n) −ˆz(n)|/z(n)) and relative square error (|z(n) −ˆz(n)|2/z(n)), as well as percentages of pixels with error δ = max(z(n)/ˆz(n), ˆz(n)/z(n)) below different thresholds. We find that removing each of these subsets degrades the performance of the global estimation method—with second order derivatives contributing least to final estimation accuracy. Interestingly, combining multiple scales but with only zeroth order derivatives performs worse than using just the point-wise depth distributions. Finally, we evaluate the performance of our method on the NYU v2 test set. Table 2 reports the quantitative performance of our method, along with other state-of-the-art approaches over the entire test set, and we find that the proposed method yields superior performance on most metrics. Figure 4 shows example predictions from our approach and that of [1]. We see that our approach is often able to better reproduce local geometric structure in its predictions (desk & chair in column 1, bookshelf in column 4), although it occasionally mis-estimates the relative position of some objects (e.g., globe in column 5). At the same time, it is also usually able to correctly estimate the depth of large and texture-less planar regions (but, see column 6 for an example failure case). Our overall inference method (network predictions and globalization) takes 24 seconds per-image when using an NVIDIA Titan X GPU. The source code for implementation, along with a pre-trained network model, are available at http://www.ttic.edu/chakrabarti/mdepth. 7 Table 2: Depth Estimation Performance on NYUv2 [11] Test Set Lower Better Higher Better Method RMSE (lin.) RMSE(log) Abs Rel. Sqr Rel. δ < 1.25 δ < 1.252 δ < 1.253 Proposed 0.620 0.205 0.149 0.118 80.6% 95.8% 98.7% Eigen 2015 [1] (VGG) 0.641 0.214 0.158 0.121 76.9% 95.0% 98.8% Wang [3] 0.745 0.262 0.220 0.210 60.5% 89.0% 97.0% Baig [5] 0.802 0.241 61.0% Eigen 2014 [2] 0.877 0.283 0.214 0.204 61.4% 88.8% 97.2% Liu [4] 0.824 0.230 61.4% 88.3% 97.1% Zoran [7] 1.22 0.43 0.41 0.57 Figure 4: Example depth estimation results on NYU v2 test set. 5 Conclusion In this paper, we described an alternative approach to reasoning about scene geometry from a single image. Instead of formulating the task as a regression to point-wise depth values, we trained a neural network to probabilistically characterize local coefficients of the scene depth map in an overcomplete representation. We showed that these local predictions could then be reconciled to form an estimate of the scene depth map using an efficient globalization procedure. We demonstrated the utility of our approach by evaluating it on the NYU v2 depth benchmark. Its performance on the monocular depth estimation task suggests that our network’s local predictions effectively summarize the depth cues present in a single image. In future work, we will explore how these predictions can be used in other settings—e.g., to aid stereo reconstruction, or improve the quality of measurements from active and passive depth sensors. We are also interested in exploring whether our approach of training a network to make overcomplete probabilistic local predictions can be useful in other applications, such as motion estimation or intrinsic image decomposition. Acknowledgments. AC acknowledges support for this work from the National Science Foundation under award no. IIS-1618021, and from a gift by Adobe Systems. AC and GS thank NVIDIA Corporation for donations of Titan X GPUs used in this research. 8 References [1] D. Eigen and R. Fergus. Predicting depth, surface normals and semantic labels with a common multi-scale convolutional architecture. In Proc. ICCV, 2015. [2] D. Eigen, C. Puhrsch, and R. Fergus. Depth map prediction from a single image using a multi-scale deep network. In NIPS, 2014. [3] P. Wang, X. Shen, Z. Lin, S. Cohen, B. Price, and A. Yuille. Towards unified depth and semantic prediction from a single image. In Proc. CVPR, 2015. [4] F. Liu, C. Shen, and G. Lin. Deep convolutional neural fields for depth estimation from a single image. In Proc. CVPR, 2015. [5] M. Baig and L. Torresani. Coupled depth learning. In Proc. WACV, 2016. [6] X. Wang, D. Fouhey, and A. Gupta. Designing deep networks for surface normal estimation. In Proc. CVPR, 2015. [7] D. Zoran, P. Isola, D. Krishnan, and W. T. Freeman. Learning ordinal relationships for mid-level vision. In Proc. ICCV, 2015. [8] K. Karsch, C. Liu, and S. B. Kang. Depth extraction from video using non-parametric sampling. In Proc. ECCV. 2012. [9] L. Ladicky, J. Shi, and M. Pollefeys. Pulling things out of perspective. In Proc. CVPR, 2014. [10] A. Saxena, S. H. Chung, and A. Y. Ng. Learning depth from single monocular images. In NIPS, 2005. [11] N. Silberman, D. Hoiem, P. Kohli, and R. Fergus. Indoor segmentation and support inference from rgbd images. In Proc. ECCV. 2012. [12] B. K. Horn and M. J. Brooks. Shape from shading. MIT Press, 1986. [13] M. B. Clowes. On seeing things. Artificial intelligence, 1971. [14] K. Sugihara. Machine interpretation of line drawings. MIT Press, 1986. [15] A. Chakrabarti, Y. Xiong, S. Gortler, and T. Zickler. Low-level vision by consensus in a spatial hierarchy of regions. In Proc. CVPR, 2015. [16] K. Chatfield, K. Simonyan, A. Vedaldi, and A. Zisserman. Return of the devil in the details: Delving deep into convolutional nets. In Proc. BMVC, 2014. [17] J. Long, E. Shelhamer, and T. Darrell. Fully convolutional networks for semantic segmentation. In Proc. CVPR, 2015. 9 | 2016 | 544 |
6,488 | Ancestral Causal Inference Sara Magliacane VU Amsterdam & University of Amsterdam sara.magliacane@gmail.com Tom Claassen Radboud University Nijmegen tomc@cs.ru.nl Joris M. Mooij University of Amsterdam j.m.mooij@uva.nl Abstract Constraint-based causal discovery from limited data is a notoriously difficult challenge due to the many borderline independence test decisions. Several approaches to improve the reliability of the predictions by exploiting redundancy in the independence information have been proposed recently. Though promising, existing approaches can still be greatly improved in terms of accuracy and scalability. We present a novel method that reduces the combinatorial explosion of the search space by using a more coarse-grained representation of causal information, drastically reducing computation time. Additionally, we propose a method to score causal predictions based on their confidence. Crucially, our implementation also allows one to easily combine observational and interventional data and to incorporate various types of available background knowledge. We prove soundness and asymptotic consistency of our method and demonstrate that it can outperform the state-ofthe-art on synthetic data, achieving a speedup of several orders of magnitude. We illustrate its practical feasibility by applying it to a challenging protein data set. 1 Introduction Discovering causal relations from data is at the foundation of the scientific method. Traditionally, cause-effect relations have been recovered from experimental data in which the variable of interest is perturbed, but seminal work like the do-calculus [16] and the PC/FCI algorithms [23, 26] demonstrate that, under certain assumptions (e.g., the well-known Causal Markov and Faithfulness assumptions [23]), it is already possible to obtain substantial causal information by using only observational data. Recently, there have been several proposals for combining observational and experimental data to discover causal relations. These causal discovery methods are usually divided into two categories: constraint-based and score-based methods. Score-based methods typically evaluate models using a penalized likelihood score, while constraint-based methods use statistical independences to express constraints over possible causal models. The advantages of constraint-based over score-based methods are the ability to handle latent confounders and selection bias naturally, and that there is no need for parametric modeling assumptions. Additionally, constraint-based methods expressed in logic [2, 3, 25, 8] allow for an easy integration of background knowledge, which is not trivial even for simple cases in approaches that are not based on logic [1]. Two major disadvantages of traditional constraint-based methods are: (i) vulnerability to errors in statistical independence test results, which are quite common in real-world applications, (ii) no ranking or estimation of the confidence in the causal predictions. Several approaches address the first issue and improve the reliability of constraint-based methods by exploiting redundancy in the independence information [3, 8, 25]. The idea is to assign weights to the input statements that reflect 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. their reliability, and then use a reasoning scheme that takes these weights into account. Several weighting schemes can be defined, from simple ways to attach weights to single independence statements [8], to more complicated schemes to obtain weights for combinations of independence statements [25, 3]. Unfortunately, these approaches have to sacrifice either accuracy by using a greedy method [3, 25], or scalability by formulating a discrete optimization problem on a super-exponentially large search space [8]. Additionally, the confidence estimation issue is addressed only in limited cases [17]. We propose Ancestral Causal Inference (ACI), a logic-based method that provides comparable accuracy to the best state-of-the-art constraint-based methods (e.g., [8]) for causal systems with latent variables without feedback, but improves on their scalability by using a more coarse-grained representation of causal information. Instead of representing all possible direct causal relations, in ACI we represent and reason only with ancestral relations (“indirect” causal relations), developing specialised ancestral reasoning rules. This representation, though still super-exponentially large, drastically reduces computation time. Moreover, it turns out to be very convenient, because in real-world applications the distinction between direct causal relations and ancestral relations is not always clear or necessary. Given the estimated ancestral relations, the estimation can be refined to direct causal relations by constraining standard methods to a smaller search space, if necessary. Furthermore, we propose a method to score predictions according to their confidence. The confidence score can be thought of as an approximation to the marginal probability of an ancestral relation. Scoring predictions enables one to rank them according to their reliability, allowing for higher accuracy. This is very important for practical applications, as the low reliability of the predictions of constraint-based methods has been a major impediment to their wide-spread use. We prove soundness and asymptotic consistency under mild conditions on the statistical tests for ACI and our scoring method. We show that ACI outperforms standard methods, like bootstrapped FCI and CFCI, in terms of accuracy, and achieves a speedup of several orders of magnitude over [8] on a synthetic dataset. We illustrate its practical feasibility by applying it to a challenging protein data set [21] that so far had only been addressed with score-based methods and observe that it successfully recovers from faithfulness violations. In this context, we showcase the flexibility of logic-based approaches by introducing weighted ancestral relation constraints that we obtain from a combination of observational and interventional data, and show that they substantially increase the reliability of the predictions. Finally, we provide an open-source version of our algorithms and the evaluation framework, which can be easily extended, at http://github.com/caus-am/aci. 2 Preliminaries and related work Preliminaries We assume that the data generating process can be modeled by a causal Directed Acyclic Graph (DAG) that may contain latent variables. For simplicity we also assume that there is no selection bias. Finally, we assume that the Causal Markov Assumption and the Causal Faithfulness Assumption [23] both hold. In other words, the conditional independences in the observational distribution correspond one-to-one with the d-separations in the causal DAG. Throughout the paper we represent variables with uppercase letters, while sets of variables are denoted by boldface. All proofs are provided in the Supplementary Material. A directed edge X →Y in the causal DAG represents a direct causal relation between cause X on effect Y . Intuitively, in this framework this indicates that manipulating X will produce a change in Y , while manipulating Y will have no effect on X. A more detailed discussion can be found in [23]. A sequence of directed edges X1 →X2 →· · · →Xn is a directed path. If there exists a directed path from X to Y (or X = Y ), then X is an ancestor of Y (denoted as X 99K Y ). Otherwise, X is not an ancestor of Y (denoted as X ̸99K Y ). For a set of variables W , we write: X 99K W := ∃Y ∈W : X 99K Y, X ̸99K W := ∀Y ∈W : X ̸99K Y. (1) We define an ancestral structure as any non-strict partial order on the observed variables of the DAG, i.e., any relation that satisfies the following axioms: (reflexivity) : X 99K X, (2) (transitivity) : X 99K Y ∧Y 99K Z =⇒X 99K Z, (3) (antisymmetry) : X 99K Y ∧Y 99K X =⇒X = Y. (4) 2 The underlying causal DAG induces a unique “true” ancestral structure, which represents the transitive closure of the direct causal relations projected on the observed variables. For disjoint sets X, Y , W we denote conditional independence of X and Y given W as X ⊥⊥ Y | W , and conditional dependence as X ̸⊥⊥Y | W . We call the cardinality |W | the order of the conditional (in)dependence relation. Following [2] we define a minimal conditional independence by: X ⊥⊥Y | W ∪[Z] := (X ⊥⊥Y | W ∪Z) ∧(X ̸⊥⊥Y | W ), and similarly, a minimal conditional dependence by: X ̸⊥⊥Y | W ∪[Z] := (X ̸⊥⊥Y | W ∪Z) ∧(X ⊥⊥Y | W ). The square brackets indicate that Z is needed for the (in)dependence to hold in the context of W . Note that the negation of a minimal conditional independence is not a minimal conditional dependence. Minimal conditional (in)dependences are closely related to ancestral relations, as pointed out in [2]: Lemma 1. For disjoint (sets of) variables X, Y, Z, W : X ⊥⊥Y | W ∪[Z] =⇒Z 99K ({X, Y } ∪W ), (5) X ̸⊥⊥Y | W ∪[Z] =⇒Z ̸99K ({X, Y } ∪W ). (6) Exploiting these rules (as well as others that will be introduced in Section 3) to deduce ancestral relations directly from (in)dependences is key to the greatly improved scalability of our method. Related work on conflict resolution One of the earliest algorithms to deal with conflicting inputs in constraint-based causal discovery is Conservative PC [18], which adds “redundant” checks to the PC algorithm that allow it to detect inconsistencies in the inputs, and then makes only predictions that do not rely on the ambiguous inputs. The same idea can be applied to FCI, yielding Conservative FCI (CFCI) [4, 10]. BCCD (Bayesian Constraint-based Causal Discovery) [3] uses Bayesian confidence estimates to process information in decreasing order of reliability, discarding contradictory inputs as they arise. COmbINE (Causal discovery from Overlapping INtErventions) [25] is an algorithm that combines the output of FCI on several overlapping observational and experimental datasets into a single causal model by first pooling and recalibrating the independence test p-values, and then adding each constraint incrementally in order of reliability to a SAT instance. Any constraint that makes the problem unsatisfiable is discarded. Our approach is inspired by a method presented by Hyttinen, Eberhardt and Järvisalo [8] (that we will refer to as HEJ in this paper), in which causal discovery is formulated as a constrained discrete minimization problem. Given a list of weighted independence statements, HEJ searches for the optimal causal graph G (an acyclic directed mixed graph, or ADMG) that minimizes the sum of the weights of the independence statements that are violated according to G. In order to test whether a causal graph G induces a certain independence, the method creates an encoding DAG of d-connection graphs. D-connection graphs are graphs that can be obtained from a causal graph through a series of operations (conditioning, marginalization and interventions). An encoding DAG of d-connection graphs is a complex structure encoding all possible d-connection graphs and the sequence of operations that generated them from a given causal graph. This approach has been shown to correct errors in the inputs, but is computationally demanding because of the huge search space. 3 ACI: Ancestral Causal Inference We propose Ancestral Causal Inference (ACI), a causal discovery method that accurately reconstructs ancestral structures, also in the presence of latent variables and statistical errors. ACI builds on HEJ [8], but rather than optimizing over encoding DAGs, ACI optimizes over the much simpler (but still very expressive) ancestral structures. For n variables, the number of possible ancestral structures is the number of partial orders (http: //oeis.org/A001035), which grows as 2n2/4+o(n2) [11], while the number of DAGs can be computed with a well-known super-exponential recurrence formula (http://oeis.org/A003024). The number of ADMGs is | DAG(n)| × 2n(n−1)/2. Although still super-exponential, the number of ancestral structures grows asymptotically much slower than the number of DAGs and even more so, ADMGs. For example, for 7 variables, there are 6 × 106 ancestral structures but already 2.3 × 1015 ADMGs, which lower bound the number of encoding DAGs of d-connection graphs used by HEJ. 3 New rules The rules in HEJ explicitly encode marginalization and conditioning operations on d-connection graphs, so they cannot be easily adapted to work directly with ancestral relations. Instead, ACI encodes the ancestral reasoning rules (2)–(6) and five novel causal reasoning rules: Lemma 2. For disjoint (sets) of variables X, Y, U, Z, W : (X ⊥⊥Y | Z) ∧(X ̸99K Z) =⇒X ̸99K Y, (7) X ̸⊥⊥Y | W ∪[Z] =⇒X ̸⊥⊥Z | W , (8) X ⊥⊥Y | W ∪[Z] =⇒X ̸⊥⊥Z | W , (9) (X ⊥⊥Y | W ∪[Z]) ∧(X ⊥⊥Z | W ∪U) =⇒(X ⊥⊥Y | W ∪U), (10) (Z ̸⊥⊥X | W ) ∧(Z ̸⊥⊥Y | W ) ∧(X ⊥⊥Y | W ) =⇒X ̸⊥⊥Y | W ∪Z. (11) We prove the soundness of the rules in the Supplementary Material. We elaborate some conjectures about their completeness in the discussion after Theorem 1 in the next Section. Optimization of loss function We formulate causal discovery as an optimization problem where a loss function is optimized over possible causal structures. Intuitively, the loss function sums the weights of all the inputs that are violated in a candidate causal structure. Given a list I of weighted input statements (ij, wj), where ij is the input statement and wj is the associated weight, we define the loss function as the sum of the weights of the input statements that are not satisfied in a given possible structure W ∈W, where W denotes the set of all possible causal structures. Causal discovery is formulated as a discrete optimization problem: W ∗= arg min W ∈W L(W; I), (12) L(W; I) := X (ij,wj)∈I: W ∪R|=¬ij wj, (13) where W ∪R |= ¬ij means that input ij is not satisfied in structure W according to the rules R. This general formulation includes both HEJ and ACI, which differ in the types of possible structures W and the rules R. In HEJ W represents all possible causal graphs (specifically, acyclic directed mixed graphs, or ADMGs, in the acyclic case) and R are operations on d-connection graphs. In ACI W represent ancestral structures (defined with the rules(2)-(4)) and the rules R are rules (5)–(11). Constrained optimization in ASP The constrained optimization problem in (12) can be implemented using a variety of methods. Given the complexity of the rules, a formulation in an expressive logical language that supports optimization, e.g., Answer Set Programming (ASP), is very convenient. ASP is a widely used declarative programming language based on the stable model semantics [12, 7] that has successfully been applied to several NP-hard problems. For ACI we use the state-of-the-art ASP solver clingo 4 [6]. We provide the encoding in the Supplementary Material. Weighting schemes ACI supports two types of input statements: conditional independences and ancestral relations. These statements can each be assigned a weight that reflects their confidence. We propose two simple approaches with the desirable properties of making ACI asymptotically consistent under mild assumptions (as described in the end of this Section), and assigning a much smaller weight to independences than to dependences (which agrees with the intuition that one is confident about a measured strong dependence, but not about independence vs. weak dependence). The approaches are: • a frequentist approach, in which for any appropriate frequentist statistical test with independence as null hypothesis (resp. a non-ancestral relation), we define the weight: w = | log p −log α|, where p = p-value of the test, α = significance level (e.g., 5%); (14) • a Bayesian approach, in which the weight of each input statement i using data set D is: w = log p(i|D) p(¬i|D) = log p(D|i) p(D|¬i) p(i) p(¬i), (15) where the prior probability p(i) can be used as a tuning parameter. 4 Given observational and interventional data, in which each intervention has a single known target (in particular, it is not a fat-hand intervention [5]), a simple way to obtain a weighted ancestral statement X 99K Y is with a two-sample test that tests whether the distribution of Y changes with respect to its observational distribution when intervening on X. This approach conveniently applies to various types of interventions: perfect interventions [16], soft interventions [14], mechanism changes [24], and activity interventions [15]. The two-sample test can also be implemented as an independence test that tests for the independence of Y and IX, the indicator variable that has value 0 for observational samples and 1 for samples from the interventional distribution in which X has been intervened upon. 4 Scoring causal predictions The constrained minimization in (12) may produce several optimal solutions, because the underlying structure may not be identifiable from the inputs. To address this issue, we propose to use the loss function (13) and score the confidence of a feature f (e.g., an ancestral relation X 99K Y ) as: C(f) = min W ∈W L(W; I ∪{(¬f, ∞)}) −min W ∈W L(W; I ∪{(f, ∞)}). (16) Without going into details here, we note that the confidence (16) can be interpreted as a MAP approximation of the log-odds ratio of the probability that feature f is true in a Markov Logic model: P(f | I, R) P(¬f | I, R) = P W ∈W e−L(W ;I)1W ∪R|=f P W ∈W e−L(W ;I)1W ∪R|=¬f ≈maxW ∈W e−L(W ;I∪{(f,∞)}) maxW ∈W e−L(W ;I∪{(¬f,∞)}) = eC(f). In this paper, we usually consider the features f to be ancestral relations, but the idea is more generally applicable. For example, combined with HEJ it can be used to score direct causal relations. Soundness and completeness Our scoring method is sound for oracle inputs: Theorem 1. Let R be sound (not necessarily complete) causal reasoning rules. For any feature f, the confidence score C(f) of (16) is sound for oracle inputs with infinite weights. Here, soundness means that C(f) = ∞if f is identifiable from the inputs, C(f) = −∞if ¬f is identifiable from the inputs, and C(f) = 0 otherwise (neither are identifiable). As features, we can consider for example ancestral relations f = X 99K Y for variables X, Y . We conjecture that the rules (2)–(11) are “order-1-complete”, i.e., they allow one to deduce all (non)ancestral relations that are identifiable from oracle conditional independences of order ≤1 in observational data. For higher-order inputs additional rules can be derived. However, our primary interest in this work is improving computation time and accuracy, and we are willing to sacrifice completeness. A more detailed study of the completeness properties is left as future work. Asymptotic consistency Denote the number of samples by N. For the frequentist weights in (14), we assume that the statistical tests are consistent in the following sense: log pN −log αN P→ −∞ H1 +∞ H0, (17) as N →∞, where the null hypothesis H0 is independence/nonancestral relation and the alternative hypothesis H1 is dependence/ancestral relation. Note that we need to choose a sample-size dependent threshold αN such that αN →0 at a suitable rate. Kalisch and Bühlmann [9] show how this can be done for partial correlation tests under the assumption that the distribution is multivariate Gaussian. For the Bayesian weighting scheme in (15), we assume that for N →∞, wN P→ −∞ if i is true +∞ if i is false. (18) This will hold (as long as there is no model misspecification) under mild technical conditions for finite-dimensional exponential family models. In both cases, the probability of a type I or type II error will converge to 0, and in addition, the corresponding weight will converge to ∞. Theorem 2. Let R be sound (not necessarily complete) causal reasoning rules. For any feature f, the confidence score C(f) of (16) is asymptotically consistent under assumption (17) or (18). Here, “asymptotically consistent” means that the confidence score C(f) →∞in probability if f is identifiably true, C(f) →−∞in probability if f is identifiably false, and C(f) →0 in probability otherwise. 5 Average execution time (s) n c ACI HEJ BAFCI BACFCI 6 1 0.21 12.09 8.39 12.51 6 4 1.66 432.67 11.10 16.36 7 1 1.03 715.74 9.37 15.12 8 1 9.74 ≥2500 13.71 21.71 9 1 146.66 ≫2500 18.28 28.51 (a) 0.1 1 10 100 1000 10000 1 101 201 301 401 501 601 701 801 901 1001 1101 1201 1301 1401 1501 1601 1701 1801 1901 Execution time (s) Instances (sorted by solution time) HEJ ACI (b) Figure 1: Execution time comparison on synthetic data for the frequentist test on 2000 synthetic models: (a) average execution time for different combinations of number of variables n and max. order c; (b) detailed plot of execution times for n = 7, c = 1 (logarithmic scale). 5 Evaluation In this section we report evaluations on synthetically generated data and an application on a real dataset. Crucially, in causal discovery precision is often more important than recall. In many realworld applications, discovering a few high-confidence causal relations is more useful than finding every possible causal relation, as reflected in recently proposed algorithms, e.g., [17]. Compared methods We compare the predictions of ACI and of the acyclic causally insufficient version of HEJ [8], when used in combination with our scoring method (16). We also evaluate two standard methods: Anytime FCI [22, 26] and Anytime CFCI [4], as implemented in the pcalg R package [10]. We use the anytime versions of (C)FCI because they allow for independence test results up to a certain order. We obtain the ancestral relations from the output PAG using Theorem 3.1 from [20]. (Anytime) FCI and CFCI do not rank their predictions, but only predict the type of relation: ancestral (which we convert to +1), non-ancestral (-1) and unknown (0). To get a scoring of the predictions, we also compare with bootstrapped versions of Anytime FCI and Anytime CFCI. We perform the bootstrap by repeating the following procedure 100 times: sample randomly half of the data, perform the independence tests, run Anytime (C)FCI. From the 100 output PAGs we extract the ancestral predictions and average them. We refer to these methods as BA(C)FCI. For a fair comparison, we use the same independence tests and thresholds for all methods. Synthetic data We simulate the data using the simulator from HEJ [8]: for each experimental condition (e.g., a given number of variables n and order c), we generate randomly M linear acyclic models with latent variables and Gaussian noise and sample N = 500 data points. We then perform independence tests up to order c and weight the (in)dependence statements using the weighting schemes described in Section 3. For the frequentist weights we use tests based on partial correlations and Fisher’s z-transform to obtain approximate p-values (see, e.g., [9]) with significance level α = 0.05. For the Bayesian weights, we use the Bayesian test for conditional independence presented in [13] as implemented by HEJ with a prior probability of 0.1 for independence. In Figure 1(a) we show the average execution times on a single core of a 2.80GHz CPU for different combinations of n and c, while in Figure 1(b) we show the execution times for n = 7, c = 1, sorting the execution times in ascending order. For 7 variables ACI is almost 3 orders of magnitude faster than HEJ, and the difference grows exponentially as n increases. For 8 variables HEJ can complete only four of the first 40 simulated models before the timeout of 2500s. For reference we add the execution time for bootstrapped anytime FCI and CFCI. In Figure 2 we show the accuracy of the predictions with precision-recall (PR) curves for both ancestral (X 99K Y ) and nonancestral (X ̸99K Y ) relations, in different settings. In this Figure, for ACI and HEJ all of the results are computed using frequentist weights and, as in all evaluations, our scoring method (16). While for these two methods we use c = 1, for (bootstrapped) (C)FCI we use all possible independence test results (c = n −2). In this case, the anytime versions of FCI and CFCI are equivalent to the standard versions of FCI and CFCI. Since the overall results are similar, we report the results with the Bayesian weights in the Supplementary Material. In the first row of Figure 2, we show the setting with n = 6 variables. The performances of HEJ and ACI coincide, performing significantly better for nonancestral predictions and the top ancestral 6 Recall 0 0.05 0.1 0.15 0.2 Precision 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1 Bootstrapped (100) CFCI Bootstrapped (100) FCI HEJ (c=1) ACI (c=1) Standard CFCI Standard FCI (a) PR ancestral: n=6 Recall 0 0.005 0.01 0.015 0.02 Precision 0.6 0.65 0.7 0.75 0.8 0.85 0.9 0.95 1 (b) PR ancestral: n=6 (zoom) Recall 0 0.2 0.4 0.6 0.8 1 Precision 0.86 0.88 0.9 0.92 0.94 0.96 0.98 1 Bootstrapped (100) CFCI Bootstrapped (100) FCI HEJ (c=1) ACI (c=1) Standard CFCI Standard FCI (c) PR nonancestral: n=6 Recall 0 0.05 0.1 0.15 0.2 Precision 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1 Bootstrapped (100) CFCI Bootstrapped (100) FCI ACI (c=1) ACI (c=1, i=1) Standard CFCI Standard FCI (d) PR ancestral: n=8 Recall 0 0.005 0.01 0.015 0.02 Precision 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1 (e) PR ancestral: n=8 (zoom) Recall 0 0.2 0.4 0.6 0.8 1 Precision 0.9 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 1 Bootstrapped (100) CFCI Bootstrapped (100) FCI ACI (c=1) ACI (c=1, i=1) Standard CFCI Standard FCI (f) PR nonancestral: n=8 Figure 2: Accuracy on synthetic data for the two prediction tasks (ancestral and nonancestral relations) using the frequentist test with α = 0.05. The left column shows the precision-recall curve for ancestral predictions, the middle column shows a zoomed-in version in the interval (0,0.02), while the right column shows the nonancestral predictions. predictions (see zoomed-in version in Figure 2(b)). This is remarkable, as HEJ and ACI use only independence test results up to order c = 1, in contrast with (C)FCI which uses independence test results of all orders. Interestingly, the two discrete optimization algorithms do not seem to benefit much from higher order independence tests, thus we omit them from the plots (although we add the graphs in the Supplementary Material). Instead, bootstrapping traditional methods, oblivious to the (in)dependence weights, seems to produce surprisingly good results. Nevertheless, both ACI and HEJ outperform bootstrapped FCI and CFCI, suggesting these methods achieve nontrivial error-correction. In the second row of Figure 2, we show the setting with 8 variables. In this setting HEJ is too slow. In addition to the previous plot, we plot the accuracy of ACI when there is oracle background knowledge on the descendants of one variable (i = 1). This setting simulates the effect of using interventional data, and we can see that the performance of ACI improves significantly, especially in the ancestral preditions. The performance of (bootstrapped) FCI and CFCI is limited by the fact that they cannot take advantage of this background knowledge, except with complicated postprocessing [1]. Application on real data We consider the challenging task of reconstructing a signalling network from flow cytometry data [21] under different experimental conditions. Here we consider one experimental condition as the observational setting and seven others as interventional settings. More details and more evaluations are reported in the Supplementary Material. In contrast to likelihoodbased approaches like [21, 5, 15, 19], in our approach we do not need to model the interventions quantitatively. We only need to know the intervention targets, while the intervention types do not matter. Another advantage of our approach is that it takes into account possible latent variables. We use a t-test to test for each intervention and for each variable whether its distribution changes with respect to the observational condition. We use the p-values of these tests as in (14) in order to obtain weighted ancestral relations that are used as input (with threshold α = 0.05). For example, if adding U0126 (a MEK inhibitor) changes the distribution of RAF significantly with respect to the observational baseline, we get a weighted ancestral relation MEK99KRAF. In addition, we use partial correlations up to order 1 (tested in the observational data only) to obtain weighted independences used as input. We use ACI with (16) to score the ancestral relations for each ordered pair of variables. The main results are illustrated in Figure 3, where we compare ACI with bootstrapped anytime CFCI 7 Raf Mek PLCg PIP2 PIP3 Erk Akt PKA PKC p38 JNK BCFCI (indep. <= 1) Raf Mek PLCg PIP2 PIP3 Erk Akt PKA PKC p38 JNK (a) Bootstrapped (100) anytime CFCI (input: independences of order ≤1) Raf Mek PLCg PIP2 PIP3 Erk Akt PKA PKC p38 JNK ACI (ancestral relations) Raf Mek PLCg PIP2 PIP3 Erk Akt PKA PKC p38 JNK (b) ACI (input: weighted ancestral relations) Raf Mek PLCg PIP2 PIP3 Erk Akt PKA PKC p38 JNK ACI (ancestral r. + indep. <= 1) Raf Mek PLCg PIP2 PIP3 Erk Akt PKA PKC p38 JNK (c) ACI (input: independences of order ≤1, weighted ancestral relations) Weighted causes(i,j) Raf Mek PLCg PIP2 PIP3 Erk Akt PKA PKC p38 JNK Raf Mek PLCg PIP2 PIP3 Erk Akt PKA PKC p38 JNK −1000 −500 0 500 1000 Weighted indep(i,j) Raf Mek PLCg PIP2 PIP3 Erk Akt PKA PKC p38 JNK Raf Mek PLCg PIP2 PIP3 Erk Akt PKA PKC p38 JNK −1000 −500 0 500 1000 Ra Mek PLCg PIP2 PIP3 Erk Ak PKA PKC p38 JNK ACI (causes) Raf Mek PLCg PIP2 PIP3 Erk Akt PKA PKC p38 JNK Raf Mek PLCg PIP2 PIP3 Erk Akt PKA PKC p38 JNK −1000 −500 0 500 1000 A Ra Mek PLCg PIP2 PIP3 Erk Ak PKA PKC p38 JNK FCI Raf Mek PLCg PIP2 PIP3 Erk Akt PKA PKC p38 JNK Raf Mek PLCg PIP2 PIP3 Erk Akt PKA PKC p38 JNK −1000 −500 0 500 1000 CFCI Raf Mek PLCg PIP2 PIP3 Erk Akt PKA PKC p38 JNK Raf Mek PLCg PIP2 PIP3 Erk Akt PKA PKC p38 JNK −1000 −500 0 500 1000 Ra Mek PLCg PIP2 PIP3 Erk Ak PKA PKC p38 JNK Figure 3: Results for flow cytometry dataset. Each matrix represents the ancestral relations, where each row represents a cause and each column an effect. The colors encode the confidence levels: green is positive, black is unknown, while red is negative. The intensity of the color represents the degree of confidence. For example, ACI identifies MEK to be a cause of RAF with high confidence. under different inputs. The output for boostrapped anytime FCI is similar, so we report it only in the Supplementary Material. Algorithms like (anytime) (C)FCI can only use the independences in the observational data as input and therefore miss the strongest signal, weighted ancestral relations, which are obtained by comparing interventional with observational data. In the Supplementary Material, we compare also with other methods ([17], [15]). Interestingly, as we show there, our results are similar to the best acyclic model reconstructed by the score-based method from [15]. As for other constraint-based methods, HEJ is computationally unfeasible in this setting, while COMBINE assumes perfect interventions (while this dataset contains mostly activity interventions). Notably, our algorithms can correctly recover from faithfulness violations (e.g., the independence between MEK and ERK), because they take into account the weight of the input statements (the weight of the independence is considerably smaller than that of the ancestral relation, which corresponds with a quite significant change in distribution). In contrast, methods that start by reconstructing the skeleton, like (anytime) (C)FCI, would decide that MEK and ERK are nonadjacent, and are unable to recover from that erroneous decision. This illustrates another advantage of our approach. 6 Discussion and conclusions As we have shown, ancestral structures are very well-suited for causal discovery. They offer a natural way to incorporate background causal knowledge, e.g., from experimental data, and allow a huge computational advantage over existing representations for error-correcting algorithms, such as [8]. When needed, ancestral structures can be mapped to a finer-grained representation with direct causal relations, as we sketch in the Supplementary Material. Furthermore, confidence estimates on causal predictions are extremely helpful in practice, and can significantly boost the reliability of the output. Although standard methods, like bootstrapping (C)FCI, already provide reasonable estimates, methods that take into account the confidence in the inputs, as the one presented here, can lead to further improvements of the reliability of causal relations inferred from data. Strangely (or fortunately) enough, neither of the optimization methods seems to improve much with higher order independence test results. We conjecture that this may happen because our loss function essentially assumes that the test results are independent from another (which is not true). Finding a way to take this into account in the loss function may further improve the achievable accuracy, but such an extension may not be straightforward. Acknowledgments SM and JMM were supported by NWO, the Netherlands Organization for Scientific Research (VIDI grant 639.072.410). SM was also supported by the Dutch programme COMMIT/ under the Data2Semantics project. TC was supported by NWO grant 612.001.202 (MoCoCaDi), and EU-FP7 grant agreement n.603016 (MATRICS). We also thank Sofia Triantafillou for her feedback, especially for pointing out the correct way to read ancestral relations from a PAG. 8 References [1] G. Borboudakis and I. Tsamardinos. Incorporating causal prior knowledge as path-constraints in Bayesian networks and Maximal Ancestral Graphs. In ICML, pages 1799–1806, 2012. [2] T. Claassen and T. Heskes. A logical characterization of constraint-based causal discovery. In UAI, pages 135–144, 2011. [3] T. Claassen and T. Heskes. A Bayesian approach to constraint-based causal inference. In UAI, pages 207–216, 2012. [4] D. Colombo, M. H. Maathuis, M. Kalisch, and T. S. Richardson. Learning high-dimensional directed acyclic graphs with latent and selection variables. The Annals of Statistics, 40(1):294–321, 2012. [5] D. Eaton and K. Murphy. Exact Bayesian structure learning from uncertain interventions. In AISTATS, pages 107–114, 2007. [6] M. Gebser, R. Kaminski, B. Kaufmann, and T. Schaub. Clingo = ASP + control: Extended report. Technical report, University of Potsdam, 2014. http://www.cs.uni-potsdam.de/wv/pdfformat/ gekakasc14a.pdf. [7] M. Gelfond. Answer sets. In Handbook of Knowledge Representation, pages 285–316. 2008. [8] A. Hyttinen, F. Eberhardt, and M. Järvisalo. Constraint-based causal discovery: Conflict resolution with Answer Set Programming. In UAI, pages 340–349, 2014. [9] M. Kalisch and P. Bühlmann. Estimating high-dimensional directed acyclic graphs with the PC-algorithm. Journal of Machine Learning Research, 8:613–636, 2007. [10] M. Kalisch, M. Mächler, D. Colombo, M. Maathuis, and P. Bühlmann. Causal inference using graphical models with the R package pcalg. Journal of Statistical Software, 47(1):1–26, 2012. [11] D. J. Kleitman and B. L. Rothschild. Asymptotic enumeration of partial orders on a finite set. Transactions of the American Mathematical Society, 205:205–220, 1975. [12] V. Lifschitz. What is Answer Set Programming? In AAAI, pages 1594–1597, 2008. [13] D. Margaritis and F. Bromberg. Efficient Markov network discovery using particle filters. Computational Intelligence, 25(4):367–394, 2009. [14] F. Markowetz, S. Grossmann, and R. Spang. Probabilistic soft interventions in conditional Gaussian networks. In AISTATS, pages 214–221, 2005. [15] J. M. Mooij and T. Heskes. Cyclic causal discovery from continuous equilibrium data. In UAI, pages 431–439, 2013. [16] J. Pearl. Causality: models, reasoning and inference. Cambridge University Press, 2009. [17] J. Peters, P. Bühlmann, and N. Meinshausen. Causal inference using invariant prediction: identification and confidence intervals. Journal of the Royal Statistical Society, Series B, 8(5):947–1012, 2015. [18] J. Ramsey, J. Zhang, and P. Spirtes. Adjacency-faithfulness and conservative causal inference. In UAI, pages 401–408, 2006. [19] D. Rothenhäusler, C. Heinze, J. Peters, and N. Meinshausen. BACKSHIFT: Learning causal cyclic graphs from unknown shift interventions. In NIPS, pages 1513–1521, 2015. [20] A. Roumpelaki, G. Borboudakis, S. Triantafillou, and I. Tsamardinos. Marginal causal consistency in constraint-based causal learning. In Causation: Foundation to Application Workshop, UAI, 2016. [21] K. Sachs, O. Perez, D. Pe’er, D. Lauffenburger, and G. Nolan. Causal protein-signaling networks derived from multiparameter single-cell data. Science, 308:523–529, 2005. [22] P. Spirtes. An anytime algorithm for causal inference. In AISTATS, pages 121–128, 2001. [23] P. Spirtes, C. Glymour, and R. Scheines. Causation, Prediction, and Search. MIT press, 2000. [24] J. Tian and J. Pearl. Causal discovery from changes. In UAI, pages 512–521, 2001. [25] S. Triantafillou and I. Tsamardinos. Constraint-based causal discovery from multiple interventions over overlapping variable sets. Journal of Machine Learning Research, 16:2147–2205, 2015. [26] J. Zhang. On the completeness of orientation rules for causal discovery in the presence of latent confounders and selection bias. Artifical Intelligence, 172(16-17):1873–1896, 2008. 9 | 2016 | 545 |
6,489 | Hierarchical Deep Reinforcement Learning: Integrating Temporal Abstraction and Intrinsic Motivation Tejas D. Kulkarni∗ DeepMind, London tejasdkulkarni@gmail.com Karthik R. Narasimhan∗ CSAIL, MIT karthikn@mit.edu Ardavan Saeedi CSAIL, MIT ardavans@mit.edu Joshua B. Tenenbaum BCS, MIT jbt@mit.edu Abstract Learning goal-directed behavior in environments with sparse feedback is a major challenge for reinforcement learning algorithms. One of the key difficulties is insufficient exploration, resulting in an agent being unable to learn robust policies. Intrinsically motivated agents can explore new behavior for their own sake rather than to directly solve external goals. Such intrinsic behaviors could eventually help the agent solve tasks posed by the environment. We present hierarchicalDQN (h-DQN), a framework to integrate hierarchical action-value functions, operating at different temporal scales, with goal-driven intrinsically motivated deep reinforcement learning. A top-level q-value function learns a policy over intrinsic goals, while a lower-level function learns a policy over atomic actions to satisfy the given goals. h-DQN allows for flexible goal specifications, such as functions over entities and relations. This provides an efficient space for exploration in complicated environments. We demonstrate the strength of our approach on two problems with very sparse and delayed feedback: (1) a complex discrete stochastic decision process with stochastic transitions, and (2) the classic ATARI game – ‘Montezuma’s Revenge’. 1 Introduction Learning goal-directed behavior with sparse feedback from complex environments is a fundamental challenge for artificial intelligence. Learning in this setting requires the agent to represent knowledge at multiple levels of spatio-temporal abstractions and to explore the environment efficiently. Recently, non-linear function approximators coupled with reinforcement learning [14, 16, 23] have made it possible to learn abstractions over high-dimensional state spaces, but the task of exploration with sparse feedback still remains a major challenge. Existing methods like Boltzmann exploration and Thomson sampling [31, 19] offer significant improvements over ϵ-greedy, but are limited due to the underlying models functioning at the level of basic actions. In this work, we propose a framework that integrates deep reinforcement learning with hierarchical action-value functions (h-DQN), where the top-level module learns a policy over options (subgoals) and the bottom-level module learns policies to accomplish the objective of each option. Exploration in the space of goals enables efficient exploration in problems with sparse and delayed rewards. Additionally, our experiments indicate that goals expressed in the space of entities and relations can help constraint the exploration space for data efficient deep reinforcement learning in complex environments. ∗Equal Contribution. Work done while Tejas Kulkarni was affiliated with MIT. 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. Reinforcement learning (RL) formalizes control problems as finding a policy π that maximizes expected future rewards [32]. Value functions V (s) are central to RL, and they cache the utility of any state s in achieving the agent’s overall objective. Recently, value functions have also been generalized as V (s, g) in order to represent the utility of state s for achieving a given goal g ∈ G [33, 21]. When the environment provides delayed rewards, we adopt a strategy to first learn ways to achieve intrinsically generated goals, and subsequently learn an optimal policy to chain them together. Each of the value functions V (s, g) can be used to generate a policy that terminates when the agent reaches the goal state g. A collection of these policies can be hierarchically arranged with temporal dynamics for learning or planning within the framework of semi-Markov decision processes [34, 35]. In high-dimensional problems, these value functions can be approximated by neural networks as V (s, g; θ). We propose a framework with hierarchically organized deep reinforcement learning modules working at different time-scales. The model takes decisions over two levels of hierarchy – (a) a top level module (meta-controller) takes in the state and picks a new goal, and (b) a lower-level module (controller) uses both the state and the chosen goal to select actions either until the goal is reached or the episode terminates. The meta-controller then chooses another goal and steps (a-b) repeat. We train our model using stochastic gradient descent at different temporal scales to optimize expected future intrinsic (controller) and extrinsic rewards (meta-controller). We demonstrate the strength of our approach on problems with delayed rewards: (1) a discrete stochastic decision process with a long chain of states before receiving optimal extrinsic rewards and (2) a classic ATARI game (‘Montezuma’s Revenge’) with even longer-range delayed rewards where most existing state-of-art deep reinforcement learning approaches fail to learn policies in a data-efficient manner. 2 Literature Review Reinforcement Learning with Temporal Abstractions Learning and operating over different levels of temporal abstraction is a key challenge in tasks involving long-range planning. In the context of hierarchical reinforcement learning [2], Sutton et al.[34] proposed the options framework, which involves abstractions over the space of actions. At each step, the agent chooses either a onestep “primitive” action or a “multi-step” action policy (option). Each option defines a policy over actions (either primitive or other options) and can be terminated according to a stochastic function β. Thus, the traditional MDP setting can be extended to a semi-Markov decision process (SMDP) with the use of options. Recently, several methods have been proposed to learn options in real-time by using varying reward functions [35] or by composing existing options [28]. Value functions have also been generalized to consider goals along with states [21]. Our work is inspired by these papers and builds upon them. Other related work for hierarchical formulations include the MAXQ framework [6], which decomposed the value function of an MDP into combinations of value functions of smaller constituent MDPs, as did Guestrin et al.[12] in their factored MDP formulation. Hernandez and Mahadevan [13] combine hierarchies with short-term memory to handle partial observations. In the skill learning literature, Baranes et al.[1] have proposed a goal-driven active learning approach for learning skills in continuous sensorimotor spaces. In this work, we propose a scheme for temporal abstraction that involves simultaneously learning options and a control policy to compose options in a deep reinforcement learning setting. Our approach does not use separate Q-functions for each option, but instead treats the option as part of the input, similar to [21]. This has two potential advantages: (1) there is shared learning between different options, and (2) the model is scalable to a large number of options. Intrinsic Motivation The nature and origin of ‘good’ intrinsic reward functions is an open question in reinforcement learning. Singh et al. [27] explored agents with intrinsic reward structures in order to learn generic options that can apply to a wide variety of tasks. In another paper, Singh et al. [26] take an evolutionary perspective to optimize over the space of reward functions for the agent, leading to a notion of extrinsically and intrinsically motivated behavior. In the context of hierarchical RL, Goel and Huber [10] discuss a framework for sub-goal discovery using the structural aspects of a learned policy model. S¸ims¸ek et al. [24] provide a graph partitioning approach to subgoal identification. 2 Schmidhuber [22] provides a coherent formulation of intrinsic motivation, which is measured by the improvements to a predictive world model made by the learning algorithm. Mohamed and Rezende [17] have recently proposed a notion of intrinsically motivated learning within the framework of mutual information maximization. Frank et al. [9] demonstrate the effectiveness of artificial curiosity using information gain maximization in a humanoid robot. Oudeyer et al. [20] categorize intrinsic motivation approaches into knowledge based methods, competence or goal based methods and morphological methods. Our work relates to competence based intrinsic motivation but other complementary methods can be combined in future work. Object-based Reinforcement Learning Object-based representations [7, 4] that can exploit the underlying structure of a problem have been proposed to alleviate the curse of dimensionality in RL. Diuk et al. [7] propose an Object-Oriented MDP, using a representation based on objects and their interactions. Defining each state as a set of value assignments to all possible relations between objects, they introduce an algorithm for solving deterministic object-oriented MDPs. Their representation is similar to that of Guestrin et al. [11], who describe an object-based representation in the context of planning. In contrast to these approaches, our representation does not require explicit encoding for the relations between objects and can be used in stochastic domains. Deep Reinforcement Learning Recent advances in function approximation with deep neural networks have shown promise in handling high-dimensional sensory input. Deep Q-Networks and its variants have been successfully applied to various domains including Atari games [16, 15] and Go [23], but still perform poorly on environments with sparse, delayed reward signals. Cognitive Science and Neuroscience The nature and origin of intrinsic goals in humans is a thorny issue but there are some notable insights from existing literature. There is converging evidence in developmental psychology that human infants, primates, children, and adults in diverse cultures base their core knowledge on certain cognitive systems including – entities, agents and their actions, numerical quantities, space, social-structures and intuitive theories [29]. During curiositydriven activities, toddlers use this knowledge to generate intrinsic goals such as building physically stable block structures. In order to accomplish these goals, toddlers seem to construct subgoals in the space of their core knowledge. Knowledge of space can also be utilized to learn a hierarchical decomposition of spatial environments. This has been explored in Neuroscience with the successor representation, which represents value functions in terms of the expected future state occupancy. Decomposition of the successor representation have shown to yield reasonable subgoals for spatial navigation problems [5, 30]. 3 Model Consider a Markov decision process (MDP) represented by states s ∈S, actions a ∈A, and transition function T : (s, a) →s′. An agent operating in this framework receives a state s from the external environment and can take an action a, which results in a new state s′. We define the extrinsic reward function as F : (s) →R. The objective of the agent is to maximize this function over long periods of time. For example, this function can take the form of the agent’s survival time or score in a game. Agents Effective exploration in MDPs is a significant challenge in learning good control policies. Methods such as ϵ-greedy are useful for local exploration but fail to provide impetus for the agent to explore different areas of the state space. In order to tackle this, we utilize a notion of intrinsic goals g ∈G. The agent focuses on setting and achieving sequences of goals via learning policies πg in order to maximize cumulative extrinsic reward. In order to learn each πg, the agent also has a critic, which provides intrinsic rewards, based on whether the agent is able to achieve its goals (see Figure 1). Temporal Abstractions As shown in Figure 1, the agent uses a two-stage hierarchy consisting of a controller and a meta-controller. The meta-controller receives state st and chooses a goal gt ∈G, where G denotes the set of all possible current goals. The controller then selects an action at using st and gt. The goal gt remains in place for the next few time steps either until it is achieved or a terminal state is reached. The internal critic is responsible for evaluating whether a goal has been reached and provides an appropriate reward rt(g) to the controller. In this work, we make a minimal 3 External Environment agent extrinsic reward Meta Controller Controller Critic action action intrinsic reward observations goal . . . . . . . . . . Meta Controller st gt gt Controller st st+1 . . . . . . st+N st+N gt+N Q2(st, g; ✓2) Q2(st+N, gt+N; ✓2) Meta Controller Controller Controller Q1(st, a; ✓1, gt) Q1(st+1, a; ✓1, gt) Q1(st+N, a; ✓1, gt) at at+1 at+N Figure 1: (Overview) The agent receives sensory observations and produces actions. Separate DQNs are used inside the meta-controller and controller. The meta-controller looks at the raw states and produces a policy over goals by estimating the action-value function Q2(st, gt; θ2) (to maximize expected future extrinsic reward). The controller takes in states and the current goal, and produces a policy over actions by estimating the action-value function Q1(st, at; θ1, gt) to solve the predicted goal (by maximizing expected future intrinsic reward). The internal critic provides a positive reward to the controller if and only if the goal is reached. The controller terminates either when the episode ends or when g is accomplished. The meta-controller then chooses a new g and the process repeats. assumption of a binary internal reward i.e. 1 if the goal is reached and 0 otherwise. The objective function for the controller is to maximize cumulative intrinsic reward: Rt(g) = P∞ t′=t γt′−trt′(g). Similarly, the objective of the meta-controller is to optimize the cumulative extrinsic reward Ft = P∞ t′=t γt′−tft′, where ft are reward signals received from the environment. Note that the time scales for Ft and Rt are different – each ft is the accumulated external reward over the time period between successive goal selections. The discounting in Ft, therefore, is over sequences of goals and not lower level actions. This setup is similar to optimizing over the space of optimal reward functions to maximize fitness [25]. In our case, the reward functions are dynamic and temporally dependent on the sequential history of goals. Figure 1 illustrates the agent’s use of the hierarchy over subsequent time steps. Deep Reinforcement Learning with Temporal Abstractions We use the Deep Q-Learning framework [16] to learn policies for both the controller and the meta-controller. Specifically, the controller estimates the following Q-value function: Q∗ 1(s, a; g) = max πag E ∞ X t′=t γt′−trt′ | st = s, at = a, gt = g, πag = max πag E rt + γ maxat+1Q∗ 1(st+1, at+1; g) | st = s, at = a, gt = g, πag (1) where g is the agent’s goal in state s and πag is the action policy. Similarly, for the meta-controller, we have: Q∗ 2(s, g) = maxπgE t+N X t′=t ft′ + γ maxg′Q∗ 2(st+N, g′) | st = s, gt = g, πg (2) where N denotes the number of time steps until the controller halts given the current goal, g′ is the agent’s goal in state st+N, and πg is the policy over goals. It is important to note that the transitions (st, gt, ft, st+N) generated by Q2 run at a slower time-scale than the transitions (st, at, gt, rt, st+1) generated by Q1. We can represent Q∗(s, g) ≈Q(s, g; θ) using a non-linear function approximator with parameters θ. Each Q ∈{Q1, Q2} can be trained by minimizing corresponding loss functions – L1(θ1) and L2(θ2). We store experiences (st, gt, ft, st+N) for Q2 and (st, at, gt, rt, st+1) for Q1 in disjoint 4 memory spaces D1 and D2 respectively. The loss function for Q1 can then be stated as: L1(θ1,i) = E(s,a,g,r,s′)∼D1 (y1,i −Q1(s, a; θ1,i, g))2 , (3) where i denotes the training iteration number and y1,i = r + γ maxa′Q1(s′, a′; θ1,i−1, g). Following [16], the parameters θ1,i−1 from the previous iteration are held fixed when optimizing the loss function. The parameters θ1 can be optimized using the gradient: ∇θ1,iL1(θ1,i) = E(s,a,r,s′∼D1) " r + γ maxa′Q1(s′, a′; θ1,i−1, g) −Q1(s, a; θ1,i, g) ∇θ1,iQ1(s, a; θ1,i, g) # The loss function L2 and its gradients can be derived using a similar procedure. Algorithm 1 Learning algorithm for h-DQN 1: Initialize experience replay memories {D1, D2} and parameters {θ1, θ2} for the controller and meta-controller respectively. 2: Initialize exploration probability ϵ1,g = 1 for the controller for all goals g and ϵ2 = 1 for the meta-controller. 3: for i = 1, num episodes do 4: Initialize game and get start state description s 5: g ←EPSGREEDY(s, G, ϵ2, Q2) 6: while s is not terminal do 7: F ←0 8: s0 ←s 9: while not (s is terminal or goal g reached) do 10: a ←EPSGREEDY({s, g}, A, ϵ1,g, Q1) 11: Execute a and obtain next state s′ and extrinsic reward f from environment 12: Obtain intrinsic reward r(s, a, s′) from internal critic 13: Store transition ({s, g}, a, r, {s′, g}) in D1 14: UPDATEPARAMS(L1(θ1,i), D1) 15: UPDATEPARAMS(L2(θ2,i), D2) 16: F ←F + f 17: s ←s′ 18: end while 19: Store transition (s0, g, F, s′) in D2 20: if s is not terminal then 21: g ←EPSGREEDY(s, G, ϵ2, Q2) 22: end if 23: end while 24: Anneal ϵ2 and ϵ1. 25: end for Algorithm 2 : EPSGREEDY(x, B, ϵ, Q) 1: if random() < ϵ then 2: return random element from set B 3: else 4: return argmaxm∈BQ(x, m) 5: end if Algorithm 3 : UPDATEPARAMS(L, D) 1: Randomly sample mini-batches from D 2: Perform gradient descent on loss L(θ) (cf. (3)) Learning Algorithm We learn the parameters of h-DQN using stochastic gradient descent at different time scales – transitions from the controller are collected at every time step but a transition from the meta-controller is only collected when the controller terminates (i.e. when a goal is repicked or the episode ends). Each new goal g is drawn in an ϵ-greedy fashion (Algorithms 1 & 2) with the exploration probability ϵ2 annealed as learning proceeds (from a starting value of 1). In the controller, at every time step, an action is drawn with a goal using the exploration probability ϵ1,g, which depends on the current empirical success rate of reaching g. Specifically, if the success rate for goal g is > 90%, we set ϵ1,g = 0.1, else 1. All ϵ1,g values are annealed to 0.1. The model parameters (θ1, θ2) are periodically updated by drawing experiences from replay memories D1 and D2, respectively (see Algorithm 3). 5 4 Experiments (1) Discrete stochastic decision process with delayed rewards For our first experiment, we consider a stochastic decision process where the extrinsic reward depends on the history of visited states in addition to the current state. This task demonstrates the importance of goal-driven exploration in such environments. There are 6 possible states and the agent always starts at s2. The agent moves left deterministically when it chooses left action; but the action right only succeeds 50% of the time, resulting in a left move otherwise. The terminal state is s1 and the agent receives the reward of 1 when it first visits s6 and then s1. The reward for going to s1 without visiting s6 is 0.01. This is a modified version of the MDP in [19], with the reward structure adding complexity to the task (see Figure 2). s1 s2 s3 s4 s5 s6 0.5 0.5 0.5 0.5 0.5 0.5 0.5 0.5 0.5 0.5 1.0 1.0 1.0 1.0 1.0 or r = 1 r = 1/100 Figure 2: A stochastic decision process where the reward at the terminal state s1 depends on whether s6 is visited (r = 1) or not (r = 1/100). Edges are annotated with transition probabilities (Red arrow: move right, Black arrow: move left). We consider each state as a candidate goal for exploration. This enables and encourages the agent to visit state s6 (if chosen as a goal) and hence, learn the optimal policy. For each goal, the agent receives a positive intrinsic reward if and only if it reaches the corresponding state. Results We compare the performance of our approach (without deep neural networks) against Q-Learning as a baseline (without intrinsic rewards) in terms of the average extrinsic reward gained in an episode. In our experiments, all ϵ parameters are annealed from 1 to 0.1 over 50k steps. The learning rate is set to 2.5 · 10−4. Figure 3 plots the evolution of reward for both methods averaged over 10 different runs. As expected, we see that Q-Learning is unable to find the optimal policy even after 200 epochs, converging to a sub-optimal policy of reaching state s1 directly to obtain a reward of 0.01. In contrast, our approach with hierarchical Q-estimators learns to choose goals s4, s5 or s6, which statistically lead the agent to visit s6 before going back to s1. Our agent obtains a significantly higher average reward of 0.13. Reward # of visits per episode 5/18/2016 Reward.html file:///Users/tejas/Documents/deepRelationalRL/dqn/Reward.html 1/1 0 50 100 150 200 0 0.02 0.04 0.06 0.08 0.1 0.12 0.14 0.16 0.18 Export to plot.ly » Steps Baseline Our Approach 5/18/2016 State 3, State 4, State 5, State 6 | filled scatter chart made by Ardavans | plotly https://plot.ly/~ardavans/4.embed 1/1 2 4 6 8 10 12 0 0.2 0.4 0.6 0.8 1 1.2 Edit chart » Episodes (*1000) State 3 State 4 State 5 State 6 Figure 3: (left) Average reward (over 10 runs) of our approach compared to Q-learning. (right) #visits of our approach to states s3-s6 (over 1000 episodes). Initial state: s2, Terminal state: s1. Figure 3 illustrates that the number of visits to states s3, s4, s5, s6 increases with episodes of training. Each data point shows the average number of visits for each state over the last 1000 episodes. This indicates that our model is choosing goals in a way so that it reaches the critical state s6 more often. (2) ATARI game with delayed rewards We now consider ‘Montezuma’s Revenge’, an ATARI game with sparse, delayed rewards. The game requires the player to navigate the explorer (in red) through several rooms while collecting treasures. In order to pass through doors (in the top right and top left corners of the figure), the player has to first pick up the key. The player has to then climb down the ladders on the right and move left towards the key, resulting in a long sequence of actions before receiving a reward (+100) for collecting the key. After this, navigating towards the door and opening it results in another reward (+300). Basic DQN [16] achieves a score of 0 while even the best performing system, Gorila DQN [18], manages only 4.16 on average. Asynchronous actor critic methods achieve a non-zero score but require 100s of millions of training frames [15]. 6 Architecture Total extrinsic reward image (s) + goal (g) Q1(s, a; g) Linear ReLU:Conv (filter:8, ftr-maps:32, strides:4) ReLU:Linear (h=512) ReLU:Conv (filter:4, ftr-maps:64, strides:2) ReLU:Conv (filter:3, ftr-maps:64, strides:1) 5/18/2016 Reward.html file:///Users/tejas/Documents/deepRelationalRL/dqn/Reward.html 1/1 0 0.5M 1M 1.5M 2M 0 50 100 150 200 250 300 350 400 Export to plot.ly » Steps Our Approach DQN Success ratio for reaching the goal ’key’ Success % of different goals over time 5/18/2016 subgoal_6.html file:///Users/tejas/Documents/deepRelationalRL/dqn/subgoal_6.html 1/1 0 0.5M 1M 1.5M 2M 0 0.2 0.4 0.6 0.8 1 Export to plot.ly » Steps 5/18/2016 Bar graph.html file:///Users/tejas/Documents/deepRelationalRL/dqn/Bar%20graph.html 1/1 0.5M 1M 1.5M 2M 0 0.05 0.1 0.15 0.2 0.25 Export to plot.ly » Steps top-left door top-right door middle-ladder bottom-left-ladder bottom-right-ladder key Figure 4: (top-left) Architecture: DQN architecture for the controller (Q1). A similar architecture produces Q2 for the meta-controller (without goal as input). (top-right) The joint training learns to consistently get high rewards. (bottom-left) Goal success ratio: The agent learns to choose the key more often as training proceeds and is successful at achieving it. (bottom-right) Goal statistics: During early phases of joint training, all goals are equally preferred due to high exploration but as training proceeds, the agent learns to select appropriate goals such as the key and bottom-left door. Setup The agent needs intrinsic motivation to explore meaningful parts of the scene before learning about the advantage of obtaining the key. Inspired by developmental psychology literature [29] and object-oriented MDPs [7], we use entities or objects in the scene to parameterize goals in this environment. Unsupervised detection of objects in visual scenes is an open problem in computer vision, although there has been recent progress in obtaining objects directly from image or motion data [8]. In this work, we built a custom pipeline to provide plausible object candidates. Note that the agent is still required to learn which of these candidates are worth pursuing as goals. The controller and meta-controller are convolutional neural networks (Figure 4) that learn representations from raw pixel data. We use the Arcade Learning Environment [3] to perform experiments. The internal critic is defined in the space of ⟨entity1, relation, entity2⟩, where relation is a function over configurations of the entities. In our experiments, the agent learns to choose entity2. For instance, the agent is deemed to have completed a goal (and only then receives a reward) if the agent entity reaches another entity such as the door. The critic computes binary rewards using the relative positions of the agent and the goal (1 if the goal was reached). Note that this notion of relational intrinsic rewards can be generalized to other settings. For instance, in the ATARI game ‘Asteroids’, the agent could be rewarded when the bullet reaches the asteroid or if simply the ship never reaches an asteroid. In ‘Pacman’, the agent could be rewarded if the pellets on the screen are reached. In the most general case, we can potentially let the model evolve a parameterized intrinsic reward function given entities. We leave this for future work. Model Architecture and Training As shown in Figure 4, the model consists of stacked convolutional layers with rectified linear units (ReLU). The input to the meta-controller is a set of four consecutive images of size 84 × 84. To encode the goal output from the meta-controller, we append a binary mask of the goal location in image space along with the original 4 consecutive frames. This augmented input is passed to the controller. The experience replay memories D1 and D2 were set to be equal to 106 and 5 · 104 respectively. We set the learning rate to be 2.5 · 10−4, with a discount rate of 0.99. We follow a two phase training procedure – (1) In the first phase, we set the exploration parameter ϵ2 of the meta-controller to 1 and train the controller on actions. This effectively leads to pre-training the controller so that it can learn to solve a subset of the goals. (2) In the second phase, we jointly train the controller and meta-controller. 7 1 2 3 4 5 6 7 8 9 10 11 12 termination (death) goal reached goal reached Meta Controller Controller Meta Controller Controller Figure 5: Sample game play on Montezuma’s Revenge: The four quadrants are arranged in a temporal order (top-left, top-right, bottom-left and bottom-right). First, the meta-controller chooses key as the goal (illustrated in red). The controller then tries to satisfy this goal by taking a series of low level actions (only a subset shown) but fails due to colliding with the skull (the episode terminates here). The meta-controller then chooses the bottom-right ladder as the next goal and the controller terminates after reaching it. Subsequently, the meta-controller chooses the key and the top-right door and the controller is able to successfully achieve both these goals. Results Figure 4 shows reward progress from the joint training phase – it is evident that the model starts gradually learning to both reach the key and open the door to get a reward of around +400 per episode. The agent learns to choose the key more often as training proceeds and is also successful at reaching it. We observe that the agent first learns to perform the simpler goals (such as reaching the right door or the middle ladder) and then slowly starts learning the ‘harder’ goals such as the key and the bottom ladders, which provide a path to higher rewards. Figure 4 also shows the evolution of the success rate of goals that are picked. At the end of training, we can see that the ’key’, ’bottomleft-ladder’ and ’bottom-right-ladders’ are chosen increasingly more often. In order to scale-up to solve the entire game, several key ingredients are missing, such as – automatic discovery of objects from videos to aid the goal parameterization we considered, a flexible shortterm memory, or the ability to intermittently terminate ongoing options. We also show some screenshots from a test run with our agent (with epsilon set to 0.1) in Figure 5, as well as a sample animation of the run.2 References [1] A. Baranes and P.-Y. Oudeyer. Active learning of inverse models with intrinsically motivated goal exploration in robots. Robotics and Autonomous Systems, 61(1):49–73, 2013. [2] A. G. Barto and S. Mahadevan. Recent advances in hierarchical reinforcement learning. Discrete Event Dynamic Systems, 13(4):341–379, 2003. [3] M. G. Bellemare, Y. Naddaf, J. Veness, and M. Bowling. The arcade learning environment: An evaluation platform for general agents. Journal of Artificial Intelligence Research, 2012. 2Sample trajectory of a run on ’Montezuma’s Revenge’ – https://goo.gl/3Z64Ji 8 [4] L. C. Cobo, C. L. Isbell, and A. L. Thomaz. Object focused q-learning for autonomous agents. In Proceedings of AAMAS, pages 1061–1068, 2013. [5] P. Dayan. Improving generalization for temporal difference learning: The successor representation. Neural Computation, 5(4):613–624, 1993. [6] T. G. Dietterich. Hierarchical reinforcement learning with the maxq value function decomposition. J. Artif. Intell. Res.(JAIR), 13:227–303, 2000. [7] C. Diuk, A. Cohen, and M. L. Littman. An object-oriented representation for efficient reinforcement learning. In Proceedings of the International Conference on Machine learning, pages 240–247, 2008. [8] S. Eslami, N. Heess, T. Weber, Y. Tassa, K. Kavukcuoglu, and G. E. Hinton. Attend, infer, repeat: Fast scene understanding with generative models. arXiv preprint arXiv:1603.08575, 2016. [9] M. Frank, J. Leitner, M. Stollenga, A. F¨orster, and J. Schmidhuber. Curiosity driven reinforcement learning for motion planning on humanoids. Intrinsic motivations and open-ended development in animals, humans, and robots, page 245, 2015. [10] S. Goel and M. Huber. Subgoal discovery for hierarchical reinforcement learning using learned policies. In FLAIRS conference, pages 346–350, 2003. [11] C. Guestrin, D. Koller, C. Gearhart, and N. Kanodia. Generalizing plans to new environments in relational mdps. In Proceedings of International Joint conference on Artificial Intelligence, pages 1003–1010, 2003. [12] C. Guestrin, D. Koller, R. Parr, and S. Venkataraman. Efficient solution algorithms for factored mdps. Journal of Artificial Intelligence Research, pages 399–468, 2003. [13] N. Hernandez-Gardiol and S. Mahadevan. Hierarchical memory-based reinforcement learning. In Advances in Neural Information Processing Systems, pages 1047–1053, 2001. [14] J. Koutn´ık, J. Schmidhuber, and F. Gomez. Evolving deep unsupervised convolutional networks for vision-based reinforcement learning. In Proceedings of the 2014 conference on Genetic and evolutionary computation, pages 541–548. ACM, 2014. [15] V. Mnih, A. P. Badia, M. Mirza, A. Graves, T. P. Lillicrap, T. Harley, D. Silver, and K. Kavukcuoglu. Asynchronous methods for deep reinforcement learning. arXiv preprint arXiv:1602.01783, 2016. [16] V. Mnih, K. Kavukcuoglu, D. Silver, A. A. Rusu, J. Veness, M. G. Bellemare, A. Graves, M. Riedmiller, et al. Human-level control through deep reinforcement learning. Nature, 518(7540):529–533, 2015. [17] S. Mohamed and D. J. Rezende. Variational information maximisation for intrinsically motivated reinforcement learning. In Advances in Neural Information Processing Systems, pages 2116–2124, 2015. [18] A. Nair, P. Srinivasan, S. Blackwell, C. Alcicek, R. Fearon, A. De Maria, V. Panneershelvam, et al. Massively parallel methods for deep reinforcement learning. arXiv preprint arXiv:1507.04296, 2015. [19] I. Osband, C. Blundell, A. Pritzel, and B. Van Roy. Deep exploration via bootstrapped dqn. arXiv preprint arXiv:1602.04621, 2016. [20] P.-Y. Oudeyer and F. Kaplan. What is intrinsic motivation? a typology of computational approaches. Frontiers in neurorobotics, 1:6, 2009. [21] T. Schaul, D. Horgan, K. Gregor, and D. Silver. Universal value function approximators. In Proceedings of the 32nd International Conference on Machine Learning (ICML-15), pages 1312–1320, 2015. [22] J. Schmidhuber. Formal theory of creativity, fun, and intrinsic motivation (1990–2010). Autonomous Mental Development, IEEE Transactions on, 2(3):230–247, 2010. [23] D. Silver, A. Huang, C. J. Maddison, A. Guez, L. Sifre, G. van den Driessche, J. Schrittwieser, et al. Mastering the game of go with deep neural networks and tree search. Nature, 529(7587):484–489, 2016. [24] ¨O. S¸ims¸ek, A. Wolfe, and A. Barto. Identifying useful subgoals in reinforcement learning by local graph partitioning. In Proceedings of the International conference on Machine learning, pages 816–823, 2005. [25] S. Singh, R. L. Lewis, and A. G. Barto. Where do rewards come from. In Proceedings of the annual conference of the cognitive science society, pages 2601–2606, 2009. [26] S. Singh, R. L. Lewis, A. G. Barto, and J. Sorg. Intrinsically motivated reinforcement learning: An evolutionary perspective. Autonomous Mental Development, IEEE Transactions on, 2(2):70–82, 2010. [27] S. P. Singh, A. G. Barto, and N. Chentanez. Intrinsically motivated reinforcement learning. In Advances in neural information processing systems, pages 1281–1288, 2004. [28] J. Sorg and S. Singh. Linear options. In Proceedings of the 9th International Conference on Autonomous Agents and Multiagent Systems, pages 31–38, Richland, SC, 2010. [29] E. S. Spelke and K. D. Kinzler. Core knowledge. Developmental science, 10(1):89–96, 2007. [30] K. L. Stachenfeld, M. Botvinick, and S. J. Gershman. Design principles of the hippocampal cognitive map. In Advances in neural information processing systems, pages 2528–2536, 2014. [31] B. C. Stadie, S. Levine, and P. Abbeel. Incentivizing exploration in reinforcement learning with deep predictive models. arXiv preprint arXiv:1507.00814, 2015. [32] R. S. Sutton and A. G. Barto. Introduction to reinforcement learning. MIT Press Cambridge, 1998. [33] R. S. Sutton, J. Modayil, M. Delp, T. Degris, P. M. Pilarski, A. White, and D. Precup. Horde: A scalable real-time architecture for learning knowledge from unsupervised sensorimotor interaction. In The 10th International Conference on Autonomous Agents and Multiagent Systems, pages 761–768, 2011. [34] R. S. Sutton, D. Precup, and S. Singh. Between mdps and semi-mdps: A framework for temporal abstraction in reinforcement learning. Artificial intelligence, 112(1):181–211, 1999. [35] C. Szepesvari, R. S. Sutton, J. Modayil, S. Bhatnagar, et al. Universal option models. In Advances in Neural Information Processing Systems, pages 990–998, 2014. 9 | 2016 | 546 |
6,490 | Agnostic Estimation for Misspecified Phase Retrieval Models Matey Neykov Zhaoran Wang Han Liu Department of Operations Research and Financial Engineering Princeton University, Princeton, NJ 08544 {mneykov, zhaoran, hanliu}@princeton.edu Abstract The goal of noisy high-dimensional phase retrieval is to estimate an s-sparse parameter β∗∈Rd from n realizations of the model Y = (X⊤β∗)2 + ε. Based on this model, we propose a significant semi-parametric generalization called misspecified phase retrieval (MPR), in which Y = f(X⊤β∗, ε) with unknown f and Cov(Y, (X⊤β∗)2) > 0. For example, MPR encompasses Y = h(|X⊤β∗|) + ε with increasing h as a special case. Despite the generality of the MPR model, it eludes the reach of most existing semi-parametric estimators. In this paper, we propose an estimation procedure, which consists of solving a cascade of two convex programs and provably recovers the direction of β∗. Our theory is backed up by thorough numerical results. 1 Introduction In scientific and engineering fields researchers often times face the problem of quantifying the relationship between a given outcome Y and corresponding predictor vector X, based on a sample {(Yi, X⊤ i )⊤}n i=1 of n observations. In such situations it is common to postulate a linear “working” model, and search for a d-dimensional signal vector β∗satisfying the following familiar relationship: Y = X⊤β∗+ ε. (1.1) When the predictor X is high-dimensional in the sense that d ≫n, it is commonly assumed that the underlying signal β∗is s-sparse. In a certain line of applications, such as X-ray crystallography, microscopy, diffraction and array imaging1, one can only measure the magnitude of X⊤β∗but not its phase (i.e., sign in the real domain). In this case, assuming model (1.1) may not be appropriate. To cope with such applications in the high-dimensional setting, [7] proposed the thresholded Wirtinger flow (TWF), a procedure which consistently estimates the signal β∗in the following real sparse noisy phase retrieval model: Y = (X⊤β∗)2 + ε, (1.2) where one additionally knows that the predictors have a Gaussian random design X ∼N(0, Id). In the present paper, taking an agnostic point of view, we recognize that both models (1.1) and (1.2) represent an idealized view of the data generating mechanism. In reality, the nature of the data could be better reflected through the more flexible viewpoint of a single index model (SIM): Y = f(X⊤β∗, ε), (1.3) where f is an unknown link function, and it is assumed that ∥β∗∥2 = 1 for identifiability. A recent line of work on high-dimensional SIMs [25, 27], showed that under Gaussian designs, one can apply ℓ1 regularized least squares to successfully estimate the direction of β∗and its support. The crucial condition allowing for the above somewhat surprising application turns out to be: Cov(Y, X⊤β∗) ̸= 0. (1.4) While condition (1.4) is fairly generic, encompassing cases with a binary outcome, such as logistic regression and one-bit compressive sensing [5], it fails to capture the phase retrieval model (1.2). 1In such applications it is typically assumed that X ∈Cd is a complex normal random vector. In this paper for simplicity we only consider the real case X ∈Rd. 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. More generally, it is easy to see that when the link function f is even in its first coordinate, condition (1.4) fails to hold. The goal of the present manuscript is to formalize a class of SIMs, which includes the noisy phase retrieval model as a special case in addition to various other additive and non-additive models with even link functions, and develop a procedure that can successfully estimate the direction of β∗up to a global sign. Formally, we consider models (1.3) with Gaussian design that satisfy the following moment assumption: Cov(Y, (X⊤β∗)2) > 0. (1.5) Unlike (1.4), one can immediately check that condition (1.5) is satisfied by model (1.2). In §2 we give multiple examples, both abstract and concrete, of SIMs obeying this constraint. Our second moment constraint (1.5) can be interpreted as a semi-parametric robust version of phase-retrieval. Hence, we will refer to the class of models satisfying condition (1.5) as misspecified phase retrieval (MPR) models. In this point of view it is worth noting that condition (1.4) relates to linear regression in a way similar to how condition (1.5) relates to the phase retrieval model. Our motivation for studying SIMs under such a constraint can ultimately be traced to the vast sufficient dimension reduction (SDR) literature. In particular, we would like to point out [22] as a source of inspiration. Contributions. Our first contribution is to formulate a novel and easily implementable two-step procedure, which consistently estimates the direction of β∗in an MPR model. In the first step we solve a semidefinite program producing a unit vector bv, such that |bv⊤β∗| is sufficiently large. Once such a pilot estimate is available, we consider solving an ℓ1 regularized least squares on the augmented outcome eYi = (Yi −Y )X⊤ i bv, where Y is the average of Yi’s, to produce a second estimate bb, which is then normalized to obtain the final refined estimator bβ = bb/∥bb∥2. In addition to being universally applicable to MPR models, our procedure has an algorithmic advantage in that it relies solely on convex optimization, and as a consequence we can obtain the corresponding global minima of the two convex programs in polynomial time. Our second contribution is to rigorously demonstrate that the above procedure consistently estimates the direction of β∗. We prove that for a given MPR model, with high probability, one has: minη∈{−1,1}∥bβ −ηβ∗∥2 ≲ p s log d/n, provided that the sample size n satisfies n ≳s2 log d. While the same rates (with different constants) hold for the TWF algorithm of [7] in the special case of noisy phase retrieval model, our procedure provably achieves these rates over the broader class of MPR models. Lastly, we propose an optional refinement of our algorithm, which shows improved performance in the numerical studies. Related Work. The phase retrieval model has received considerable attention in the recent years by statistics, applied mathematics as well as signal processing communities. For the non-sparse version of (1.2), efficient algorithms have been suggested based on both semidefinite programs [8, 10] and non-convex optimization methods that extend gradient descent [9]. Additionally, a non-traditional instance of phase retrieval model (which also happens to be a special case of the MPR model) was considered by [11], where the authors suggested an estimation procedure originally proposed for the problem of mixed regression. For the noisy sparse version of model (1.2), near optimal solutions were achieved with a computationally infeasible program by [20]. Subsequently, a tractable gradient descent approach achieving minimax optimal rates was developed by [7]. Abstracting away from the phase retrieval or linear model settings, we note that inference for SIMs in the case when d is small or fixed, has been studied extensively in the literature [e.g., 18, 24, 26, 34, among many others]. In another line of research on SDR, seminal insights shedding light on condition (1.4) can be found in, e.g., [12, 21, 23]. The modified condition (1.5) traces roots to [22], where the authors designed a procedure to handle precisely situations where (1.4) fails to hold. More recently, there have been active developments for high-dimensional SIMs. [27] and later [31] demonstrated that under condition (1.4), running the least squares with ℓ1 regularization can obtain a consistent estimate of the direction of β∗, while [25] showed that this procedure also recovers the signed support of the direction. Excess risk bounds were derived in [14]. Very recently, [16] extended this observation to other convex loss functions under a condition corresponding to (1.4) depending implicitly on the loss function of interest. [28] proposed a non-parametric least squares with an equality ℓ1 constraint to handle simultaneous estimation of β∗as well as f. [17] considered a smoothed-out U-process type of loss function with ℓ1 regularization, and proved their approach works for a sub-class of functions satisfying condition (1.4). None of the aforementioned works on SIMs can be directly applied to tackle the MPR class (1.5). A generic procedure for estimating sparse principal eigenvectors was 2 developed in [37]. While in principle this procedure can be applied to estimate the direction in MPR models, it requires proper initialization, and in addition, it requires knowledge of the sparsity of the vector β∗. We discuss this approach in more detail in §4. Regularized procedures have also been proposed for specific choices of f and Y . For example, [36] studied consistent estimation under the model P(Y = 1|X) = (h(X⊤β∗) + 1)/2 with binary Y , where h : R 7→[−1, 1] is possibly unknown. Their procedure is based on taking pairs of differences in the outcome, and therefore replaces condition (1.4) with a different type of moment conditon. [35] considered the model Y = h(X⊤β∗) + ε with a known continuously differentiable and monotonic h, and developed estimation and inferential procedures based on the ℓ1 regularized quadratic loss, in a similar spirit to the TWF algorithm suggested by [7]. In conclusion, although there exists much prior related work, to the best of our knowledge, none of the available literature discusses the MPR models in the generality we attempt in the present manuscript. Notation. We now briefly outline some commonly used notations. Other notations will be defined as needed throughout the paper. For a (sparse) vector v = (v1, . . . , vp)⊤, we let Sv := supp(v) = {j : vj ̸= 0} denote its support, ∥v∥p denote the ℓp norm (with the usual extension when p = ∞) and v⊗2 := vv⊤is a shorthand for the outer product. With a standard abuse of notation we will denote by ∥v∥0 = |supp(v)| the cardinality of the support of v. We often use Id to denote a d × d identity matrix. For a real random variable X, define ∥X∥ψ2 = sup p≥1 p−1/2(E|X|p)1/p, ∥X∥ψ1 = sup p≥1 p−1(E|X|p)1/p. Recall that a random variable is called sub-Gaussian if ∥X∥ψ2 < ∞and sub-exponential if ∥X∥ψ1 < ∞[e.g., 32]. For any integer k ∈N we use the shorthand notation [k] = {1, . . . , k}. We also use standard asymptotic notations. Given two sequences {an}, {bn} we write an = O(bn) if there exists a constant C < ∞such that an ≤Cbn, and an ≍bn if there exist positive constants c and C such that c < an/bn < C. Organization. In §2 and §3 we introduce the MPR model class and our estimation procedure, and §3.1 is dedicated to stating the theoretical guarantees of our proposed algorithm. Simulation results are given in §4. A brief discussion is provided in §5. We defer the proofs to the appendices due to space limitations. 2 MPR Models In this section we formally introduce MPR models. In detail, we argue that the class of such models is sufficiently rich, including numerous models of interest. Motivated by the setup in the sparse noisy phase retrieval model (1.2), we assume throughout the remainder of the paper that X ∼N(0, Id). We begin our discussion with a formal definition. Definition 2.1 (MPR Models). Assume that we are given model (1.3), where X ∼N(0, Id), ε ⊥⊥X and β∗∈Rd is an s-sparse unit vector, i.e., ∥β∗∥2 = 1. We call such a model misspecified phase retrieval (MPR) model, if the link function f and noise ε further satisfy, for Z ∼N(0, 1) and K > 0, c0 := Cov(f(Z, ε), Z2) > 0, (2.1) ∥Y ∥ψ1 ≤K. (2.2) Both assumptions (2.1) and (2.2) impose moment restrictions on the random variable Y . Assumption (2.1) states that Y is positively correlated with the random variable (X⊤β∗)2, while assumption (2.2) requires Y to have somewhat light-tails. Also, as mentioned in the introduction, the unit norm constraint on the vector β∗is required for the identifiability of model (1.3). We remark that the class of MPR models is convex in the sense that if we have two MPR models f1(X⊤β∗, ε) and f2(X⊤β∗, ε), all models generated by their convex combinations λf1(X⊤β∗, ε)+(1−λ)f2(X⊤β∗, ε) (λ ∈[0, 1]) are also MPR models. It is worth noting the > direction in (2.1) is assumed without loss of generality. If Cov(Y, (X⊤β∗)2) < 0 one can apply the same algorithm to −Y . However, the knowledge of the direction of the inequality is important. In the following, we restate condition (2.1) in a more convenient way, enabling us to easily calculate the explicit value of the constant c0 in several examples. Proposition 2.2. Assume that there exists a version of the map ϕ(z) : z 7→E[f(Z, ε)|Z = z] such that ED2ϕ(Z) > 0, where D2 is the second distributional derivative of ϕ and Z ∼N(0, 1). Then the SIM (1.3) satisfies assumption (2.1) with c0 = ED2ϕ(Z). We now provide three concrete MPR models as warm up examples for the more general examples discussed in Proposition 2.3 and Remark 2.3. Consider the models: 3 Y = (X⊤β∗)2 + ε, (2.3) Y = |X⊤β∗| + ε, (2.4) Y = |X⊤β∗+ ε|, (2.5) where ε ⊥⊥X is sub-exponential noise, i.e., ∥ε∥ψ1 ≤Kε for some Kε > 0. Model (2.3) is the noisy phase retrieval model considered by [7], while models (2.4) and (2.5) were both discussed in [11], where the authors proposed a method to solve model (2.5) in the low-dimensional regime. Below we briefly explain why these models satisfy conditions (2.1) and (2.2). First, observe that in all three models we have a sum of two sub-exponential random variables, and hence by the triangle inequality it follows that the random variable Y is also sub-exponential, which implies (2.2). To understand why (2.1) holds, by applying Proposition 2.2 we have c0 = E2 = 2 > 0 for model (2.3), c0 = E2δ0(Z) = 2/ √ 2π > 0 for model (2.4), and c0 = E2δ0(Z + ε) = 2Eφ(ε) > 0 for model (2.5), where δ0(·) is the Dirac delta function centered at zero, and φ is the density of the standard normal distribution. Admittedly, calculating the second distributional derivative could be a laborious task in general. In the remainder of this section we set out to find a simple to check generic sufficient condition on the link function f and error term ε, under which both (2.1) and (2.2) hold. Before giving our result note that the condition ED2ϕ(Z) > 0 is implied whenever ϕ is strictly convex and twice differentiable. However, strictly convex functions ϕ may violate assumption (2.2) as they can inflate the tails of Y arbitrarily (consider, e.g., f(x, ε) = x4 + ε). Moreover, the functions in example (2.4) and (2.5) fail to be twice differentiable. In the following result we handle those two problems, and in addition we provide a more generic condition than convexity, which suffices to ensure the validity of (2.1). Proposition 2.3. The following statements hold. (i) Let the function ϕ defined in Proposition 2.2 be such that the map z 7→ϕ(z) + ϕ(−z) is non-decreasing on R+ 0 and and there exist z1 > z2 > 0 such that ϕ(z1) + ϕ(−z1) > ϕ(z2) + ϕ(−z2). Then (2.1) holds. (ii) A sufficient condition for (i) to hold, is that z 7→ϕ(z) is convex and sub-differentiable at every point z ∈R, and there exists a point z0 ∈R+ 0 satisfying ϕ(z0) + ϕ(−z0) > 2ϕ(0). (iii) Assume that there exist functions g1, g2 such that f(Z, ε) ≤g1(Z) + g2(ε), and g1 is essentially quadratic in the sense that there exists a closed interval I = [a, b] with 0 ∈I, such that for all z satisfying g1(z) ∈Ic we have |g1(z)| ≤Cz2 for a sufficiently large constant C > 0, and let g2(ε) be sub-exponential. Then (2.2) holds. Remark 2.4. Proposition 2.3 shows that the class of MPR models is sufficiently broad. By (i) and (ii) it immediately follows that the additive models Y = h(X⊤β∗) + ε, (2.6) where the link function h is even and increasing on R+ 0 or convex, satisfy the covariance condition (2.1) by (i) and (ii) of Proposition 2.3 respectively. If h is also essentially quadratic and ε is subexponentially distributed, using (iii) we can deduce that Y in (2.6) is a sub-exponential random variable, and hence under these restrictions model (2.6) is an MPR model. Both examples (2.3) and (2.4) take this form. Additionally, Proposition 2.3 implies that the model Y = h(X⊤β∗+ ε) (2.7) satisfies (2.1), whenever the link h is a convex sub-differentiable function, such that h(z0)+h(−z0) > 2h(0) for some z0 > 0, E|h(z + ε)| < ∞for all z ∈R and E|h(Z + ε)| < ∞. This conclusion follows because under the latter conditions the function ϕ(z) = Eh(z + ε) satisfies (ii), which is proved in Appendix C under Lemma C.1. Moreover, if it turns out that h is essentially quadratic and h(2ε) is sub-exponential, then by Jensen’s inequality we have 2h(Z +ε) ≤h(2Z)+h(2ε) and hence (iii) implies that (2.2) is also satisfied. Model (2.5) is of the type (2.7). Unlike the additive noise models (2.6), models (2.7) allow noise corruption even within the argument of the link function. On the negative side, it should be apparent that (2.1) fails to hold in cases where ϕ is an odd function, i.e., ϕ(z) = −ϕ(−z). In many such cases (e.g. when ϕ is monotone or non-constant and non-positive/nonnegative on R+), one would have Cov(Y, X⊤β∗) = E[ϕ(Z)Z] ̸= 0, and hence direct application of the ℓ1 regularized least squares algorithm is possible as we discussed in the introduction. 3 Agnostic Estimation for MPR In this section we describe and motivate our two-step procedure, which consists of a convex relaxation and an ℓ1 regularized least squares program, for performing estimation in the MPR class of models 4 described by Definition 2.1. We begin our motivation by noting that any MPR model satisfies the following inequality Cov((Y −µ)X⊤β∗, X⊤β∗) = E{(Y −µ)(X⊤β∗)2} = Cov(f(Z, ε), Z2) = c0 > 0, (3.1) where we have denoted µ := EY . This simple observation plays a major role in the motivation of our procedure. Notice that in view of condition (1.4), inequality (3.1) implies that if instead of observing Y we had observed ˘Y = g(X⊤β∗, ε) = (Y −µ)X⊤β∗. However, there is no direct way of generating the random variable ˘Y , as doing so would require the knowledge of β∗and the mean µ. Here, we propose to roughly estimate β∗by a vector bv first, use an empirical estimate Y of µ, and then obtain the ℓ1 regularized least squares estimate on the augmented variable eY = (Y −Y )X⊤bv to sharpen the convergence rate. At first glance it might appear counter-intuitive that introducing a noisy estimate of β∗can lead to consistent estimates, as the so-defined eY variable depends on the projection of X on span{β∗, bv}. Decompose bv = (bv⊤β∗)β∗+ bβ⊥, (3.2) where bβ⊥⊥β∗. To better motivate this proposal, in the following we analyze the population least squares fit, based on the augmented variable ˇY = (Y −µ)X⊤bv for some fixed unit vector bv with decomposition (3.2). Writing out the population solution for least squares yields: [EX⊗2]−1E[X ˇY ] = E[X(Y −µ)X⊤(bv⊤β∗)β∗] | {z } I1 + E[X(Y −µ)X⊤bβ⊥] | {z } I2 . (3.3) We will now argue that left hand side of (3.3) is proportional to β∗. First, we observe that I1 = c0(bv⊤β∗)β∗, since multiplying by any vector b ⊥β∗yields b⊤I1 = 0 by independence. Second, and perhaps more importantly, we have that I2 = 0. To see this, we first take a vector b ∈span{β∗, bβ⊥}⊥. Since the three variables b⊤X, Y −µ and bβ⊥X are independent, we have b⊤I2 = 0. Multiplying by β∗we have β∗⊤I2 = 0 since β∗⊤X(Y −µ) is independent of X⊤bβ⊥. Finally, multiplying by bβ⊥yields I⊤ 2 bβ⊥= 0, since (X⊤bβ⊥)2 is independent of Y −µ. (a) Initialization (b) Second Step Figure 1: An illustration of the estimates bv and bβ produced by the first and second steps of Algorithm 1. After the first step we can guarantee that the vector β∗belongs to one of two spherical caps which contain all vectors w such that |bv⊤w| ≥κ for some constant κ > 0, provided that the sample size n ≳s2 log d is sufficiently large. After the second step we can guarantee that the vector β∗belongs to one of two spherical caps in (b), which are shrinking with (n, s, d) at a faster rate. It is noteworthy to mention that the above derivation crucially relies on the fact that the Y variable was centered, and the vector bv was fixed. In what follows we formulate a pilot procedure which produces an estimate bv such that |bv⊤β∗| ≥κ > 0. A proper initialization algorithm can be achieved by using a spectral method, such as the Principal Hessian Directions (PHD) proposed by [22]. Cast into the framework of SIM, the PHD framework implies the following simple observation: Lemma 3.1. If we have an MPR model, then argmax∥v∥2=1 v⊤E[Y (X⊗2 −I)]v = ±β∗. A proof of this fact can be found in Appendix C. Lemma 3.1 encourages us to look into the following sample version maximization problem argmax∥v∥2=1,∥v∥0=sn−1v⊤Pn i=1[Yi(X⊗2 i −I)]v, (3.4) which targets a restricted (s-sparse) principal eigenvector. Unfortunately, solving such a problem is a computationally intensive task, and requires knowledge of s. Here we take a standard route of relaxing the above problem to a convex program, and solving it efficiently via semidefinite programming (SDP). A similar in spirit SDP relaxation for solving sparse PCA problems, was originally proposed by [13]. Instead of solving (3.4), define bΣ = n−1 Pn i=1 Yi(X⊗2 i −I), and solve the following convex 5 program: bA = argmaxtr(A)=1,A∈Sd + tr(bΣA) −λn Pd i,j=1|Aij|, (3.5) where Sd + is the convex cone of non-negative semidefinite matrices, and λn is a regularization parameter encouraging element-wise sparsity in the matrix A. The hopes of introducing the optimization program above are that bA will be a good first estimate of β∗⊗2. In practice it could turn out that the matrix bA is not rank one, hence we suggest taking bv as the principal eigenvector of bA. In theory we show that with high probability the matrix bA will indeed be of rank one. Observation (3.3), Lemma 3.1 and the SDP formulation motivate the agnostic two-step estimation procedure for misspecified phase retrieval in Algorithm 1. Algorithm 1 input :(Yi, Xi)n i=1: data, λn, νn: tuning parameters 1. Split the sample into two approximately equal sets S1, S2, with |S1| = ⌊n/2⌋, |S2| = ⌈n/2⌉. 2. Let bΣ := |S1|−1 P i∈S1 Yi(X⊗2 i −Id). Solve (3.5). Let bv be the first eigenvector of bA. 3. Let Y = |S2|−1 P i∈S2 Yi. Solve the following program: bb = argminb(2|S2|)−1P i∈S2((Yi −Y )X⊤ i bv −X⊤ i b)2 + νn∥b∥1. (3.6) 4. Return bβ := bb/∥bb∥2. The sample split is required to ensure that after decomposition (3.2), the vector bβ⊥and the value bv⊤β∗are independent of the remaining sample. In §3.1 we demonstrate that Algorithm 1 succeeds with optimal (in the noisy regime) ℓ2 rate p s log d/n, provided that s2 log d ≲n. The latter requirement on the sample size suffices to guarantee that the solution bA of optimization program (3.5) is rank one. Figure 1 illustrates the two steps of Algorithm 1. In addition to our main procedure, we propose an optional refinement step (Algorithm 2) in which one applies steps 3. and 4. of Algorithm 1 on the full dataset using the output vector bβ of Algorithm 1. Doing so can potentially result in additional stability and further refinements of the rate constant. Algorithm 2 Optional Refinement input :(Yi, Xi)n i=1: data, ν′ n: tuning parameter, output bβ from the Algorithm 1 5. Let Y = n−1 P i∈[n] Yi. Solve the following program: bb = argminb(2n)−1Pn i=1((Yi −Y )X⊤ i bβ −X⊤ i b)2 + ν′ n∥b∥1. (3.7) 6. Return bβ′ := bb/∥bb∥2. 3.1 Theoretical Guarantees In this section we present our main theoretical results, which consist of theoretical justification of our procedures, as well as lower bounds for certain types of SIM (1.3). To simplify the presentation for this section, we slightly change the notation and assume that the sample size is 2n and S1 = [n] and S2 = {n + 1, . . . , 2n}. Of course this abuse of notation does not restrict our analysis to only even sample size cases. Our first result shows that the optimization program (3.5) succeeds in producing a vector bv which is close to the vector β∗. Proposition 3.2. Assume that n is large enough so that s p log d/n < (1/6 −κ/4)c0/(C1 + C2) for some small but fixed κ > 0 and constants C1, C2 (depending on f and ε). Then there exists a value of λn ≍ p log d/n such that the principal eigenvector bv of bA, the solution of (3.5), satisfies |bv⊤β∗| ≥κ > 0, with probability at least 1 −4d−1 −O(n−1). Proposition 3.2 shows that the first step of Algorithm 1 narrows down the search for the direction of β∗to a union of two spherical caps (i.e., the estimate bv satisfies |bv⊤β∗| ≥κ for some constant κ > 0, see also Figure 1a). Our main result below, demonstrates that in combination with program (3.6) this suffices to recover the direction of β∗at an optimal rate with high probability. 6 Theorem 3.3. There exist values of λn, νn ≍ p log d/n and a constant R > 0 depending on f and ε, such that if s p log d/n < R and log(d) log2(n)/n = o(1), the output of Algorithm 1 satisfies: sup ∥β∗∥2=1,∥β∗∥0≤s Pβ∗ min η∈{1,−1} ∥bβ −ηβ∗∥2 > L r s log d n ≤O(d−1 ∨n−1), (3.8) where L is a constant depending solely on f and ε. We remark that although the estimation rate is of the order p s log d/n, our procedure still requires that s p log d/n is sufficiently small. This phenomenon is similar to what has been observed by [7], and it is our belief that this requirement cannot be relaxed for computationally feasible algorithms. We would further like to mention that while in bound (3.8) we control the worst case probability of failure, it is less clear whether the estimate bβ is universally consistent (i.e., whether the sup can be moved inside the probability in (3.8)). 4 Numerical Experiments In this section we provide numerical experiments based on the three models (2.3), (2.4) and (2.5) where the random variable ε ∼N(0, 1). All models are compared with the Truncated Power Method (TPM), proposed in [37]. For model (2.3) we also compare the results of our approach to the ones given by the TWF algorithm of [7]. Our setup is as follows. In all scenarios the vector β∗was held fixed at β∗= (−s−1/2, s−1/2, . . . , s−1/2 | {z } s , 0, . . . 0 | {z } d−s ). Since our theory requires that n ≳s2 log d, we have setup four different sample sizes n ≈θs2 log d, where θ ∈{4, 8, 12, 16}. We let s depend on the dimension d and we take s ≈log d. In addition to the suggested approach in Algorithm 1, we also provide results using the refinement procedure (see Algorithm 3.7). We also provide the values of two “warm” starts of our algorithm, produced by solving program (3.5) with half and full data correspondingly. It is evident that for all scenarios the second step of Algorithms 1 and 2 outperform the warm start from SDP, except in Figure 2 (b), (c), when the sample size is simply two small to for the warm start on half of the data to be accurate. All values we report are based on an average over 100 simulations. The SDP parameter was kept at a constant value (0.015) throughout all simulations, and we observed that varying this parameter had little influence on the final SDP solution. To select the νn parameter for (3.6) a pre-specified grid of parameters {ν1, . . . , νl} was selected, and the following heuristic procedure based on K-fold cross-validation was used. We divide S2 into K = 5 approximately equally sized non-intersecting sets S2 = ∪j∈[K] eSj 2. For each j ∈[K] and k ∈[l] we run (3.6) on the set ∪r∈[K],r̸=j eSr 2 with a tuning parameter νn = νk to obtain an estimate bβk,−eSj 2. Lemma 3.1 then justifies the following criteria to select the optimal index for selecting bνn = νbl where bl = argmax k∈[l] X j∈[K] X i∈eSj 2 Yi(X⊤ i bβk,−eSj 2)2. Our experience suggests this approach works well in practice provided that the values {ν1, . . . , νl} are selected within appropriate range and are of the magnitude p log d/n. Since the TPM algorithm requires an estimate of the sparsity s, we tuned it as suggested in Section 4.1.2 of [37]. In particular, for each scenario we considered the set of possible sparsities K = {s, 2s, 4s, 8s}. For each k ∈K the algorithm is ran on the first part of the data S1, to obtain an estimate bβk, and the final estimate is taken to be bβbk where bk is given by bk = argmax k∈K bβ⊤ k |S2|−1 X i∈S2 Yi(X⊗2 i −Id) bβk. The TPM is ran for 2000 iterations. In the case of phase retrieval, the TWF algorithm was also ran at a total number of 2000 iterations, using the tuning parameters originally suggested in [7]. As expected the TWF algorithm which targets the sparse phase retrieval model in particular outperforms our approach in the case when the sample size n is small, however our approach performs very comparatively to the TWF, and in fact even slightly better once we increase the sample size. It is possible that the TWF algorithm can perform better if it is ran for a longer than 2000 iterations, though in most cases it appeared to have converged to its final value. The results are visualized on Figure 2 above. The TPM algorithm, has performance comparable to that of Algorithm 1, is always 7 G G G 0.0 0.5 1.0 1.5 2.0 ||β^ −β*||2 G G G G G G G G G G G G Init Second Step Init full data Refined TPM TWF full data θ = 4 θ = 8 θ = 12 θ = 16 (a) Model (2.3), d = 200 G G 0.0 0.5 1.0 1.5 2.0 ||β^ −β*||2 G G G G G G G G Init Second Step Init full data Refined TPM θ = 4 θ = 8 θ = 12 θ = 16 (b) Model (2.4), d = 200 G G 0.0 0.5 1.0 1.5 2.0 ||β^ −β*||2 G G G G G G G G Init Second Step Init full data Refined TPM θ = 4 θ = 8 θ = 12 θ = 16 (c) Model (2.5), d = 200 G G G 0.0 0.5 1.0 1.5 2.0 ||β^ −β*||2 G G G G G G G G G G G G Init Second Step Init full data Refined TPM TWF full data θ = 4 θ = 8 θ = 12 θ = 16 (d) Model (2.3), d = 400 G G 0.0 0.5 1.0 1.5 2.0 ||β^ −β*||2 G G G G G G G G Init Second Step Init full data Refined TPM θ = 4 θ = 8 θ = 12 θ = 16 (e) Model (2.4), d = 400 G G 0.0 0.5 1.0 1.5 2.0 ||β^ −β*||2 G G G G G G G G Init Second Step Init full data Refined TPM θ = 4 θ = 8 θ = 12 θ = 16 (f) Model (2.5), d = 400 Figure 2: Simulation results for the three examples considered in §2, in two different settings for the dimension d = 200, 400. Here the parameter θ ≈ n s2 log d describes the relationship between sample size, dimension and sparsity of the signal. Algorithm 2 dominates in most settings, with exceptions when θ is too small, in which case none of the approaches provides meaningful results. worse than the estimate produced by Algorithm 2, and it needs an initialization (for the first step of Algorithm 1 is used) and further requires a rough knowledge of the sparsity s, whereas both Algorithms 1 and 2 do not require an estimate of s. 5 Discussion In this paper we proposed a two-step procedure for estimation of MPR models with standard Gaussian designs. We argued that the MPR models form a rich class including numerous additive SIMs (i.e., Y = h(X⊤β∗) + ε) with an even and increasing on R+ link function h. Our algorithm is based solely on convex optimization, and achieves optimal rates of estimation. Our procedure does require that the sample size n ≳s2 log d to ensure successful initialization. The same condition has been exhibited previously, e.g., in [7] for the phase retrieval model, and in works on sparse principal components analysis [see, e.g., 3, 15, 33]. We anticipate that for a certain subclass of MPR models, the sample size requirement n ≳s2 log d is necessary for computationally efficient algorithms to exist. We conjecture that models (2.3)-(2.5) are such models. It is however certainly not true that this sample size requirement holds for all models from the MPR class. For example, the following model can be solved efficiently by applying the Lasso algorithm, without requiring the sample size scaling n ≳s2 log d Y = sign(X⊤β∗+ c), where c < 0 is fixed. This discussion leads to the important question under what conditions of the (known) link and error distribution (f, ε) one can efficiently solve the SIM Y = f(X⊤β∗, ε) with an optimal sample complexity. We would like to investigate this issue further in our future work. Acknowledgments: The authors would like to thank the reviewers and meta-reviewers for carefully reading the manuscript and their helpful suggestions which improved the presentation. The authors would also like to thank Professor Xiaodong Li for kindly providing the code for the TWF algorithm. References [1] Adamczak, R. and Wolff, P. (2015). Concentration inequalities for non-Lipschitz functions with bounded derivatives of higher order. Probability Theory and Related Fields, 162 531–586. [2] Amini, A. A. and Wainwright, M. J. (2008). High-dimensional analysis of semidefinite relaxations for sparse principal components. In IEEE International Symposium on Information Theory. [3] Berthet, Q. and Rigollet, P. (2013). Complexity theoretic lower bounds for sparse principal component detection. In Conference on Learning Theory. [4] Bickel, P. J., Ritov, Y. and Tsybakov, A. B. (2009). Simultaneous analysis of Lasso and dantzig selector. The Annals of Statistics 1705–1732. 8 [5] Boufounos, P. T. and Baraniuk, R. G. (2008). 1-bit compressive sensing. In Annual Conference on Information Sciences and Systems. [6] Bühlmann, P. and van de Geer, S. (2011). Statistics for high-dimensional data: Methods, theory and applications. Springer. [7] Cai, T. T., Li, X. and Ma, Z. (2015). Optimal rates of convergence for noisy sparse phase retrieval via thresholded Wirtinger flow. arXiv:1506.03382. [8] Candès, E. J., Li, X. and Soltanolkotabi, M. (2015). Phase retrieval from coded diffraction patterns. Applied and Computational Harmonic Analysis, 39 277–299. [9] Candès, E. J., Li, X. and Soltanolkotabi, M. (2015). Phase retrieval via Wirtinger flow: Theory and algorithms. IEEE Transactions on Information Theory, 61 1985–2007. [10] Candès, E. J., Strohmer, T. and Voroninski, V. (2013). Phaselift: Exact and stable signal recovery from magnitude measurements via convex programming. Communications on Pure and Applied Mathematics, 66 1241–1274. [11] Chen, Y., Yi, X. and Caramanis, C. (2013). A convex formulation for mixed regression with two components: Minimax optimal rates. arXiv:1312.7006. [12] Cook, R. D. and Ni, L. (2005). Sufficient dimension reduction via inverse regression. Journal of the American Statistical Association, 100. [13] d’Aspremont, A., El Ghaoui, L., Jordan, M. I. and Lanckriet, G. R. (2007). A direct formulation for sparse PCA using semidefinite programming. SIAM review, 49 434–448. [14] Ganti, R., Rao, N., Willett, R. M. and Nowak, R. (2015). Learning single index models in high dimensions. arXiv preprint arXiv:1506.08910. [15] Gao, C., Ma, Z. and Zhou, H. H. (2014). Sparse CCA: Adaptive estimation and computational barriers. arXiv:1409.8565. [16] Genzel, M. (2016). High-dimensional estimation of structured signals from non-linear observations with general convex loss functions. arXiv:1602.03436. [17] Han, F. and Wang, H. (2015). Provable smoothing approach in high dimensional generalized regression model. arXiv:1509.07158. [18] Horowitz, J. L. (2009). Semiparametric and nonparametric methods in econometrics. Springer. [19] Laurent, B. and Massart, P. (2000). Adaptive estimation of a quadratic functional by model selection. Annals of Statistics 1302–1338. [20] Lecué, G. and Mendelson, S. (2013). Minimax rate of convergence and the performance of erm in phase recovery. arXiv:1311.5024. [21] Li, K.-C. (1991). Sliced inverse regression for dimension reduction. Journal of the American Statistical Association, 86 316–327. [22] Li, K.-C. (1992). On principal Hessian directions for data visualization and dimension reduction: Another application of Stein’s lemma. Journal of the American Statistical Association, 87 1025–1039. [23] Li, K.-C. and Duan, N. (1989). Regression analysis under link violation. The Annals of Statistics 1009– 1052. [24] McCullagh, P. and Nelder, J. (1989). Generalized linear models. Chapman & Hall/CRC. [25] Neykov, M., Liu, J. S. and Cai, T. (2016). L1-regularized least squares for support recovery of high dimensional single index models with Gaussian designs. Journal of Machine Learning Research, 17 1–37. [26] Peng, H. and Huang, T. (2011). Penalized least squares for single index models. Journal of Statistical Planning and Inference, 141 1362–1379. [27] Plan, Y. and Vershynin, R. (2015). The generalized Lasso with non-linear observations. IEEE Transactions on information theory. [28] Radchenko, P. (2015). High dimensional single index models. Journal of Multivariate Analysis, 139 266–282. [29] Raskutti, G., Wainwright, M. J. and Yu, B. (2010). Restricted eigenvalue properties for correlated Gaussian designs. Journal of Machine Learning Research, 11 2241–2259. [30] Stein, C. M. (1981). Estimation of the mean of a multivariate normal distribution. The Annals of Statistics 1135–1151. [31] Thrampoulidis, C., Abbasi, E. and Hassibi, B. (2015). Lasso with non-linear measurements is equivalent to one with linear measurements. arXiv preprint, arXiv:1506.02181. [32] Vershynin, R. (2010). Introduction to the non-asymptotic analysis of random matrices. arXiv:1011.3027. [33] Wang, Z., Gu, Q. and Liu, H. (2015). Sharp computational-statistical phase transitions via oracle computational model. arXiv:1512.08861. [34] Xia, Y. and Li, W. (1999). On single-index coefficient regression models. Journal of the American Statistical Association, 94 1275–1285. [35] Yang, Z., Wang, Z., Liu, H., Eldar, Y. C. and Zhang, T. (2015). Sparse nonlinear regression: Parameter estimation and asymptotic inference. arXiv; 1511:04514. [36] Yi, X., Wang, Z., Caramanis, C. and Liu, H. (2015). Optimal linear estimation under unknown nonlinear transform. In Advances in Neural Information Processing Systems. [37] Yuan, X.-T. and Zhang, T. (2013). Truncated power method for sparse eigenvalue problems. Journal of Machine Learning Research, 14 899–925. 9 | 2016 | 547 |
6,491 | Can Peripheral Representations Improve Clutter Metrics on Complex Scenes? Arturo Deza Dynamical Neuroscience Institute for Collaborative Biotechnologies UC Santa Barbara, CA, USA deza@dyns.ucsb.edu Miguel P. Eckstein Psychological and Brain Sciences Institute for Collaborative Biotechnologies UC Santa Barbara, CA, USA eckstein@psych.ucsb.edu Abstract Previous studies have proposed image-based clutter measures that correlate with human search times and/or eye movements. However, most models do not take into account the fact that the effects of clutter interact with the foveated nature of the human visual system: visual clutter further from the fovea has an increasing detrimental influence on perception. Here, we introduce a new foveated clutter model to predict the detrimental effects in target search utilizing a forced fixation search task. We use Feature Congestion (Rosenholtz et al.) as our non foveated clutter model, and we stack a peripheral architecture on top of Feature Congestion for our foveated model. We introduce the Peripheral Integration Feature Congestion (PIFC) coefficient, as a fundamental ingredient of our model that modulates clutter as a non-linear gain contingent on eccentricity. We show that Foveated Feature Congestion (FFC) clutter scores (r(44) = −0.82 ± 0.04, p < 0.0001) correlate better with target detection (hit rate) than regular Feature Congestion (r(44) = −0.19 ± 0.13, p = 0.0774) in forced fixation search; and we extend foveation to other clutter models showing stronger correlations in all cases. Thus, our model allows us to enrich clutter perception research by computing fixation specific clutter maps. Code for building peripheral representations is available1. 1 Introduction What is clutter? While it seems easy to make sense of a cluttered desk vs an uncluttered desk at a glance, it is hard to quantify clutter with a number. Is a cluttered desk, one stacked with papers? Or is an uncluttered desk, one that is more organized irrelevant of number of items? An important goal in clutter research has been to develop an image based computational model that outputs a quantitative measure that correlates with human perceptual behavior [19, 12, 24, 21]. Previous studies have created models that output global or regional metrics to measure clutter perception. Such measures are aimed to predict the influence of clutter on perception. However, one important aspect of human visual perception is that it is not space invariant: the fovea processes visual information with high spatial detail while regions away from the central fovea have access to lower spatial detail. Thus, the influence of clutter on perception can depend on the retinal location of the stimulus and such influences will likely interact with the information content in the stimulus. The goal of the current paper is to develop a foveated clutter model that can successfully predict the interaction between retinal eccentricity and image content in modulating the influence of clutter on perceptual behavior. We introduce a foveated mechanism based on the peripheral architecture proposed by Freeman and Simoncelli [9] and stack it into a current clutter model (Feature Congestion [23, 24]) to generate a clutter map that arises from a calculation of information loss with retinal eccentricity but is multiplicatively modulated by the original unfoveated clutter score. The new 1Piranhas Toolkit: https://github.com/ArturoDeza/Piranhas 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. Color Map Pyramid 1 Pyramid 2 Pyramid 3 Max operation Contrast Map Pyramid 1 Pyramid 2 Pyramid 3 Max operation Orientation Map Pyramid 1 Pyramid 2 Pyramid 3 Max operation Feature Congestion map Input Image Figure 1: The Feature Congestion pipeline as explained in Rosenholtz et al. [24]. A color, contrast and orientation feature map for each spatial pyramid is extracted, and the max value of each is computed as the final feature map. The Feature Congestion map is then computed by a weighted sum over each feature map. The Feature Congestion score is the mean value of the map. measure is evaluated in a gaze-contingent psychophysical experiment measuring target detection in complex scenes as a function of target retinal eccentricity. We show that the foveated clutter models that account for loss of information in the periphery correlates better with human target detection (hit rate) across retinal eccentricities than non-foveated models. Although the model is presented in the context of Feature Congestion, the framework can be extended to any previous or future clutter metrics that produce clutter scores that are computed from a global pixel-wise clutter map. 2 Previous Work Previous studies have developed general measures of clutter computed for an entire image and do not consider the space-variant properties of the human visual system. Because our work seeks to model and assess the interaction between clutter and retinal location, experiments manipulating the eccentricity of a target while observers hold fixation (gaze contingent forced fixation) are most appropriate to evaluate the model. To our knowledge there has been no systematic evaluation of fixation dependent clutter models with forced fixation target detection in scenes. In this section, we will give an overview of state-of-the-art clutter models, metrics and evaluations. 2.1 Clutter Models Feature Congestion: Feature Congestion, initially proposed by [23, 24] produces both a pixel-wise clutter score map as a well as a global clutter score for any input image or Region of Interest (ROI). Each clutter map is computed by combining a Color map in CIELab space, an orientation map [14], and a local contrast map at multiple scales through Gaussian Pyramids [5]. One of the main advantages Feature Congestion has is that each pixel-wise clutter score (Fig. 1) and global score can be computed in less than a second. Furthermore, this is one of the few models that can output a specific clutter score for any pixel or ROI in an image. This will be crucial for developing a foveated model as explained in Section 4. Edge Density: Edge Density computes a ratio after applying an Edge Detector on the input image [19]. The final clutter score is the ratio of edges to total number of pixels present in the image. The intuition for this metric is straightforward: “the more edges, the more clutter” (due to objects for example). Subband Entropy: The Subband Entropy model begins by computing N steerable pyramids [25] at K orientations across each channel from the input image in CIELab color space. Once each N × K subband is collected for each channel, the entropy for each oriented pyramid is computed pixelwise and they are averaged separately. Thus, Subband Entropy wishes to measure the entropy of each spatial frequency and oriented filter response of an image. Scale Invariance: The Scale Invariant Clutter Model proposed by Farid and Bravo [4] uses graphbased segmentation [8] at multiple k scales. A scale invariant clutter representation is given by the power law coefficient that matches the decay of number of regions with the adjusted scale parameter. 2 + + Fixation: 500 - 1000 ms (1 of 4 locations) Stimulus: 100, 200, 400, 900, 1600 ms (Remain fixated) Task 1 response (unlimited time, no feedback) Figure 2: Experiment 1: Forced Fixation Search flow diagram. A naive observer begins by fixating the image at a location that is either 1, 4, 9 or 15 deg away from the target (the observer is not aware of the possible eccentricities). After fixating on the image for a variable amount of time (100, 200, 400, 900 or 1600 ms), the observer must make a decision on target detection. ProtoObject Segmentation: ProtoObject Segmentation proposes an unsupervised metric for clutter scoring [27, 28]. The model begins by converting the image into HSV color space, and then proceeds to segment the image through superpixel segmentation [17, 16, 1]. After segmentation, mean-shift [11] is applied on all cluster (superpixel) medians to calculate the final amount of representative colors present in the image. Next, superpixels are merged with one another contingent on them being adjacent, and being assigned to the same mean-shift HSV cluster. The final score is a ratio between initial number of superpixels and final number of superpixels. Crowding Model: The Crowding Model developed by van der Berg et al. [26] is the only model to have used losses in the periphery due to crowding as a clutter metric. It decomposes the image into 3 different scales in CIELab color space. It then produces 6 different orientation maps for each scale given the luminance channel; a contrast map is also obtained by difference of Gaussians on the previously mentioned channel. All feature maps are then pooled with Gaussian kernels that grow linearly with eccentricity, KL-divergence is then computed between the pre and post pooling feature maps to get information loss coefficients, all coefficients are averaged together to produce a final clutter score. We will discuss the differences of this model to ours in the Discussion (Section 5). Texture Tiling Model: The Texture Tiling Model (TTM) is a recent perceptual model that accounts for losses in the periphery [22, 13] through psyhophysical experiments modelling visual search [7]: feature search, conjunction search, configuration search and asymmetric search. In essence, the Mongrels proposed by Rosenholtz et al. that simulate peripheral losses are very similar to the Metamers proposed by Freeman & Simoncelli [9]. We do not include comparisons to the TTM model since it requires additional psychophysics on the Mongrel versions of the images. 2.2 Clutter Metrics Global Clutter Score: The most basic clutter metric used in clutter research is the original clutter score that every model computes over the entire image. Edge Density & Proto-Object Segmentation output a ratio, while Subband Entropy and Feature Congestion output a score. However, Feature Congestion is the only model that outputs a dense pixelwise clutter map before computing a global score (Fig. 1). Thus, we use Feature Congestion clutter maps for our foveated clutter model. Clutter ROI: The second most used clutter metric is ROI (Region of Interest)-based, as shown in the work of Asher et al. [3]. This metric is of interest when an observer is engaging in target search, vs making a human judgement (Ex: “rate the clutter of the following scenes”). 2.3 Clutter Evaluations Human Clutter Judgements: Multiple studies of clutter, correlate their metrics with rankings/ratings of clutter provided by human participants. Ideally, if clutter model A is better than clutter model B, then the correlation of model scores and human rankings/ratings should be higher for model A than for model B. [28, 19, 26] 3 Response Time: Highly cluttered images will require more time for target search, hence more time to arrive to a decision of target present/absent. Under the previous assumption, a high correlation value between response time and clutter score are a good sign for a clutter model. [24, 4, 26, 3, 12] Target Detection (Hit Rate, False Alarms, Performance): In general, when engaging in target search for a fixed amount of time across all trial conditions, an observer will have a lower hit rate and higher false alarm rate for a highly cluttered image than an uncluttered image. [24, 3, 12] 3 Methods & Experiments 3.1 Experiment 1: Forced Fixation Search A total of 13 subjects participated in a Forced Fixation Search experiment where the goal was to detect a target in the subject’s periphery and identify if there was a target (person) present or absent. Participants had variable amounts of time (100, 200, 400, 900, 1600 ms) to view each clip that was presented in a random order at a variable degree of eccentricities that the subjects were not aware of (1 deg, 4 deg, 9 deg, 15 deg). They were then prompted with a Target Detection rating scale where they had to rate from a scale from 1-10 by clicking on a number reporting how confident they were on detecting the target. Participants have unlimited time for making their judgements, and they did not take more than 10 seconds per judgment. There was no response feedback after each trial. Trials were aborted when subjects broke fixation outside of a 1 deg radius around the fixation cross. Each subject did 12 sessions that consisted of 360 unique images. Every session also presented the images with aerial viewpoints from different vantage points (Example: session 1 had the target at 12 o’clock - North, while session 2 had the target at 3 o’clock - East). To control for any fixational biases, all subjects had a unique fixation point for every trial for the same eccentricity values. All images were rendered with variable levels of clutter. Each session took about an hour to complete. The target was of size 0.5 deg ×0.5 deg, 1 deg ×1 deg, 1.5 deg ×1.5 deg, depending on zoom level. For our analysis, we only used the low zoom and 100 ms time condition since there was less ceiling effects across all eccentricities. Stimuli Creation: A total of 273 videos were created each with a total duration of 120 seconds, where a ‘birds eye’ point-of-view camera rotated slowly around the center. While the video was in rotating motion, there was no relative motion between any parts of the video. From the original videos, a total of 360 × 4 different clips were created. Half of the clips were target present, while the other half were target absent. These short and slowly rotating clips were used instead of still images in our experiment, to simulate slow real movement from a pilot point of view. All clips were shown to participants in random order. Apparatus: An EyeLink 1000 system (SR Research) was used to collect Eye Tracking data at a frequency of 1000Hz. Each participant was at a distance of 76 cm from a LCD screen on gamma display, so that each pixel subtended a visual angle of 0.022 deg /px. All video clips were rendered at 1024 × 760 pixels (22.5 deg ×16.7 deg) and a frame rate of 24fps. Eye movements with velocity over 22 deg /s and acceleration over 4000 deg /s2 were qualified as saccades. Every trial began with a fixation cross, where each subject had to fixate the cross with a tolerance of 1 deg. 4 Foveated Feature Congestion A regular Feature Congestion clutter score is computed by taking the mean of the Feature Congestion map of the image or of a target ROI [12]. We propose a Foveated Feature Congestion (FFC) model that outputs a score which takes into account two main terms: 1) a regular Feature Congestion (FC) score and 2) a Peripheral Integration Feature Congestion (PIFC) coefficient that accounts the lower spatial resolution of the visual periphery that are detrimental for target detection. The first term is independent of fixation, while the second term will act as a non-linear gain that will either reduce or amplify the clutter score depending on fixation distance from the target. In this Section we will explain how to compute a PIFC, which will require creating a human-like peripheral architecture as explained in Section 4.1. We then present our Foveated Feature Congestion (FFC) clutter model in Section 4.2. Finally, we conclude by making a quantiative evaluation of the FFC (Section 4.3) in its ability to predict variations of target detectability across images and retinal eccentricity of the target. 4 3 6 9 12 15 18 21 24 0 1.0 0.9 0.8 0.7 0.6 0.5 0.4 0.3 0.2 0.1 0.0 Eccentricity in degrees away from fovea 1.0 0.9 0.8 0.7 0.6 0.5 0.4 0.3 0.2 0.1 0.0 Function value Function value Polar angle referenced from fovea 2π π 0 π/2 π/4 3π/4 5π/4 3π/2 7π/4 (a) Top: gn(e) function. Bottom: hn(θ) function. Function Value 0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 0 6 12 18 24 -6 -12 -18 -24 Eccentricity (degrees) 0 6 12 18 24 -6 -12 -18 -24 Eccentricity (degrees) (b) Peripheral Architecture. Figure 3: Construction of a Peripheral Architecture a la Freeman & Simoncelli [9] using the functions described in Section 4.1 are shown in Fig. 3(a). The blue region in the center of Fig. 3(b), represents the fovea where all information is preserved. Outer regions (in red), represent different parts of the periphery at multiple eccentricities. 4.1 Creating a Peripheral Architecture We used the Piranhas Toolkit to create a Freeman and Simoncelli [9] peripheral architecture. This biologically inspired model has been tested and used to model V1 and V2 responses in human and non-human primates with high precision for a variety of tasks [20, 10, 18, 2]. It is described by a set of pooling (linear) regions that increase in size with retinal eccentricity. Each pooling region is separable with respect to polar angle hn(θ) and log eccentricity gn(e), as described in Eq. 2 and Eq. 3 respectively. These functions are multiplied for every angle and eccentricity (θ, e) and are plotted in log polar coordinates to create the peripheral architecture as seen in Fig. 3. f(x) = cos2( π 2 ( x−(t0−1)/2 t0 )); −(1 + t0)/2 < x ≤(t0 −1)/2 1; (t0 −1)/2 < x ≤(1 −t0)/2 −cos2( π 2 ( x−(1+t0)/2 t0 )) + 1; (1 −t0)/2 < x ≤(1 + t0)/2 (1) hn(θ) = f θ −(wθn + wθ(1−t0) 2 ) wθ ; wθ = 2π Nθ ; n = 0, ..., Nθ −1 (2) gn(e) = f log(e) −[log(e0) + we(n + 1)] we ; we = log(er) −log(e0) Ne ; n = 0, ..., Ne −1 (3) The parameters we used match a V1 architecture with a scale of s = 0.25 , a visual radius of er = 24 deg, a fovea of 2 deg, with e0 = 0.25 deg 2, and t0 = 1/2. The scale defines the number of eccentricities Ne, as well as the number of polar pooling regions Nθ from ⟨0, 2π]. Although observers saw the original stimuli at 0.022 deg/pixel, with image size 1024 × 760; for modelling purposes: we rescaled all images to half their size so the peripheral architecture could fit all images under any fixation point. To preserve stimuli size in degrees after rescaling our images, our foveal model used an input value of 0.044 deg/pixel (twice the value of experimental settings). Resizing the image to half its size also allows the peripheral architecture to consume less CPU computation time and memory. 4.2 Creating a Foveated Feature Congestion Model Intuitively, a foveated clutter model that takes into account target search should score very low when the target is in the fovea (near zero), and very high when the target is in the periphery. Thus, an observer should find a target without difficulty, achieving a near perfect hit rate in the fovea, yet the observer should have a lower hit rate in the periphery given crowding effects. Note that in the 2We remove regions with a radius smaller than the foveal radius, since there is no pooling in the fovea. 5 Feature Congestion Foveated Feature Congestion Feature maps Input Image Feature Congestion Score PIFC Coefficient Foveated Feature Congestion Score Total map Difference Map PIFC map Figure 4: Foveated Feature Congestion flow diagram: In this example, the point of fixation is at 15 deg away from the target (bottom right corner of the input image). A Feature Congestion map of the image (top flow), and a Foveated Feature Congestion map (bottom flow) are created. The PIFC coefficient is computed around an ROI centered at the target (bottom flow; zoomed box). The Feature Congestion score is then multiplied by the PIFC coefficient, and the Foveated Feature Congestion score is returned. Sample PIFC’s across eccentricities can be seen in the Supplementary Material. periphery, not only should it be harder to detect a target, but it is also likely to confuse the target with another object or region affine in shape, size, texture and/or pixel value (false alarms). Under this assumption, we wish to modulate a clutter score (Feature Congestion) by a multiplicative factor, given the target and fixation location. We call this multiplicative term: the PIFC coefficient, which is defined over a 6 deg ×6 deg ROI around the location of target t. The target itself was removed when processing the clutter maps since it indirectly contributes to the ROI clutter score [3]. The PIFC aims at quantifying the information loss around the target region due to peripheral processing. To compute the PIFC, we use the before mentioned ROI, and calculate a mean difference from the foveated clutter map with respect to the original non-foveated clutter map. If the target is foveated, there should be little to no difference between a foveated map and the original map, thus setting the PIFC coefficient value to near zero. However, as the target is farther away from the fovea, the PIFC coefficient should be higher given pooling effects in the periphery. To create a foveated map, we use Feature Congestion and apply max pooling on each pooling region after the peripheral architecture has been stacked on top of the Feature Congestion map. Note that the FFC map values will depend on the fixation location as shown in Fig. 4. The PIFC map is the result of subtracting the foveated map from the unfoveated map in the ROI, and the score is a mean distance value between these two maps (we use L1-norm, L2-norm or KL-divergence). Computational details can be seen in Algorithm 1. Thus, we can resume our model in Eq. 4: FFCf,t I = FCI × PIFCf ROI(t) (4) where FCI is the Feature Congestion score [24] of image I which is computed by the mean of the Feature Congestion map RF C, and FFCf,t I is the Foveated Feature Congestion score of the image I, depending on the point of fixation f and the location of the target t. 4.3 Foveated Feature Congestion Evaluation A visualization of each image and its respective Hit Rate vs Clutter Score across both foveated and unfoveated models can be visualized in Fig 5. Qualitatively, it shows the importance of a PIFC weighting term to the total image clutter score when performing our forced fixation search experiment. Futhermore, a quantitative bootstrap correlation analysis comparing classic metrics (Image, Target, ROI) against foveal metrics (FFC1, FFC2 and FFC3) shows that hit rate vs clutter scores are greater for those foveated models with a PIFC: Image: (r(44) = −0.19 ± 0.13, p = 0.0774), Target: (r(44) = −0.03 ± 0.14, p = 0.4204), ROI: (r(44) = −0.25 ± 0.14, p = 0.0392), FFC1 (L1-norm): 6 Algorithm 1 Computation of Peripheral Integration Feature Congestion (PIFC) Coefficient 1: procedure COMPUTE PIFC OF ROI OF IMAGE I ON FIXATION f 2: Create a Peripheral Architecture A : (Nθ, Ne) 3: Offset image I in Peripheral Architecture by fixation f : (fx, fy). 4: Compute Regular Feature Congestion (RF C) map of image I 5: Set Peripheral Feature Congestion (P f F C) ⊂IR2 + map to zero. 6: Copy Feature Congestion values in fovea r0: P f F C(r0) = (RF C(r0)) 7: for each pooling region ri overlapping I, s.t. 1 ≤i ≤Nθ × Ne do 8: Get Regular Feature Congestion (FC) values in ri 9: Set Peripheral FC value to max Regular FC value: P f F C(ri) = max(RF C(ri)) 10: end for 11: Crop PIFC map to ROI: pf F C = P f F C(ROI) 12: Crop FC map to ROI: rF C = RF C(ROI) 13: Choose Distance metric D between rF C and pf F C map 14: Compute Coefficient = mean(D(rF C, pf F C)) 15: return Coefficient 16: end procedure (1) (2) (3) (4) (25) (26) (27) (28) (50) (51) (52) (1) (2) (3) (4) (25) (26) (27) (28) (50) (51) (52) (1) (2) (3) (4) (25) (26) (27)(28) (50) (51) (52) (1) (2) (3) (4) (25) (26) (27) (28) (50) (51) (52) 1 deg 4 deg 9 deg 15 deg Feature Congestion 2.00 2.25 2.50 2.75 3.00 3.25 1.0 0.9 0.8 0.7 0.6 0.5 0.4 0.3 0.2 0.1 0.0 Hit Rate (a) Feature Congestion with image ID’s (1) (2) (3) (4) (25) (26) (27) (28) (50) (51) (52) (1) (2) (3) (4) (25) (26) (27) (28) (50) (51) (52) (1) (2) (3) (4) (25) (26) (27) (28) (50) (51) (52) (1)(2) (3) (4) (25) (26) (27) (28) (50) (51) (52) 1 deg 4 deg 9 deg 15 deg Foveated Feature Congestion 0 3 6 9 12 15 1.0 0.9 0.8 0.7 0.6 0.5 0.4 0.3 0.2 0.1 0.0 Hit Rate (b) Foveated Feature Congestion with image ID’s Figure 5: Fig. 5(a) shows the current limitations of global clutter metrics when engaging in Forced Fixation Search. The same image under different eccentricities has the same clutter score yet possess a different hit rate. Our proposed foveated model (Fig. 5(b)), compensates this difference through the PIFC coefficient, and modulates each clutter score depending on fixation distance from target. (r(44) = −0.82±0.04, p < 0.0001), FFC2 (L2-norm): (r(44) = −0.79±0.06, p < 0.0001), FFC3 (KL-divergence): (r(44) = −0.82 ± 0.04, p < 0.0001). Notice that there is no difference in correlations between using the L1-norm, L2-norm or KLdivergence distance for each model in terms of the correlation with hit rate. Table ??(Supp. Mat.) also shows the highest correlation with a 6 × 6 deg ROI window across all metrics. Note that the same analysis can not be applied to false alarms, since it is indistinguishable to separate a false alarm at 1 deg from 15 deg (the target is not present, so there is no real eccentricity away from fixation). However as mentioned in the Methods section, fixation location for target absent trials in the experiment were placed assuming a location from its matching target present image. It is important that target present and absent fixations have the same distributions for each eccentricity. 5 Discussion In general, images that have low Feature Congestion have less gain in PIFC coefficients as eccentricity increases. While images with high clutter have higher gain in PIFC coefficients. Consequently, the difference of FFC between different images increases nonlinearly with eccentricity, as observed in Fig. 6. This is our main contribution, as these differences in clutter score as a function of eccentricity do not exist for regular Feature Congestion, and these differences in scores should be able to correlate with human performance in target detection. 7 (1) (2) (3) (4) (25) (26) (27) (28) (50) (51) (52) 3.00 2.75 2.50 2.25 2.00 1 4 9 15 Eccentricity Feature Congestion (a) FC vs Eccentricity. (1) (2) (3) (4) (25) (26) (27) (28) (50) (51) (52) 1 4 9 15 Eccentricity PIFC coefficient 4 3 2 1 0 5 (b) PIFC (L1-norm) vs Eccentricity. (1) (2) (3) (4) (25) (26) (27) (28) (50) (51) (52) 0 3 6 9 12 15 1 4 9 15 Eccentricity Foveated Feature Congestion (c) FFC vs Eccentricity. Figure 6: Feature Congestion (FC) vs Foveated Feature Congestion (FFC). In Fig. 6(a) we see that clutter stays constant across different eccentricities for a forced fixation task. Our FFC model (Fig. 6(c)) enriches the FC model, by showing how clutter increases as a function of eccentricity through the PIFC in Fig. 6(b). Feature Congestion Edge Density Subband Entropy ProtoObject Segmentation Dense Representation Foveated Representation Figure 7: Dense and Foveated representations of multiple models assuming a center point of fixation. Our model is also different from the van der Berg et al. [26] model since our peripheral architecture uses: a biologically inspired peripheral architecture with log polar regions that provide anisotropic pooling [15] rather than isotropic gaussian pooling as a linear function of eccentricity [26, 6]; we used region-based max pooling for each final feature map instead of pixel-based mean pooling (gaussians) per each scale (which allows for stronger differences); this final difference also makes our model computationally more efficient running at 700ms per image, vs 180s per image for the Crowding model (×250 speed up). A home-brewed Crowding Model applied to our forced fixation experiment resulted in a correlation of (r(44) = −0.23 ± 0.13, p = 0.0469), equivalent to using a non foveated metric such as regular Feature Congestion (r(44) = −0.19 ± 0.13, p = 0.0774). We finally extended our model to create foveated(FoV) versions of Edge Density(ED) [19], Subband Entropy(SE) [25, 24] and ProtoObject Segmentation(PS) [28] showing that correlations for all foveated versions are stronger than non-foveated versions for the same task: rED = −0.21, rED+F oV = −0.76, rSE = −0.19, rSE+F oV = −0.77, rP S = −0.30, but rP S+F oV = −0.74. Note that the highest foveated correlation is FC: rF C+F oV = −0.82, despite rF C = −0.19 under a L1-norm loss of the PIFC. Feature Congestion has a dense representation, is more bio-inspired than the other models, and outperforms in the periphery. See Figure 7. An overview of creating dense and foveated versions for previously mentioned models can be seen in the Supp. Material. 6 Conclusion In this paper we have introduced a peripheral architecture that shows detrimental effects of different eccentricities on target detection, that helps us model clutter for forced fixation experiments. We introduced a forced fixation experimental design for clutter research; we defined a biologically inspired peripheral architecture that pools features in V1; and we stacked the previously mentioned peripheral architecture on top of a Feature Congestion map to create a Foveated Feature Congestion (FFC) model – and we extended this pipeline to other clutter models. We showed that the FFC model better explains loss in target detection performance as a function of eccentricity through the introduction of the Peripheral Integration Feature Congestion coefficient which varies non linearly. 8 Acknowledgements We would like to thank Miguel Lago and Aditya Jonnalagadda for useful proof-reads and revisions, as well as Mordechai Juni, N.C. Puneeth, and Emre Akbas for useful suggestions. This work has been sponsored by the U.S. Army Research Office and the Regents of the University of California, through Contract Number W911NF-09-0001 for the Institute for Collaborative Biotechnologies, and that the content of the information does not necessarily reflect the position or the policy of the Government or the Regents of the University of California, and no official endorsement should be inferred. References [1] R. Achanta, A. Shaji, K. Smith, A. Lucchi, P. Fua, and S. Süsstrunk. Slic superpixels. Technical report, 2010. [2] E. Akbas and M. P. Eckstein. Object detection through exploration with a foveated visual field. arXiv preprint arXiv:1408.0814, 2014. [3] M. F. Asher, D. J. Tolhurst, T. Troscianko, and I. D. Gilchrist. Regional effects of clutter on human target detection performance. Journal of vision, 13(5):25–25, 2013. [4] M. J. Bravo and H. Farid. A scale invariant measure of clutter. Journal of Vision, 8(1):23–23, 2008. [5] P. J. Burt and E. H. Adelson. The laplacian pyramid as a compact image code. Communications, IEEE Transactions on, 31(4):532–540, 1983. [6] R. Dubey, C. S. Soon, and P.-J. B. Hsieh. A blurring based model of peripheral vision predicts visual search performances. Journal of Vision, 14(10):935–935, 2014. [7] M. P. Eckstein. Visual search: A retrospective. Journal of Vision, 11(5):14–14, 2011. [8] P. F. Felzenszwalb and D. P. Huttenlocher. Efficient graph-based image segmentation. International Journal of Computer Vision, 59(2):167–181, 2004. [9] J. Freeman and E. P. Simoncelli. Metamers of the ventral stream. Nature neuroscience, 14(9):1195–1201, 2011. [10] J. Freeman, C. M. Ziemba, D. J. Heeger, E. P. Simoncelli, and J. A. Movshon. A functional and perceptual signature of the second visual area in primates. Nature neuroscience, 16(7):974–981, 2013. [11] K. Fukunaga and L. D. Hostetler. The estimation of the gradient of a density function, with applications in pattern recognition. Information Theory, IEEE Transactions on, 21(1):32–40, 1975. [12] J. M. Henderson, M. Chanceaux, and T. J. Smith. The influence of clutter on real-world scene search: Evidence from search efficiency and eye movements. Journal of Vision, 9(1):32–32, 2009. [13] S. Keshvari and R. Rosenholtz. Pooling of continuous features provides a unifying account of crowding. Journal of Vision, 16(39), 2016. [14] M. S. Landy and J. R. Bergen. Texture segregation and orientation gradient. Vision research, 31(4):679–691, 1991. [15] D. M. Levi. Visual crowding. Current Biology, 21(18):R678–R679, 2011. [16] A. Levinshtein, A. Stere, K. N. Kutulakos, D. J. Fleet, S. J. Dickinson, and K. Siddiqi. Turbopixels: Fast superpixels using geometric flows. Pattern Analysis and Machine Intelligence, IEEE Transactions on, 31(12):2290–2297, 2009. [17] M.-Y. Liu, O. Tuzel, S. Ramalingam, and R. Chellappa. Entropy rate superpixel segmentation. In Computer Vision and Pattern Recognition (CVPR), 2011 IEEE Conference on, pages 2097–2104. IEEE, 2011. [18] J. A. Movshon and E. P. Simoncelli. Representation of naturalistic image structure in the primate visual cortex. In Cold Spring Harbor symposia on quantitative biology, volume 79, pages 115–122. Cold Spring Harbor Laboratory Press, 2014. [19] A. Oliva, M. L. Mack, M. Shrestha, and A. Peeper. Identifying the perceptual dimensions of visual complexity of scenes. [20] J. Portilla and E. P. Simoncelli. A parametric texture model based on joint statistics of complex wavelet coefficients. International Journal of Computer Vision, 40(1):49–70, 2000. [21] R. Pramod and S. Arun. Do computational models differ systematically from human object perception? In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pages 1601–1609, 2016. [22] R. Rosenholtz, J. Huang, A. Raj, B. J. Balas, and L. Ilie. A summary statistic representation in peripheral vision explains visual search. Journal of vision, 12(4):14–14, 2012. [23] R. Rosenholtz, Y. Li, J. Mansfield, and Z. Jin. Feature congestion: a measure of display clutter. In Proceedings of the SIGCHI conference on Human factors in computing systems, pages 761–770. ACM, 2005. [24] R. Rosenholtz, Y. Li, and L. Nakano. Measuring visual clutter. Journal of vision, 7(2):17–17, 2007. [25] E. P. Simoncelli and W. T. Freeman. The steerable pyramid: A flexible architecture for multi-scale derivative computation. In icip, page 3444. IEEE, 1995. [26] R. van den Berg, F. W. Cornelissen, and J. B. Roerdink. A crowding model of visual clutter. Journal of Vision, 9(4):24–24, 2009. [27] C.-P. Yu, W.-Y. Hua, D. Samaras, and G. Zelinsky. Modeling clutter perception using parametric protoobject partitioning. In Advances in Neural Information Processing Systems, pages 118–126, 2013. [28] C.-P. Yu, D. Samaras, and G. J. Zelinsky. Modeling visual clutter perception using proto-object segmentation. Journal of vision, 14(7):4–4, 2014. 9 | 2016 | 548 |
6,492 | Proximal Deep Structured Models Shenlong Wang University of Toronto slwang@cs.toronto.edu Sanja Fidler University of Toronto fidler@cs.toronto.edu Raquel Urtasun University of Toronto urtasun@cs.toronto.edu Abstract Many problems in real-world applications involve predicting continuous-valued random variables that are statistically related. In this paper, we propose a powerful deep structured model that is able to learn complex non-linear functions which encode the dependencies between continuous output variables. We show that inference in our model using proximal methods can be efficiently solved as a feedfoward pass of a special type of deep recurrent neural network. We demonstrate the effectiveness of our approach in the tasks of image denoising, depth refinement and optical flow estimation. 1 Introduction Many problems in real-world applications involve predicting a collection of random variables that are statistically related. Over the past two decades, graphical models have been widely exploited to encode these interactions in domains such as computer vision, natural language processing and computational biology. However, these models are shallow and only a log linear combination of hand-crafted features is learned [34]. This limits the ability to learn complex patterns, which is particularly important nowadays as large amounts of data are available, facilitating learning. In contrast, deep learning approaches learn complex data abstractions by compositing simple nonlinear transformations. In recent years, they have produced state-of-the-art results in many applications such as speech recognition [17], object recognition [21], stereo estimation [38], and machine translation [33]. In some tasks, they have been shown to outperform humans, e.g., fine grained categorization [7] and object classification [15]. Deep neural networks are typically trained using simple loss functions. Cross entropy or hinge loss are used when dealing with discrete outputs, and squared loss when the outputs are continuous. Multi-task approaches are popular, where the hope is that dependencies of the output will be captured by sharing intermediate layers among tasks [9]. Deep structured models attempt to learn complex features by taking into account the dependencies between the output variables. A variety of methods have been developed in the context of predicting discrete outputs [7, 3, 31, 39]. Several techniques unroll inference and show how the forward and backward passes of these deep structured models can be expressed as a set of standard layers [1, 14, 31, 39]. This allows for fast end-to-end training on GPUs. However, little to no attention has been given to deep structured models with continuous valued output variables. One of the main reasons is that inference (even in the shallow model) is much less well studied, and very few solutions exist. An exception are Markov random fields (MRFs) with Gaussian potentials, where exact inference is possible (via message-passing) if the precision matrix is positive semi-definite and satisfies the spectral radius condition [36]. A family of popular approaches convert the continuous inference problem into a discrete task using particle methods [18, 32]. Specific solvers have also been designed for certain types of potentials, e.g. polynomials [35] and piecewise convex functions [37]. 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. Proximal methods are a popular solution to perform inference in continuous MRFs when the potentials are non-smooth and non-differentiable functions of the outputs [26]. In this paper, we show that proximal methods are a special type of recurrent neural networks. This allows us to efficiently train a wide family of deep structured models with continuous output variables end-to-end on the GPU. We show that learning can simply be done via back-propagation for any differentiable loss function. We demonstrate the effectiveness of our algorithm in the tasks of image denoising, depth refinement and optical flow and show superior results over competing algorithms on these tasks. 2 Proximal Deep Structured Networks In this section, we first introduce continuous-valued deep structured models and briefly review proximal methods. We then propose proximal deep structured models and discuss how to do efficient inference and learning in these models. Finally we discuss the relationship with previous work. 2.1 Continuous-valued Deep Structured Models Given an input x ∈X, let y = (y1, ..., yN) be the set of random variables that we are interested in predicting. The output space is a product space of all the elements: y ∈Y = QN i=1 Yi, and the domain of each individual variable yi is a closed subset in real-valued space, i.e. Yi ⊂R. Let E(x, y; w) : X × Y × RK →R be an energy function which encodes the problem that we are interested in solving. Without loss of generality we assume that the energy decomposes into a sum of functions, each depending on a subset of variables E(x, y; w) = X i fi(yi, x; wu) + X α fα(yα, x; wα) (1) where fi(yi; x, w) : Yi × X →R is a function that depends on a single variable (i.e., unary term) and fα(yα) : Yα × X →R depends on a subset of variables yα = (yi)i∈α defined on a domain Yα ⊂Y. Note that, unlike standard MRF models, the functions fi and fα are non-linear functions of the parameters. The energy function is parameterized in terms of a set of weights w, and learning aims at finding the value of these weights which minimizes a loss function. Given an input x, inference aims at finding the best configuration by minimizing the energy function: y∗= arg min y∈Y X i fi(yi, x; wu) + X α fα(yα, x; wα) (2) Finding the best scoring configuration y∗is equivalent to maximizing the posteriori distribution: p(y|x; w) = 1 Z(x;w) exp(−E(x, y|w)), with Z(x; w) the partition function. Standard multi-variate deep networks (e.g., FlowNet [11]) have potential functions which depend on a single output variable. In this simple case, inference corresponds to a forward pass that predicts the value of each variable independently. This can be interpreted as inference in a graphical model with only unary potentials fi. In the general case, performing inference in MRFs with continuous variables involves solving a very challenging numerical optimization problem. Depending on the structure and properties of the potential functions, various methods have been proposed. For instance, particle methods perform approximate inference by performing message passing on a series of discrete MRFs [18, 32]. Exact inference is possible for a certain type of MRFs, i.e., Gaussian MRFs with positive semidefinite precision matrix. Efficient dedicated algorithms exist for a restricted family of functions, e.g., polynomials [35]. If certain conditions are satisfied, inference is often tackled by a group of algorithms called proximal methods [26]. In this section, we will focus on this family of inference algorithms and show that they are a particular type of recurrent net. We will use this fact to efficiently train deep structured models with continuous outputs. 2.2 A Review on Proximal Methods Next, we briefly discuss proximal methods, and refer the reader to [26] for a thorough review. Proximal algorithms are very generally applicable, but they are particularly successful at solving non-smooth, non-differentiable, or constrained problems. Their base operation is evaluating the proximal operator of a function, which involves solving a small convex optimization problem that 2 often admits a closed-form solution. In particular, the proximal operator proxf(x0) : R →R of a function is defined as proxf(x0) = arg min y (y −x0)2 + f(y) If f is convex, the fixed points of the proximal operator of f are precisely the minimizers of f. In other words, proxf(x∗) = x∗iff x∗minimizes f. This fix-point property motivates the simplest proximal method called the proximal point algorithm which iterates x(n+1) = proxf(x(n)). All the proximal algorithms used here are based on this fix-point property. Note that even if the function f(·) is not differentiable (e.g., ℓ1 norm) there might exist a closed-form or easy to compute proximal operator. While the original proximal operator was designed for the purpose of obtaining the global optimum in convex optimization, recent work has shown that proximal methods work well for non-convex optimization as long as the proximal operator exists [20, 30, 5]. For multi-variate optimization problems the proximal operator might not be trivial to obtain (e.g., when having high-order potentials). In this case, a widely used solution is to decompose the highorder terms into small problems that can be solved through proximal operators. Examples of this family of algorithms are half-quadratic splitting [13], alternating direction method of multipliers [12] and primal-dual methods [2] . In this work, we focus on the non-convex multi-variate case. 2.3 Proximal Deep Structured Models In order to apply proximal algorithms to tackle the inference problem defined in Eq. (2), we require the energy functions fi and fα to satisfy the following conditions: 1. There exist functions hi and gi such that fi(yi, x; w) = gi(yi, hi(x, w)), where gi is a distance function 1; 2. There exists a closed-form proximal operator for gi(yi, hi(x; w)) wrt yi. 3. There exist functions hα and gα such that fα(yα, x; w) can be re-written as fα(yα, x; w) = hα(x; w)gα(wT αyα). 4. There exists a proximal operator for either the dual or primal form of gα(·). A fairly general family of deep structured models satisfies these conditions. Our experimental evaluation will demonstrate the applicability in a wide variety of tasks including depth refinement, image denoising as well as optical flow. If our potential functions satisfy the conditions above, we can rewrite our objective function as follows: E(x, y; w) = X i gi(yi, hi(x; w)) + X α hα(x; w)gα(wT αyα) (3) In this paper, we make the important observation that each iteration of most existing proximal solvers contain five sub-steps: (i) compute the locally linear part; (ii) compute the proximal operator proxgi; (iii) deconvolve; (iv) compute the proximal operator proxgα; (v) update the result through a gradient descent step. Due to space restrictions, we show primal-dual solvers in this section, and refer the reader to the supplementary material for ADMM, half-quadratic splitting and the proximal gradient method. The general idea of primal dual solvers is to introduce auxiliary variables z to decompose the highorder terms. We can then minimize z and y alternately through computing their proximal operator. In particular, we can transform the primal problem in Eq. (3) into the following saddle point problem min y∈Y max z∈Z X i gi(yi, hi(x, wu)) − X α hα(x, w)g∗ α(zα) + X α hα(x, w)⟨wT αyα, zα⟩ (4) where g∗ α(·) is the convex conjugate of gα(·): g∗ α(z∗) = sup{⟨z∗, z⟩−gα(z)|z ∈Z} and the convex conjugate of g∗ α is gα itself, if gα(·) is convex. 1A function g : Y × Y →[0, ∞) is called a distance function iff it satisfies the condition of non-negativity, identity of indisernibles, symmetry and triangle inequality. 3 Figure 1: The whole architecture (top) and one iteration block (bottom) of our proximal deep structured model. The primal-dual method solves the problem in Eq. (4) by iterating the following steps: (i) fix y and minimize the energy wrt z; (ii) fix z and minimize the energy wrt y; (iii) conduct a Nesterov extrapolation gradient step. These iterative computation steps are: z(t+1) α = proxg∗α(z(t) α + σρ hα(x;w)wT α ¯y(t) α ) y(t+1) i = proxgi,hi(x,w)(y(t) i − στ hα(x;w)w∗T ·,i z(t+1)) ¯y(t+1) i = y(t+1) i + σex(y(t+1) i −y(t) i ) (5) where y(t) is the solution at the t-th iteration, z(t) is an auxiliary variable and h(x, wu) is the deep unary network. Note that different functions gi and gα in (3) have different proximal operators. It is not difficult to see that the inference process in Eq. (5) can be written as a feed-forward pass in a recurrent neural network by stacking multiple computation blocks. In particular, the first step is a convolution layer and the third step can be considered as a deconvolution layer sharing weights with the first step. The proximal operators are non-linear activation layers and the gradient descent step is a weighted sum. We also rewrite the scalar multiplication as a 1 × 1 convolution. We refer the reader to Fig. 1 for an illustration. The lower figure depicts one iteration of inference while the whole inference process as a recurrent net is shown in the top figure. Note that the whole inference process has two stages: first we compute the unaries h(x; wu) with a forward pass. Then we perform MAP inference through our recurrent network. The first non-linearity for the primal dual method is the proximal operator of the dual function of fα. This changes for other types of proximal methods. In the case of the alternating direction method of multipliers (ADMM) the nonlinearity corresponds to the proximal operator of fα; for half-qudratic splitting it is the proximal operator of fα’s primal form while the second non linearity is a least-squares solver; if fi or fα is reduced to a quadratic function of y, the algorithm is simplified, as the proximal operator of a quadratic function is a linear function [5]. We refer the reader to the supplementary material for more details on other proximal methods. 2.4 Learning Given training pairs composed of inputs {xn}N n=1 and their corresponding output {ygt n }N n=1, learning aims at finding parameters which minimizes a regularized loss function: w∗= arg min w X n ℓ(y∗ n, ygt n ) + γr(w) where ℓ(·) is the loss, r(·) is a regularizer of the weight (we use ℓ2-norm in practice), y∗ n is the minimizer of Eq. (3) for the n-th example and γ is a scalar. Given the conditions that both proxfi and proxgα (or proxg∗α) are sub-differentiable wrt. w and y, back-propagation can be used to compute the gradient efficiently. We refer the reader to Fig. 2 for an illustration of our learning algorithm. Parameters such as the gradient steps σρ, στ, σex in Eq. (5) are considered hyper-parameters in proximal methods and are typically manually set. In contrast, we can learn them as they are 1 × 1 convolution weights. 4 Algorithm: Learning Continuous-Valued Deep Structured Models Repeat until stopping criteria 1. Forward pass to compute hi(x, w) and hα(x, w) 2. Compute y∗i via forward pass in Eq. (5) 3. Compute the gradient via backward pass 4. Parameter update Figure 2: Algorithm for learning proximal deep structured models. Non-shared weights: The weights and gradient steps for high-order potentials are shared among all the iteration blocks in the inference network, which guarantees the feed-forward pass to explicitly minimize the energy function in Eq. (2). In practice we found that by removing the weight-sharing and fixed gradient step constraints, we can give extra flexibility to our model, boosting the final performance. This observation is consistent with the findings of shrinkage field [30] and inference machines [27]. Multi-loss: Intermediate layer outputs y(t) should gradually converge towards the final output. Motivated by this fact, we include a loss over the intermediate computations to accelerate convergence. 2.5 Discussion and Related Work Our approach can be considered as a continuous-valued extension of deep structured models [3, 31, 39]. Unlike previous methods where the output lies in a discrete domain and inference is conducted through a specially designed message passing layer, the output of the proposed method is in continuous domain and inference is done by stacking convolution and non-linear activation layers. Without deep unary potentials, our model is reduced to a generalized version of field-of-experts [28]. The idea of stacking shrinkage functions and convolutions as well as learning iteration-specific weights was exploited in the learning iterative shrinkage algorithm (LISTA) [14]. LISTA can be considered as a special case of our proposed model with sparse coding as the energy function and proximal gradient as the inference algorithm. Our approach is also closely related to the recent structured prediction energy networks (SPEN) [1], where our unary network is analogous to the feature net in SPEN and the whole energy model is analogous to the energy net. Both SPEN and our proposed method can be considered as a special case of optimization-based learning [8]. However, SPEN utilizes plain gradient descent for inference while our network is proximal algorithm motivated. Previous methods have tried to learn multi-variate regression networks for optical flow [11] and stereo [24]. But none of these approaches model the interactions between output variables. Thus, they can be considered a special case of our model, where only unary functions fi are present. 3 Experiments We demonstrate the effectiveness of our approach in three different applications: image denoising, depth refinement and optical flow estimation. We employ mxnet [4] with CUDNNv4 acceleration to implement the networks, which we train end-to-end. Our experiments are conducted on a Xeon 3.2 Ghz machine with a Titan X GPU. 3.1 Image Denoising We first evaluate our method for the task of image denoising (i.e., shallow unary) using the BSDS image dataset [23]. We corrupt each image with Gaussian noise with standard deviation σ = 25. We use the energy function typically employed for image denoising: y∗= arg min y∈Y X i ∥yi −xi∥2 2 + λ X α ∥wT ho,αyα∥1 (6) According to the primal dual algorithm, the activation function for the first nonlinearity is the proximal operator of the dual function of the ℓ1-norm: prox∗ ρ(z) = min(|z|, 1)·sign(z), which is the projection onto an ℓ∞-norm ball. In practice we encode this function as prox∗ ρ(z) = max(min(z, 1), −1). The 5 BM3D [6] EPLL [40] LSSC [22] CSF [30] RTF [29] Ours Ours GPU PSNR 28.56 28.68 28.70 28.72 28.75 28.79 28.79 Time (second) 2.57 108.72 516.48 5.10 69.25 0.23 0.011 Table 1: Natural Image Denoising on BSDS dataset [23] with noise variance σ = 25. 3 × 3 5 × 5 7 × 7 16 28.43 28.57 28.68 32 28.48 28.64 28.76 64 28.49 28.68 28.79 Table 2: Performance of the proposed model with different hyper-parameters Figure 3: Qualitative results for image denoising. Left to right: noisy input, ground-truth, our result. second nonlinearity is the proximal operator of the primal function of the ℓ2-norm, which is a weighted sum: proxℓ2(y, λ) = x+λy 1+λ . For training, we select 244 images, following the configuration of [30]. We randomly cropped 128 × 128 clean patches from the training images and obtained the noisy input by adding random noise. We use mean square error as the loss function and set a weight decay strength of 0.0004 for all settings. Note that for all the convolution and deconvolution layers, the bias is set to zero. MSRA initialization [16] is used for the convolution parameters and the initial gradient step for each iteration is set to be 0.02. We use adam [19] with a learning rate of t = 0.02 and hyper-parameters β1 = 0.9 and β2 = 0.999 as in Kingma et al. [19]. The learning rate is divided by 2 every 50 epoch, and we use a mini-batch size of 32. We compare against a number of recent state-of-the-art techniques [6, 40, 22, 30, 29]. 2 The Peak Signal-to-Noise Ratio (PSNR) is used as a performance measure. As shown in Tab. 1 our proposed method outperforms all methods in terms of accuracy and speed. The second best performing method is RTF [29], while being two orders of magnitude slower than our approach. Our GPU implementation achieves real-time performance with more than 90 frames/second. Note that a GPU version of CSF is reported to run at 0.92s on a 512 × 512 image on a GTX 480 [30]. However, since GPU implementation is not available online, we cannot make proper comparisons. Tab. 2 shows performance with different hyper-parameters (filter size, number of filters per each layer). As we can see, larger receptive fields and more convolution filters slightly boost the performance. Fig. 3 depicts the qualitative results of our model for the denoising task. 3.2 Depth Refinement Due to specularities and intensity changes of structured light imaging, the sensor’s output depth is often noisy. Thus, refining the depth to generate a cleaner, more accurate depth image is an important task. We conduct the depth refinement experiment on the 7 Scenes dataset [25]. We follow the configuration of [10], where the ground-truth depth was computed using KinectFusion [25]. The noise [10] has a Poisson-like distribution and is depth-dependent, which is very different from the image denoising experiment which contained Gaussian noise. We use the same architecture as for the task of natural image denoising. The multi-stage mean square error is used as loss function and the weight decay strength is set to be 0.0004. Adam (β1 = 0.9 and 2We chose the model with the best performance for each competing algorithm. For the CSF method, we use CSF5 7×7; for RTF we use RTF5; for our method, we pick 7 × 7 × 64 high-order structured network. 6 Figure 4: Qualitative results for depth refinement. Left to right: input, ground-truth, wiener filter, bilateral filter, BM3D, Filter Forest, Ours. Wiener Bilateral LMS BM3D [6] FilterForest [10] Ours PSNR 32.29 30.95 24.37 35.46 35.63 36.31 Table 3: Performance of depth refinement on dataset [10] Figure 5: Optical flow: Left to right: first and second input, ground-truth, Flownet [11], ours. β2 = 0.999) is used as the optimizer with a learning rate of 0.01. Data augmentation is used to avoid overfitting, including random cropping, flipping and rotation. We used a mini-batch size of 16. We train our model on 1000 frames of the Chess scene and test on the other scenes. PSNR is used to evaluate the performance. As shown in Tab. 3, our approach outperforms all competing algorithms. This shows that our deep structured network is able to handle non-additive non-Gaussian noise. Qualitative results are shown in Fig. 4. Compared to the competing approaches, our method is able to recover better depth estimates particularly along the depth discontinuities. 3.3 Optical Flow We evaluate the task of optical flow estimation on the Flying Chairs dataset [11]. The size of training images is 512 × 384. We formulate the energy as follows: y∗= arg min y∈Y X i ∥yi −fi(xl, xr; wu)∥1 + λ X α ∥wT ho,αyα∥1 (7) where fi(xl, xr; wu) is a Flownet model [11], is a fully-convolutional encoder-decoder network that predicts 2D optical flow per pixel. It has 11 encoding layers and 11 deconv layers with skip connections. xl and xr are the left and right input images respectively and y is the desired optical flow output. Note that we use the ℓ1-norm for both, the data and the regularization term. The first nonlinearity activation function is the proximal operator of the ℓ1-norm’s dual function: prox∗ ρ(z) = min(|z|, 1) · sign(z), and the second non-linear activation function is the proximal operator of the ℓ1-norm’s primal form: proxτ,x(y, λ) = x −min(|x −y|, λ) · sign(x), which is a soft shrinkage function [26]. 7 Flownet Flownet + TV-l1 Our proposed End-point-error 4.98 4.96 4.91 Table 4: Performance of optical flow on Flying chairs dataset [11] We build a deep structured model with 5 iteration blocks. Each iteration block has 32 convolution filters of size 7 × 7 for both the convolution and deconvolution layers, which results in 10 convolution/deconv layers and 10 non-linearities. The multi-stage mean square error is used as the loss function and the weight decay strength is set to be 0.0004. Training is conducted on the training subset of the Flying Chairs dataset. Our unary model is initialized with a pre-trained Flownet parameters. The high-order term is initialized with MSRA random initialization [16]. The hyper-parameter λ in this experiment is pre-set to be 10. We use random flipping, cropping and color-tuning for data augmentation, and employ the adam optimizer with the same configuration as before (β1 = 0.9 and β2 = 0.999) with a learning rate t = 0.005. The learning rate is divided by 2 every 10 epoch and the mini-batch size is set to be 12. We evaluate all approaches on the test set of the Flying chairs dataset. End-point error is used as a measure of performance. The unary-only model (i.e. plain flownet) is used as baseline and we also compare against a plain TV-l1 model with four pre-set gradient operators as post-processing. As shown in Tab. 4 our method outperforms all the baselines. From Fig. 5 we can see that our method is less noisy than Flownet’s output and better preserves the boundaries. Note that our current model is isotropic. In order to further boost the performance, incorporating anisotropic filtering like bilateral filtering is an interesting future direction. 4 Conclusion We have proposed a deep structured model that learns non-linear functions encoding complex dependencies between continuous output variables. We have showed that inference in our model using proximal methods can be efficiently solved as a feed-foward pass on a special type of deep recurrent neural network. We demonstrated our approach in the tasks of image denoising, depth refinement and optical flow. In the future we plan to investigate other proximal methods and a wider variety of applications. References [1] David Belanger and Andrew McCallum. Structured prediction energy networks. In ICML, 2016. [2] A. Chambolle and T. Pock. A first-order primal-dual algorithm for convex problems with applications to imaging. JMIV, 2011. [3] L. Chen, A. Schwing, A. Yuille, and R. Urtasun. Learning deep structured models. In ICML, 2015. [4] T. Chen, M. Li, Y. Li, M. Lin, N. Wang, M. Wang, T. Xiao, B. Xu, C. Zhang, and Z. Zhang. Mxnet: A flexible and efficient machine learning library for heterogeneous distributed systems. arXiv, 2015. [5] Y. Chen, W. Yu, and T. Pock. On learning optimized reaction diffusion processes for effective image restoration. In CVPR, 2015. [6] K. Dabov, A. Foi, V. Katkovnik, and K. Egiazarian. Image denoising by sparse 3-d transform-domain collaborative filtering. TIP, 2007. [7] J. Deng, N. Ding, Y. Jia, A. Frome, K. Murphy, S. Bengio, Y. Li, H. Neven, and H. Adam. Large-scale object classification using label relation graphs. In ECCV. 2014. [8] Justin Domke. Generic methods for optimization-based modeling. In AISTATS, 2012. [9] D. Eigen and R. Fergus. Predicting depth, surface normals and semantic labels with a common multi-scale convolutional architecture. In ICCV, 2015. [10] S. Fanello, C. Keskin, P. Kohli, S. Izadi, J. Shotton, A. Criminisi, U. Pattacini, and T. Paek. Filter forests for learning data-dependent convolutional kernels. In CVPR, 2014. [11] P. Fischer, A. Dosovitskiy, E. Ilg, P. Häusser, C. Hazırba¸s, V. Golkov, P. van der Smagt, D. Cremers, and T. Brox. Flownet: Learning optical flow with convolutional networks. In CVPR, 2015. 8 [12] D. Gabay and B. Mercier. A dual algorithm for the solution of nonlinear variational problems via finite element approximation. Computers & Mathematics with Applications, 1976. [13] D. Geman and C. Yang. Nonlinear image recovery with half-quadratic regularization. TIP, 1995. [14] Karol Gregor and Yann LeCun. Learning fast approximations of sparse coding. In ICML, 2010. [15] K. He, X. Zhang, S. Ren, and J. Sun. Deep residual learning for image recognition. arXiv, 2015. [16] K. He, X. Zhang, S. Ren, and J. Sun. Delving deep into rectifiers: Surpassing human-level performance on imagenet classification. In ICCV, 2015. [17] G. Hinton, L. Deng, D. Yu, G. Dahl, A. Mohamed, N. Jaitly, A. Senior, V. Vanhoucke, P. Nguyen, T. Sainath, et al. Deep neural networks for acoustic modeling in speech recognition. SPM, IEEE, 2012. [18] A. Ihler and D. McAllester. Particle belief propagation. In AISTATS, 2009. [19] D. Kingma and J. Ba. Adam: A method for stochastic optimization. arXiv, 2014. [20] D. Krishnan and R. Fergus. Fast image deconvolution using hyper-laplacian priors. In NIPS, 2009. [21] A. Krizhevsky, I. Sutskever, and G. Hinton. Imagenet classification with deep convolutional neural networks. In NIPS, 2012. [22] J. Mairal, F. Bach, J. Ponce, G. Sapiro, and A. Zisserman. Non-local sparse models for image restoration. In ICCV, 2009. [23] D. Martin, C. Fowlkes, D. Tal, and J. Malik. A database of human segmented natural images and its application to evaluating segmentation algorithms and measuring ecological statistics. In ICCV, 2001. [24] N. Mayer, E. Ilg, P. Häusser, P. Fischer, D. Cremers, A. Dosovitskiy, and T. Brox. A large dataset to train convolutional networks for disparity, optical flow, and scene flow estimation. arXiv, 2015. [25] R. Newcombe, S. Izadi, O. Hilliges, D. Molyneaux, D. Kim, A. Davison, P. Kohi, J. Shotton, S. Hodges, and A. Fitzgibbon. Kinectfusion: Real-time dense surface mapping and tracking. In ISMAR, 2011. [26] N. Parikh and S. Boyd. Proximal algorithms. Foundations and Trends in optimization, 2014. [27] S. Ross, D. Munoz, M. Hebert, and J. Bagnell. Learning message-passing inference machines for structured prediction. In CVPR, 2011. [28] S. Roth and M. Black. Fields of experts: A framework for learning image priors. In CVPR, 2005. [29] U. Schmidt, J. Jancsary, S. Nowozin, S. Roth, and C. Rother. Cascades of regression tree fields for image restoration. PAMI, 2013. [30] U. Schmidt and S. Roth. Shrinkage fields for effective image restoration. In CVPR, 2014. [31] A. Schwing and R. Urtasun. Fully connected deep structured networks. arXiv, 2015. [32] E. Sudderth, A. Ihler, M. Isard, W. Freeman, and A. Willsky. Nonparametric belief propagation. Communications of the ACM, 2010. [33] I. Sutskever, O. Vinyals, and Q. Le. Sequence to sequence learning with neural networks. In NIPS, 2014. [34] I. Tsochantaridis, T. Hofmann, T. Joachims, and Y. Altun. Support vector machine learning for interdependent and structured output spaces. In ICML, 2004. [35] S. Wang, A. Schwing, and R. Urtasun. Efficient inference of continuous markov random fields with polynomial potentials. In NIPS, 2014. [36] Y. Weiss and W. Freeman. Correctness of belief propagation in gaussian graphical models of arbitrary topology. Neural computation, 2001. [37] C. Zach and P. Kohli. A convex discrete-continuous approach for markov random fields. In ECCV. 2012. [38] J. Zbontar and Y. LeCun. Computing the stereo matching cost with a convolutional neural network. In CVPR, 2015. [39] S. Zheng, S. Jayasumana, B. Romera-Paredes, V. Vineet, Z. Su, D. Du, C. Huang, and P. Torr. Conditional random fields as recurrent neural networks. In ICCV, 2015. [40] D. Zoran and Y. Weiss. From learning models of natural image patches to whole image restoration. In ICCV, 2011. 9 | 2016 | 549 |
6,493 | Higher-Order Factorization Machines Mathieu Blondel, Akinori Fujino, Naonori Ueda NTT Communication Science Laboratories Japan Masakazu Ishihata Hokkaido University Japan Abstract Factorization machines (FMs) are a supervised learning approach that can use second-order feature combinations even when the data is very high-dimensional. Unfortunately, despite increasing interest in FMs, there exists to date no efficient training algorithm for higher-order FMs (HOFMs). In this paper, we present the first generic yet efficient algorithms for training arbitrary-order HOFMs. We also present new variants of HOFMs with shared parameters, which greatly reduce model size and prediction times while maintaining similar accuracy. We demonstrate the proposed approaches on four different link prediction tasks. 1 Introduction Factorization machines (FMs) [13, 14] are a supervised learning approach that can use second-order feature combinations efficiently even when the data is very high-dimensional. The key idea of FMs is to model the weights of feature combinations using a low-rank matrix. This has two main benefits. First, FMs can achieve empirical accuracy on a par with polynomial regression or kernel methods but with smaller and faster to evaluate models [4]. Second, FMs can infer the weights of feature combinations that were not observed in the training set. This second property is crucial for instance in recommender systems, a domain where FMs have become increasingly popular [14, 16]. Without the low-rank property, FMs would fail to generalize to unseen user-item interactions. Unfortunately, although higher-order FMs (HOFMs) were briefly mentioned in the original work of [13, 14], there exists to date no efficient algorithm for training arbitrary-order HOFMs. In fact, even just computing predictions given the model parameters naively takes polynomial time in the number of features. For this reason, HOFMs have, to our knowledge, never been applied to any problem. In addition, HOFMs, as originally defined in [13, 14], model each degree in the polynomial expansion with a different matrix and therefore require the estimation of a large number of parameters. In this paper, we propose the first efficient algorithms for training arbitrary-order HOFMs. To do so, we rely on a link between FMs and the so-called ANOVA kernel [4]. We propose linear-time dynamic programming algorithms for evaluating the ANOVA kernel and computing its gradient. Based on these, we propose stochastic gradient and coordinate descent algorithms for arbitrary-order HOFMs. To reduce the number of parameters, as well as prediction times, we also introduce two new kernels derived from the ANOVA kernel, allowing us to define new variants of HOFMs with shared parameters. We demonstrate the proposed approaches on four different link prediction tasks. 2 Factorization machines (FMs) Second-order FMs. Factorization machines (FMs) [13, 14] are an increasingly popular method for efficiently using second-order feature combinations in classification or regression tasks even when the data is very high-dimensional. Let w ∈Rd and P ∈Rd×k, where k ∈N is a rank hyper-parameter. We denote the rows of P by ¯pj and its columns by ps, for j ∈[d] and s ∈[k], 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. where [d] := {1, . . . , d}. Then, FMs predict an output y ∈R from a vector x = [x1, . . . , xd]T by ˆyFM(x) := ⟨w, x⟩+ X j′>j ⟨¯pj, ¯pj′⟩xjxj′. (1) An important characteristic of (1) is that it considers only combinations of distinct features (i.e., the squared features x2 1, . . . , x2 d are ignored). The main advantage of FMs compared to naive polynomial regression is that the number of parameters to estimate is O(dk) instead of O(d2). In addition, we can compute predictions in O(2dk) time1 using ˆyFM(x) = wTx + 1 2 ∥P Tx∥2 − k X s=1 ∥ps ◦x∥2 , where ◦indicates element-wise product [3]. Given a training set X = [x1, . . . , xn] ∈Rd×n and y = [y1, . . . , yn]T ∈Rn, w and P can be learned by minimizing the following non-convex objective 1 n n X i=1 ℓ(yi, ˆyFM(xi)) + β1 2 ∥w∥2 + β2 2 ∥P ∥2, (2) where ℓis a convex loss function and β1 > 0, β2 > 0 are hyper-parameters. The popular libfm library [14] implements efficient stochastic gradient and coordinate descent algorithms for obtaining a stationary point of (2). Both algorithms have a runtime complexity of O(2dkn) per epoch. Higher-order FMs (HOFMs). Although no training algorithm was provided, FMs were extended to higher-order feature combinations in the original work of [13, 14]. Let P (t) ∈Rd×kt, where t ∈{2, . . . , m} is the order or degree of feature combinations considered, and kt ∈N is a rank hyper-parameter. Let ¯p(t) j be the jth row of P (t). Then m-order HOFMs can be defined as ˆyHOFM(x) := ⟨w, x⟩+ X j′>j ⟨¯p(2) j , ¯p(2) j′ ⟩xjxj′ +· · ·+ X jm>···>j1 ⟨¯p(m) j1 , . . . , ¯p(m) jm ⟩xj1xj2 . . . xjm (3) where we defined ⟨¯p(t) j1 , . . . , ¯p(t) jt ⟩:= sum(¯p(t) j1 ◦· · · ◦¯p(t) jt ) (sum of element-wise products). The objective function of HOFMs can be expressed in a similar way as for (2): 1 n n X i=1 ℓ(yi, ˆyHOFM(xi)) + β1 2 ∥w∥2 + m X t=2 βt 2 ∥P (t)∥2, (4) where β1, . . . , βm > 0 are hyper-parameters. To avoid the combinatorial explosion of hyperparameter combinations to search, in our experiments we will simply set β1 = · · · = βm and k2 = · · · = km. While (3) looks quite daunting, [4] recently showed that FMs can be expressed from a simpler kernel perspective. Let us define the ANOVA2 kernel [19] of degree 2 ≤m ≤d by Am(p, x) := X jm>···>j1 m Y t=1 pjtxjt. (5) For later convenience, we also define A0(p, x) := 1 and A1(p, x) := ⟨p, x⟩. Then it is shown that ˆyHOFM(x) = ⟨w, x⟩+ k2 X s=1 A2 p(2) s , x + · · · + km X s=1 Am p(m) s , x , (6) where p(t) s is the sth column of P (t). This perspective shows that we can view FMs and HOFMs as a type of kernel machine whose “support vectors” are learned directly from data. Intuitively, the ANOVA kernel can be thought as a kind of polynomial kernel that uses feature combinations without replacement (i.e., of distinct features). A key property of the ANOVA kernel is multi-linearity [4]: Am(p, x) = Am(p¬j, x¬j) + pjxj Am−1(p¬j, x¬j), (7) where p¬j denotes the (d −1)-dimensional vector with pj removed and similarly for x¬j. That is, everything else kept fixed, Am(p, x) is an affine function of pj ∀j ∈[d]. Although no training 1We include the constant factor for fair later comparison with arbitrary-order HOFMs. 2The name comes from the ANOVA decomposition of functions. [20, 19] 2 algorithm was provided, [4] showed based on (7) that, although non-convex, the objective function of arbitrary-order HOFMs is convex in w and in each row of P (2), . . . , P (m), separately. Interpretability of HOFMs. An advantage of FMs and HOFMs is their interpretability. To see why this is the case, notice that we can rewrite (3) as ˆyHOFM(x) = ⟨w, x⟩+ X j′>j W(2) j,j′xjxj′ + · · · + X jm>···>j1 W(m) j1,...,jmxj1xj2 . . . xjm, where we defined W(t) := Pkt s=1 p(t) s ⊗· · · ⊗p(t) s | {z } t times . Intuitively, W(t) ∈Rdt is a low-rank t-way tensor which contains the weights of feature combinations of degree t. For instance, when t = 3, W(3) i,j,k is the weight of xixjxk. Similarly to the ANOVA decomposition of functions, HOFMs consider only combinations of distinct features (i.e., xj1xj2 . . . xjm for jm > · · · > j2 > j1). This paper. Unfortunately, there exists to date no efficient algorithm for training arbitrary-order HOFMs. Indeed, computing (5) naively takes O(dm), i.e., polynomial time. In the following, we present linear-time algorithms. Moreover, HOFMs, as originally defined in [13, 14] require the estimation of m −1 matrices P (2), . . . , P (m). Thus, HOFMs can produce large models when m is large. To address this issue, we propose new variants of HOFMs with shared parameters. 3 Linear-time stochastic gradient algorithms for HOFMs The kernel view presented in Section 2 allows us to focus on the ANOVA kernel as the main “computational unit” for training HOFMs. In this section, we develop dynamic programming (DP) algorithms for evaluating the ANOVA kernel and computing its gradient in only O(dm) time. Evaluation. The main observation (see also [18, Section 9.2]) is that we can use (7) to recursively remove features until computing the kernel becomes trivial. Let us denote a subvector of p by p1:j ∈Rj and similarly for x. Let us introduce the shorthand aj,t := At(p1:j, x1:j). Then, from (7), aj,t = aj−1,t + pjxj aj−1,t−1 ∀d ≥j ≥t ≥1. (8) For convenience, we also define aj,0 = 1 ∀j ≥0 since A0(p, x) = 1 and aj,t = 0 ∀j < t since there does not exist any t-combination of features in a j < t dimensional vector. Table 1: Example of DP table j = 0 j = 1 j = 2 . . . j = d t = 0 1 1 1 1 1 t = 1 0 a1,1 a2,1 . . . ad,1 t = 2 0 0 a2,2 . . . ad,2 ... ... ... ... ... ... t = m 0 0 0 . . . ad,m The quantity we want to compute is Am(p, x) = ad,m. Instead of naively using recursion (8), which would lead to many redundant computations, we use a bottom-up approach and organize computations in a DP table. We start from the top-left corner to initialize the recursion and go through the table to arrive at the solution in the bottomright corner. The procedure, summarized in Algorithm 1, takes O(dm) time and memory. Gradients. For computing the gradient of Am(p, x) w.r.t. p, we use reverse-mode differentiation [2] (a.k.a. backpropagation in a neural network context), since it allows us to compute the entire gradient in a single pass. We supplement each variable aj,t in the DP table by a so-called adjoint ˜aj,t := ∂ad,m ∂aj,t , which represents the sensitivity of ad,m = Am(p, x) w.r.t. aj,t. From recursion (8), except for edge cases, aj,t influences aj+1,t+1 and aj+1,t. Using the chain rule, we then obtain ˜aj,t = ∂ad,m ∂aj+1,t ∂aj+1,t ∂aj,t + ∂ad,m ∂aj+1,t+1 ∂aj+1,t+1 ∂aj,t = ˜aj+1,t+pj+1xj+1 ˜aj+1,t+1 ∀d−1 ≥j ≥t ≥1. (9) Similarly, we introduce the adjoint ˜pj := ∂ad,m ∂pj ∀j ∈[d]. Since pj influences aj,t ∀t ∈[m], we have ˜pj = m X t=1 ∂ad,m ∂aj,t ∂aj,t ∂pj = m X t=1 ˜aj,t aj−1,t−1 xj. We can run recursion (9) in reverse order of the DP table starting from ˜ad,m = ∂ad,m ∂ad,m = 1. Using this approach, we can compute the entire gradient ∇Am(p, x) = [˜p1, . . . , ˜pd]T w.r.t. p in O(dm) time and memory. The procedure is summarized in Algorithm 2. 3 Algorithm 1 Evaluating Am(p, x) in O(dm) Input: p ∈Rd, x ∈Rd aj,t ←0 ∀t ∈[m], j ∈[d] ∪{0} aj,0 ←1 ∀j ∈[d] ∪{0} for t := 1, . . . , m do for j := t, . . . , d do aj,t ←aj−1,t + pjxjaj−1,t−1 end for end for Output: Am(p, x) = ad,m Algorithm 2 Computing ∇Am(p, x) in O(dm) Input: p ∈Rd, x ∈Rd, {aj,t}d,m j,t=0 ˜aj,t ←0 ∀t ∈[m + 1], j ∈[d] ˜ad,m ←1 for t := m, . . . , 1 do for j := d −1, . . . , t do ˜aj,t ←˜aj+1,t + ˜aj+1,t+1pj+1xj+1 end for end for ˜pj := Pm t=1 ˜aj,taj−1,t−1xj ∀j ∈[d] Output: ∇Am(p, x) = [˜p1, . . . , ˜pd]T Stochastic gradient (SG) algorithms. Based on Algorithm 1 and 2, we can easily learn arbitraryorder HOFMs using any gradient-based optimization algorithm. Here we focus our discussion on SG algorithms. If we alternatingly minimize (4) w.r.t P (2), . . . , P (m), then the sub-problem associated with degree m is of the form F(P ) := 1 n n X i=1 ℓ yi, k X s=1 Am(ps, xi) + oi ! + β 2 ∥P ∥2, (10) where o1, . . . , on ∈R are fixed offsets which account for the contribution of degrees other than m to the predictions. The sub-problem is convex in each row of P [4]. A SG update for (10) w.r.t. ps for some instance xi can be computed by ps ←ps −ηℓ′(yi, ˆyi)∇Am(ps, xi) −ηβps, where η is a learning rate and where we defined ˆyi := Pk s=1 Am(ps, xi) + oi. Because evaluating Am(p, x) and computing its gradient both take O(dm), the cost per epoch, i.e., of visiting all instances, is O(mdkn). When m = 2, this is the same cost as the SG algorithm implemented in libfm. Sparse data. We conclude this section with a few useful remarks on sparse data. Let us denote the support of a vector x = [x1, . . . , xd]T by supp(x) := {j ∈[d]: xj ̸= 0} and let us define xS := [xj : j ∈S]T. It is easy to see from (7) that the gradient and x have the same support, i.e., supp(∇Am(p, x)) = supp(x). Another useful remark is that Am(p, x) = Am(psupp(x), xsupp(x)), provided that m ≤nz(x), where nz(x) is the number of non-zero elements in x. Hence, when the data is sparse, we only need to iterate over non-zero features in Algorithm 1 and 2. Consequently, their time and memory cost is only O(nz(x)m) and thus the cost per epoch of SG algorithms is O(mknz(X)). 4 Coordinate descent algorithm for arbitrary-order HOFMs We now describe a coordinate descent (CD) solver for arbitrary-order HOFMs. CD is a good choice for learning HOFMs because their objective function is coordinate-wise convex, thanks to the multilinearity of the ANOVA kernel [4]. Our algorithm can be seen as a generalization to higher orders of the CD algorithms proposed in [14, 4]. An alternative recursion. Efficient CD implementations typically require maintaining statistics for each training instance, such as the predictions at the current iteration. When a coordinate is updated, the statistics then need to be synchronized. Unfortunately, the recursion we used in the previous section is not suitable for a CD algorithm because it would require to store and synchronize the DP table for each training instance upon coordinate-wise updates. We therefore turn to an alternative recursion: Am(p, x) = 1 m m X t=1 (−1)t+1Am−t(p, x)Dt(p, x), (11) where we defined Dt(p, x) := Pd j=1(pjxj)t. Note that the recursion was already known in the context of traditional kernel methods (c.f., [19, Section 11.8]) but its application to HOFMs is novel. Since we know that A0(p, x) = 1 and A1(p, x) = ⟨p, x⟩, we can use (11) to compute A2(p, x), then A3(p, x), and so on. The overall evaluation cost for arbitrary m ∈N is O(md + m2). 4 Coordinate-wise derivatives. We can apply reverse-mode differentiation to recursion (11) in order to compute the entire gradient (c.f., Appendix C). However, in CD, since we only need the derivative of one variable at a time, we can simply use forward-mode differentiation: ∂Am(p, x) ∂pj = 1 m m X t=1 (−1)t+1 ∂Am−t(p, x) ∂pj Dt(p, x) + Am−t(p, x)∂Dt(p, x) ∂pj , (12) where ∂Dt(p,x) ∂pj = tpt−1 j xt j. The advantage of (12) is that we only need to cache Dt(p, x) for t ∈[m]. Hence the memory complexity per sample is only O(m) instead of O(dm) for (8). Use in a CD algorithm. Similarly to [4], we assume that the loss function ℓis µ-smooth and update the elements pj,s of P in cyclic order by pj,s ←pj,s −η−1 j,s ∂F (P ) ∂pj,s , where we defined ηj,s := µ n n X i=1 ∂Am(ps, xi) ∂pj,s 2 + β and ∂F(P ) ∂pj,s = 1 n n X i=1 ℓ′(yi, ˆyi)∂Am(ps, xi) ∂pj,s + βpj,s. The update guarantees that the objective value is monotonically non-increasing and is the exact coordinate-wise minimizer when ℓis the squared loss. Overall, the total cost per epoch, i.e., updating all coordinates once, is O(τ(m)knz(X)), where τ(m) is the time it takes to compute (12). Assuming Dt(ps, xi) have been previously cached, for t ∈[m], computing (12) takes τ(m) = m(m+1)/2−1 operations. For fixed m, if we unroll the two loops needed to compute (12), modern compilers can often further reduce the number of operations needed. Nevertheless, this quadratic dependency on m means that our CD algorithm is best for small m, typically m ≤4. 5 HOFMs with shared parameters HOFMs, as originally defined in [13, 14], model each degree with separate matrices P (2), . . . , P (m). Assuming that we use the same rank k for all matrices, the total model size of m-order HOFMs is therefore O(kdm). Moreover, even when using our O(dm) DP algorithm, the cost of computing predictions is O(k(2d + · · · + md)) = O(kdm2). Hence, HOFMs tend to produce large, expensiveto-evaluate models. To reduce model size and prediction times, we introduce two new kernels which allow us to share parameters between each degree: the inhomogeneous ANOVA kernel and the all-subsets kernel. Because both kernels are derived from the ANOVA kernel, they share the same appealing properties: multi-linearity, sparse gradients and sparse-data friendliness. 5.1 Inhomogeneous ANOVA kernel It is well-known that a sum of kernels is equivalent to concatenating their associated feature maps [18, Section 3.4]. Let θ = [θ1, . . . , θm]T. To combine different degrees, a natural kernel is therefore A1→m(p, x; θ) := m X t=1 θtAt(p, x). (13) The kernel uses all feature combinations of degrees 1 up to m. We call it inhomogeneous ANOVA kernel, since it is an inhomogeneous polynomial of x. In contrast, Am(p, x) is homogeneous. The main difference between (13) and (6) is that all ANOVA kernels in the sum share the same parameters. However, to increase modeling power, we allow each kernel to have different weights θ1, . . . , θm. Evaluation. Due to the recursive nature of Algorithm 1, when computing Am(p, x), we also get A1(p, x), . . . , Am−1(p, x) for free. Indeed, lower-degree kernels are available in the last column of the DP table, i.e., At(p, x) = ad,t ∀t ∈[m]. Hence, the cost of evaluating (13) is O(dm) time. The total cost for computing ˆy = Pk s=1 A1→m(ps, x; θ) is O(kdm) instead of O(kdm2) for ˆyHOFM(x). Learning. While it is certainly possible to learn P and θ by directly minimizing some objective function, here we propose an easier solution, which works well in practice. Our key observation is that we can easily turn Am into A1→m by adding dummy values to feature vectors. Let us denote the concatenation of p with a scalar γ by [γ, p] and similarly for x. From (7), we easily obtain Am([γ1, p], [1, x]) = Am(p, x) + γ1Am−1(p, x). 5 Table 2: Datasets used in our experiments. For a detailed description, c.f. Appendix A. Dataset n+ Columns of A nA dA Columns of B nB dB NIPS [17] 4,140 Authors 2,037 13,649 Enzyme [21] 2,994 Enzymes 668 325 GD [10] 3,954 Diseases 3,209 3,209 Genes 12,331 25,275 Movielens 100K [6] 21,201 Users 943 49 Movies 1,682 29 Similarly, if we apply (7) twice, we obtain: Am([γ1, γ2, p], [1, 1, x]) = Am(p, x) + (γ1 + γ2)Am−1(p, x) + γ1γ2Am−2(p, x). Applying the above to m = 2 and m = 3, we obtain A2([γ1, p], [1, x]) = A1→2(p, x; [γ1, 1]) and A3([γ1, γ2, p], [1, 1, x]) = A1→3(p, x; [γ1γ2, γ1+γ2, 1]). More generally, by adding m−1 dummy features to p and x, we can convert Am to A1→m. Because p is learned, this means that we can automatically learn γ1, . . . , γm−1. These weights can then be converted to θ1, . . . , θm by “unrolling” recursion (7). Although simple, we show in our experiments that this approach works favorably compared to directly learning P and θ. The main advantage of this approach is that we can use the same software unmodified (we simply need to minimize (10) with the augmented data). Moreover, the cost of computing the entire gradient by Algorithm 2 using the augmented data is just O(dm + m2) compared to O(dm2) for HOFMs with separate parameters. 5.2 All-subsets kernel We now consider a closely related kernel called all-subsets kernel [18, Definition 9.5]: S(p, x) := d Y j=1 (1 + pjxj). The main difference with the traditional use of this kernel is that we learn p. Interestingly, it can be shown that S(p, x) = 1 + A1→d(p, x; 1) = 1 + A1→nz(x)(p, x; 1), where nz(x) is the number of non-zero features in x. Hence, the kernel uses all combinations of distinct features up to order nz(x) with uniform weights. Even if d is very large, the kernel can be a good choice if each training instance contains only a few non-zero elements. To learn the parameters, we simply substitute Am with S in (10). In SG or CD algorithms, all it entails is to substitute ∇Am(p, x) with ∇S(p, x). For computing ∇S(p, x), it is easy to verify that S(p, x) = S(p¬j, x¬j)(1 + pjxj) ∀j ∈[d] and therefore we have ∇S(p, x) = x1 S(p¬1, x¬1), . . . , xd S(p¬d, x¬d) T = x1 S(p, x) 1 + p1x1 , . . . , xd S(p, x) 1 + pdxd T . Therefore, the main advantage of the all-subsets kernel is that we can evaluate it and compute its gradient in just O(d) time. The total cost for computing ˆy = Pk s=1 S(ps, x) is only O(kd). 6 Experimental results 6.1 Application to link prediction Problem setting. We now demonstrate a novel application of HOFMs to predict the presence or absence of links between nodes in a graph. Formally, we assume two sets of possibly disjoint nodes of size nA and nB, respectively. We assume features for the two sets of nodes, represented by matrices A ∈RdA×nA and B ∈RdB×nB. For instance, A can represent user features and B movie features. We denote the columns of A and B by ai and bj, respectively. We are given a matrix Y ∈{0, 1}nA×nB, whose elements indicate presence (positive sample) or absence (negative sample) of link between two nodes ai and bj. We denote the number of positive samples by n+. Using this data, our goal is to predict new associations. Datasets used in our experiments are summarized in Table 2. Note that for the NIPS and Enzyme datasets, A = B. Conversion to a supervised problem. We need to convert the above information to a format FMs and HOFMs can handle. To predict an element yi,j of Y , we simply form xi,j to be the concatenation 6 Table 3: Comparison of area under the ROC curve (AUC) as measured on the test sets. NIPS Enzyme GD Movielens 100K HOFM (m = 2) 0.856 0.880 0.717 0.778 HOFM (m = 3) 0.875 0.888 0.717 0.786 HOFM (m = 4) 0.874 0.887 0.717 0.786 HOFM (m = 5) 0.874 0.887 0.717 0.786 HOFM-shared-augmented (m = 2) 0.858 0.876 0.704 0.778 HOFM-shared-augmented (m = 3) 0.874 0.887 0.704 0.787 HOFM-shared-augmented (m = 4) 0.836 0.824 0.663 0.779 HOFM-shared-augmented (m = 5) 0.824 0.795 0.600 0.621 HOFM-shared-simplex (m = 2) 0.716 0.865 0.721 0.701 HOFM-shared-simplex (m = 3) 0.777 0.870 0.721 0.709 HOFM-shared-simplex (m = 4) 0.758 0.870 0.721 0.709 HOFM-shared-simplex (m = 5) 0.722 0.869 0.721 0.709 All-subsets 0.730 0.840 0.721 0.714 Polynomial network (m = 2) 0.725 0.879 0.721 0.761 Polynomial network (m = 3) 0.789 0.853 0.719 0.696 Polynomial network (m = 4) 0.782 0.873 0.717 0.708 Polynomial network (m = 5) 0.543 0.524 0.648 0.501 Low-rank bilinear regression 0.855 0.694 0.611 0.718 of ai and bj and feed this to a HOFM in order to compute a prediction ˆyi,j. Because HOFMs use feature combinations in xi,j, they can learn the weights of feature combinations between ai and bj. At training time, we need both positive and negative samples. Let us denote the set of positive and negative samples by Ω. Then our training set is composed of (xi,j, yi,j) pairs, where (i, j) ∈Ω. Models compared. • HOFM: ˆyi,j = ˆyHOFM(xi,j) as defined in (3) and as originally proposed in [13, 14]. We minimize (4) by alternating minimization of (10) for each degree. • HOFM-shared: ˆyi,j = Pk s=1 A1→m(ps, xi,j; θ). We learn P and θ using the simple augmented data approach described in Section 5.1 (HOFM-shared-augmented). Inspired by SimpleMKL [12], we also report results when learning P and θ directly by minimizing 1 |Ω| P (i,j)∈Ωℓ(yi,j, ˆyi,j) + β 2 ∥P ∥2 subject to θ ≥0 and ⟨θ, 1⟩= 1 (HOFM-shared-simplex). • All-subsets: ˆyi,j = Pk s=1 S(ps, xi,j). As explained in Section 5.2, this model is equivalent to the HOFM-shared model with m = nz(xi,j) and θ = 1. • Polynomial network: ˆyi,j = Pk s=1(γs + ⟨ps, xi,j⟩)m. This model can be thought as factorization machine variant that uses a polynomial kernel instead of the ANOVA kernel (c.f., [8, 4, 22]). • Low-rank bilinear regression: ˆyi,j = aiUV Tbj, where U ∈RdA×k and V ∈RdB×k. Such model was shown to work well for link prediction in [9] and [10]. We learn U and V by minimizing 1 |Ω| P (i,j)∈Ωℓ(yi,j, ˆyi,j) + β 2 (∥U∥2 + ∥V ∥2). Experimental setup and evaluation. In this experiment, for all models above, we use CD rather than SG to avoid the tuning of a learning rate hyper-parameter. We set ℓto be the squared loss. Although we omitted it from our notation for clarity, we also fit a bias term for all models. We evaluated the compared models using the area under the ROC curve (AUC), which is the probability that the model correctly ranks a positive sample higher than a negative sample. We split the n+ positive samples into 50% for training and 50% for testing. We sample the same number of negative samples as positive samples for training and use the rest for testing. We chose β from 10−6, 10−5, . . . , 106 by cross-validation and following [9] we empirically set k = 30. Throughout our experiments, we initialized the elements of P randomly by N(0, 0.01). Results are indicated in Table 3. Overall the two best models were HOFM and HOFM-sharedaugmented, which achieved the best scores on 3 out of 4 datasets. The two models outperformed low-rank bilinear regression on 3 out 4 datasets, showing the benefit of using higher-order feature combinations. HOFM-shared-augmented achieved similar accuracy to HOFM, despite using a smaller model. Surprisingly, HOFM-shared-simplex did not improve over HOFM-shared-augmented except 7 (a) Convergence when m = 2 (b) Convergence when m = 3 (c) Convergence when m = 4 (d) Scalability w.r.t. degree m Figure 1: Solver comparison for minimizing (10) when varying the degree m on the NIPS dataset with β = 0.1 and k = 30. Results on other datasets are in Appendix B. on the GD dataset. We conclude that our augmented data approach is convenient yet works well in practice. All-subsets and polynomial networks performed worse than HOFM and HOFM-sharedaugmented, except on the GD dataset where they were the best. Finally, we observe that HOFM were quite robust to increasing m, which is likely a benefit of modeling each degree with a separate matrix. 6.2 Solver comparison We compared AdaGrad [5], L-BFGS and coordinate descent (CD) for minimizing (10) when varying the degree m on the NIPS dataset with β = 0.1 and k = 30. We constructed the data in the same way as explained in the previous section and added m −1 dummy features, resulting in n = 8, 280 sparse samples of dimension d = 27, 298 + m −1. For AdaGrad and L-BFGS, we computed the (stochastic) gradients using Algorithm 2. All solvers used the same initialization. Results are indicated in Figure 1. We see that our CD algorithm performs very well when m ≤3 but starts to deteriorate when m ≥4, in which case L-BFGS becomes advantageous. As shown in Figure 1 d), the cost per epoch of AdaGrad and L-BFGS scales linearly with m, a benefit of our DP algorithm for computing the gradient. However, to our surprise, we found that AdaGrad is quite sensitive to the learning rate η. AdaGrad diverged for η ∈{1, 0.1, 0.01} and the largest value to work well was η = 0.001. This explains why AdaGrad did not outperform CD despite the lower cost per epoch. In the future, it would be useful to create a CD algorithm with a better dependency on m. 7 Conclusion and future directions In this paper, we presented the first training algorithms for HOFMs and introduced new HOFM variants with shared parameters. A popular way to deal with a large number of negative samples is to use an objective function that directly maximize AUC [9, 15]. This is especially easy to do with SG algorithms because we can sample pairs of positive and negative samples from the dataset upon each SG update. We therefore expect the algorithms developed in Section 3 to be especially useful in this setting. Recently, [7] proposed a distributed SG algorithm for training second-order FMs. It should be straightforward to extend this algorithm to HOFMs based on our contributions in Section 3. Finally, it should be possible to integrate Algorithm 1 and 2 into a deep learning framework such as TensorFlow [1], in order to easily compose ANOVA kernels with other layers (e.g., convolutional). 8 References [1] M. Abadi et al. TensorFlow: Large-scale machine learning on heterogeneous systems, 2015. [2] A. G. Baydin, B. A. Pearlmutter, and A. A. Radul. Automatic differentiation in machine learning: a survey. arXiv preprint arXiv:1502.05767, 2015. [3] M. Blondel, A. Fujino, and N. Ueada. Convex factorization machines. In Proceedings of European Conference on Machine Learning and Principles and Practice of Knowledge Discovery in Databases (ECML PKDD), 2015. [4] M. Blondel, M. Ishihata, A. Fujino, and N. Ueada. Polynomial networks and factorization machines: New insights and efficient training algorithms. In Proceedings of International Conference on Machine Learning (ICML), 2016. [5] J. Duchi, E. Hazan, and Y. Singer. Adaptive subgradient methods for online learning and stochastic optimization. Journal of Machine Learning Research, 12:2121–2159, 2011. [6] GroupLens. http://grouplens.org/datasets/movielens/, 1998. [7] M. Li, Z. Liu, A. Smola, and Y.-X. Wang. Difacto – distributed factorization machines. In Proceedings of International Conference on Web Search and Data Mining (WSDM), 2016. [8] R. Livni, S. Shalev-Shwartz, and O. Shamir. On the computational efficiency of training neural networks. In Advances in Neural Information Processing Systems, pages 855–863, 2014. [9] A. K. Menon and C. Elkan. Link prediction via matrix factorization. In Machine Learning and Knowledge Discovery in Databases, pages 437–452. 2011. [10] N. Natarajan and I. S. Dhillon. Inductive matrix completion for predicting gene–disease associations. Bioinformatics, 30(12):i60–i68, 2014. [11] V. Y. Pan. Structured Matrices and Polynomials: Unified Superfast Algorithms. Springer-Verlag New York, Inc., 2001. [12] A. Rakotomamonjy, F. Bach, S. Canu, and Y. Grandvalet. Simplemkl. Journal of Machine Learning Research, 9:2491–2521, 2008. [13] S. Rendle. Factorization machines. In Proceedings of International Conference on Data Mining, pages 995–1000. IEEE, 2010. [14] S. Rendle. Factorization machines with libfm. ACM Transactions on Intelligent Systems and Technology (TIST), 3(3):57–78, 2012. [15] S. Rendle, C. Freudenthaler, Z. Gantner, and L. Schmidt-Thieme. Bpr: Bayesian personalized ranking from implicit feedback. In Proceedings of the twenty-fifth conference on uncertainty in artificial intelligence, pages 452–461, 2009. [16] S. Rendle, Z. Gantner, C. Freudenthaler, and L. Schmidt-Thieme. Fast context-aware recommendations with factorization machines. In SIGIR, pages 635–644, 2011. [17] S. Roweis. http://www.cs.nyu.edu/~roweis/data.html, 2002. [18] J. Shawe-Taylor and N. Cristianini. Kernel Methods for Pattern Analysis. Cambridge University Press, 2004. [19] V. Vapnik. Statistical learning theory. Wiley, 1998. [20] G. Wahba. Spline models for observational data, volume 59. Siam, 1990. [21] Y. Yamanishi, J.-P. Vert, and M. Kanehisa. Supervised enzyme network inference from the integration of genomic data and chemical information. Bioinformatics, 21:i468–i477, 2005. [22] J. Yang and A. Gittens. Tensor machines for learning target-specific polynomial features. arXiv preprint arXiv:1504.01697, 2015. 9 | 2016 | 55 |
6,494 | SPALS: Fast Alternating Least Squares via Implicit Leverage Scores Sampling Dehua Cheng University of Southern California dehua.cheng@usc.edu Richard Peng Georgia Institute of Technology rpeng@cc.gatech.edu Ioakeim Perros Georgia Institute of Technology perros@gatech.edu Yan Liu University of Southern California yanliu.cs@usc.edu Abstract Tensor CANDECOMP/PARAFAC (CP) decomposition is a powerful but computationally challenging tool in modern data analytics. In this paper, we show ways of sampling intermediate steps of alternating minimization algorithms for computing low rank tensor CP decompositions, leading to the sparse alternating least squares (SPALS) method. Specifically, we sample the Khatri-Rao product, which arises as an intermediate object during the iterations of alternating least squares. This product captures the interactions between different tensor modes, and form the main computational bottleneck for solving many tensor related tasks. By exploiting the spectral structures of the matrix Khatri-Rao product, we provide efficient access to its statistical leverage scores. When applied to the tensor CP decomposition, our method leads to the first algorithm that runs in sublinear time per-iteration and approximates the output of deterministic alternating least squares algorithms. Empirical evaluations of this approach show significant speedups over existing randomized and deterministic routines for performing CP decomposition. On a tensor of the size 2.4m ⇥6.6m ⇥92k with over 2 billion nonzeros formed by Amazon product reviews, our routine converges in two minutes to the same error as deterministic ALS. 1 Introduction Tensors, a.k.a. multidimensional arrays, appear frequently in many applications, including spatialtemporal data modeling [40], signal processing [12, 14], deep learning [29] and more. Low-rank tensor decomposition [21] is a fundamental tool for understanding and extracting the information from tensor data, which has been actively studied in recent years. Developing scalable and provable algorithms for most tensor processing tasks is challenging due to the non-convexity of the objective [18, 21, 16, 1]. Especially in the era of big data, scalable low-rank tensor decomposition algorithm (that runs in nearly linear or even sublinear time in the input data size) has become an absolute must to command the full power of tensor analytics. For instance, the Amazon review data [24] yield a 2, 440, 972 ⇥6, 643, 571 ⇥92, 626 tensor with 2 billion nonzero entries after preprocessing. Such data sets pose challenges of scalability to some of the simplest tensor decomposition tasks. There are multiple well-defined tensor ranks[21]. In this paper, we focus on the tensor CANDECOMP/PARAFAC (CP) decomposition [17, 3], where the low-rank tensor is modeled by the summation over many rank-1 tensors. Due to its simplicity and interpretability, tensor CP decomposition, which is to find the best rank-R approximation for the input tensor often by minimizing the square loss function, has been widely adopted in many applications [21]. 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. Matrix Khatri-Rao (KRP) product captures the interactions between different tensor modes in the CP decomposition, and it is essential for understanding many tensor related tasks. For instance, in the alternating least square (ALS) algorithm, which has been the workhorse for solving the tensor CP decomposition problem, a compact representation of the KRP can reduce the computational cost directly. ALS is a simple and parameter-free algorithm that optimizes the target rank-R tensor by updating its factor matrices in the block coordinate descent fashion. In each iteration, the computational bottleneck is to solve a least square regression problem, where the size of the design matrix, a KRP of factor matrices, is n2 ⇥n for an n ⇥n ⇥n tensor. While least square regression is one of the most studied problem, solving it exactly requires at least O(n2) operations [23], which can be larger than the size of input data for sparse tensors. For instance, the amazon review data with 2 ⇥109 nonzeros leads to a computational cost on the order of 1012 per iteration. Exploiting the structure of the KRP can reduce this cost to be linear in the input size, which on large-scale applications is still expensive for an iterative algorithm. An effective way for speeding up such numerical computations is through randomization [23, 38], where the computational cost can be uncorrelated with the ambient size of the input data in the optimal case. By exploring the connection between the spectral structures of the design matrix as the KRP of the factor matrices, we provide efficient access to the statistical leverage score of the design matrix. It allows us to propose the SPALS algorithm that samples rows of the KRP in a nearly-optimal manner. This near optimality is twofold: 1) the estimates of leverage scores that we use have many tight cases; 2) the operation of sampling a row can be efficiently performed. The latter requirement is far from trivial: Note that even when the optimal sampling probability is given, drawing a sample may require O(n2) preprocessing. Our result on the spectral structures of the design matrix allows us to achieve both criteria simultaneously, leading to the first sublinear-per-iteration cost ALS algorithm with provable approximation guarantees. Our contributions can be summarized as follows: 1. We show a close connection between the statistical leverage scores of the matrix Khatri-Rao product and the scores of the input matrices. This yields efficient and accurate leverage score estimations for importance sampling; 2. Our algorithm achieves the state-of-art computational efficiency, while approximating the ALS algorithm provably for computing CP tensor decompositions. The running time of each iteration of our algorithm is ˜O(nR3), sublinear in the input size for large tensors. 3. Our theoretical results on the spectral structure of KRP can also be applied on other tensor related applications such as stochastic gradient descent [26] and high-order singular value decompositions (HOSVD) [13]. We formalize the definitions in Section 2 and present our main results on leverage score estimation of the KRP in Section 3. The SPALS algorithm and its theoretical analysis are presented in Section 4. We discuss connections with previous works in Section 5. In Section 6, we empirical evaluate this algorithm and its variants on both synthetic and real world data. And we conclude and discuss our work in Section 7. 2 Notation and Background Vectors are represented by boldface lowercase letters, such as, a, b, c; Matrices are represented by boldface capital letters, such as, A, B, C; Tensors are represented by boldface calligraphic capital letters, such as, T . Without loss of generality, in this paper we focus our discussion for the 3-mode tensors, but our results and algorithm can be easily generalized to higher-order tensors. The ith entry of a vector is denoted by ai, element (i, j) of a matrix A is denoted by Aij, and the element (i, j, k) of a tensor T 2 RI⇥J⇥K is denoted by Tijk. For notation simplicity, we assume that (i, j) also represents the index i + Ij between 1 and IJ, where the value I and J should be clear from the context. For a tensor T 2 RI⇥J⇥K, we denote the tensor norm as kT k, i.e., kT k = qPI,J,K i,j,k=1 T 2 ijk. Special Matrix Products Our manipulation of tensors as matrices revolves around several matrix products. Our main focus is the matrix Khatri-Rao product (KRP) ⊙, where for a pair of matrices A 2 RI⇥R and B 2 RJ⇥R, A ⊙B 2 R(IJ)⇥R has element ((i, j), r) as AirBjr. 2 We also utilize the matrix Kronecker product ⌦and the elementwise matrix product ⇤. More details on these products can be found in Appendix A and [21]. Tensor Matricization Here we consider only the case of mode-n matricization. For n = 1, 2, 3, the mode-n matricization of a tensor T 2 RI⇥J⇥K is denoted by T(n). For instance, T(3) 2 RK⇥IJ, where the element (k, (i, j)) is Tijk. Tensor CP Decomposition The tensor CP decomposition [17, 3] expresses a tensor as the sum of a number of rank-one tensors, e.g., T = R X r=1 ar ◦br ◦cr, where ◦denotes the outer product, T 2 RI⇥J⇥K and ar 2 RI, br 2 RJ, and cr 2 RK for r = 1, 2, . . . , R. Tensor CP decomposition will be compactly represented using JA, B, CK, where the factor matrices A 2 RI⇥R,B 2 RJ⇥R and C 2 RK⇥R and ar, br, cr are their r-th column respectively, i.e., JA, B, CKijk = PR r=1 AirBjrCkr. Similar as in the matrix case, each rank-1 component is usually interpreted as a hidden factor, which captures the interactions between all dimensions in the simplest way. Given a tensor T 2 RI⇥J⇥K along with target rank R, the goal is to find a rank-R tensor specified by its factor matrices A 2 RI⇥R, B 2 RJ⇥R, C 2 RK⇥R, that is as close to T as possible: min A,B,C kT −JA, B, CKk2 = X i,j,k T i,j,k − R X r=1 AirBjrCkr !2 . Alternating Least Squares Algorithm A widely used method for performing CP decomposition is alternating least squares (ALS) algorithm. It iteratively minimizes one of the factor matrices with the others fixed. For instance, when the factors A and B are fixed, algebraic manipulations suggest that the best choice of C can be obtained by solving the least squares regression: min C &&&XC> −T> (3) &&& 2 , (1) where the design matrix X = B ⊙A is the KRP of A and B, and T(3) is the matricization of T [21]. 3 Near-optimal Leverage Score Estimation for Khatri-Rao Product As shown in Section 2, the matrix KRP captures the essential interactions between the factor matrices in the tensor CP decomposition. This task is challenging because the size of KRP of two matrices is significantly larger than the input matrices. For example, for the amazon review data, the KRP of two factor matrices contains 1012 rows, which is much larger than the data set itself with 109 nonzeros. Importance sampling is one of the most powerful tools for obtaining sample efficient randomized data reductions with strong guarantees. However, effective implementation requires comprehensive knowledge on the objects to be sampled: the KRP of factor matrices. In this section, we provide an efficient and effective toolset for estimating the statistical leverage scores of the KRP of factor matrices, giving a direct way of applying importance sampling, one of the most important tools in randomized matrix algorithms, for tensor CP decomposition related applications. In the remainder of this section, we first define and discuss the optimal importance: statistical leverage score, in the context of `2-regression. Then we propose and prove our near-optimal leverage score estimation routine. 3.1 Leverage Score Sampling for `2-regression It is known that, when p ⌧n, subsampling the rows of design matrix X 2 Rn⇥p by its statistical leverage score and solving on the samples provides efficient approximate solution to the least square regression problem: minβ kXβ −yk2 2, with strong theoretical guarantees [23]. 3 Definition 3.1 (Statistical Leverage Score). Given an n ⇥r matrix X, with n > r, let U denote the n ⇥r matrix consisting of the top-r left singular vectors of X. Then, the quantity ⌧i = kUi,:k2 2, where Ui,: denotes the i-th row of U, is the statistical leverage score of the i-th row of X. The statistical leverage score of a certain row captures importance of the row in forming the linear subspace. Its optimality in solving `2-regression can be explained by the subspace projection nature of linear regression. It does not yield an efficient algorithm for the optimization problem in Equation (1) due to the difficulties of computing statistical leverage scores. But this reduction to the matrix setting allows for speedups using a variety of tools. In particular, sketching [6, 25, 27] or iterative sampling [22, 9] lead to routines that run in input sparsity time: O(nnz) plus the cost of solving an O(r log n) sized least squares problem. However, directly applying these methods still require at least one pass over T at each iteration, which will dominate the overall cost. 3.2 Near-optimal Leverage Score Estimation As discussed in the previous section, the KRPs of factor matrices capture the interaction between two modes in the tensor CP decomposition, e.g., the design matrix B ⊙A in the linear regression problem. To extract a compact representation of the interaction, the statistical leverage scores of B⊙A provide an informative distribution over the rows, which can be utilized to select the important subsets of rows randomly. For a matrix with IJ rows in total, e.g., B ⊙A, in general, the calculation of statistical leverage score is prohibitively expensive. However, due to the special structure of the KRP B ⊙A, the upper bound of statistical leverage score, which is sufficient to obtain the same guarantee by using slightly more samples, can be efficiently estimated, as shown in Theorem 3.2. Theorem 3.2 (Khatri-Rao Bound). For matrix A 2 RI⇥R and matrix B 2 RJ⇥R, where I > R and J > R, let ⌧A i and ⌧B j be the statistical leverage score of the i-th and j-th row of A and B, respectively. Then, for statistical leverage score of the (iJ + j)-th row of matrix A ⊙B, ⌧A⊙B i,j , we have ⌧A⌦B i,j ⌧A i ⌧B j . Proof. Let the singular value decomposition of A and B be A = Ua⇤aVa> and B = Ub⇤bVb>, where Ua 2 RI⇥R, Ub 2 RJ⇥R, and ⇤a, ⇤b, Va, Vb 2 RR⇥R. By the definition of Khatri-Rao product, we have that A ⊙B = [A:,1 ⌦B:,1, . . . , A:,R ⌦B:,R] 2 RIJ⇥R, where ⌦is the Kronecker product. By the form of SVD and Lemma B.1, we have A ⊙B =[Ua⇤a(Va 1,:)> ⌦Ub⇤b(Vb 1,:)>, . . . , Ua⇤a(Va R,:)> ⌦Ub⇤b(Vb R,:)>] = h (Ua⇤a) ⌦(Ub⇤b) i ⇣ Va> ⊙Vb>⌘ = h Ua ⌦Ubi h ⇤a ⌦⇤bi ⇣ Va> ⊙Vb>⌘ = h Ua ⌦Ubi S, where S = ⇥ ⇤a ⌦⇤b⇤⇣ Va> ⊙Vb>⌘ 2 RR2⇥R . So the SVD of A ⊙B can be constructed using the SVD of S = Us⇤sV> s . So the leverage score of A ⊙B can be computed from [Ua ⌦Ub] Us: H = [Ua ⌦Ub] UsU> s [Ua ⌦Ub]> , (2) and for the index k = iJ + j, we have ⌧A⊙B i,j = Hk,k = e> k Hek '''' h Ua ⌦Ubi> ek '''' 2 2 (3) = R X p=1 R X q=1 (Ua i,p)2(Ub j,q) 2 = ( R X p=1 (Ua i,p)2)( R X q=1 (Ub j,q) 2) = ⌧A i ⌧B j , (4) where ei is the i-th natural basis vector. The first inequality is because H 4 [Ua ⌦Ub] [Ua ⌦Ub]> . 4 Algorithm 1 Sample a row from B ⊙A and T(3). Draw a Bernoulli random variable z ⇠Bernoulli(β). if z = 0 then Draw i ⇠Multi(⌧A 1 /R, . . . , ⌧A I /R) and j ⇠Multi(⌧B 1 /R, . . . , ⌧B J /R). else Draw a entry (i, j, k) from the nonzero entries with probability proportional to T 2 i,j,k. end if Return the (jI + i)-th row of B ⊙A and T(3) with weight IJpi,j. For the rank-R CP decomposition, the sum of the leverage scores for all rows in B ⊙A equals R. The sum of our upper bound relaxes it to R2, which means that now we need ˜O(R2) samples instead of ˜O(R). This result directly generalizes to the Khatri-Rao product of k-dimensional tensors. The proof is provided in Appendix C. Theorem 3.3. For matrices A(k) 2 RIk⇥R where Ik > R for k = 1, . . . , K, let ⌧(k) i be the statistical leverage score of the i-th row of A(k). Then, for the Q k Ik-by-R matrix A(1) ⊙A(2) ⊙· · · ⊙A(K) with statistical leverage score ⌧i1,...,iK for the row corresponding to ⌧i1,...,iK, we have ⌧1:K i1,...,iK K Y k=1 ⌧(k) ik , where ⌧1:K i1,...,iK denotes the statistical leverage score of the row of A(1) ⊙A(2) ⊙· · · ⊙A(K) corresponding to the ik-th row of A(k) for k = 1, . . . , K. Our estimation enables the development of efficient numerical algorithms and is nearly optimal in three ways: 1. The estimation can be calculated in sublinear time given that max{I, J, K} = o (nnz(T )). For instance, for the amazon review data, we have max{I, J, K} ⇡106 ⌧nnz(T ) ⇡109; 2. The form of the estimation allows efficient sample-drawing. In fact, the row index can be drawn efficiently by considering each mode independently; 3. The estimation is tight up to a constant factor R. And R is considered as modest constant for low-rank decomposition. Therefore, the estimation allows sample-efficient importance sampling. 4 SPALS: Sampling Alternating Least Squares The direct application of our results on KRP leverage score estimation is an efficient version of the ALS algorithm for tensor CP decomposition, where the computational bottleneck is to solve the optimization problem 1. Our main algorithmic result is a way to obtain a high quality O(r2 log n) row sample of X without explicitly constructing the matrix X. This is motivated by a recent work that implicitly generates sparsifiers for multistep random walks [4]. In particular, we sample the rows of X, the KRP of A and B, using products of quantities computed on the corresponding rows in A and B, which provides a rank-1 approximation to the optimal importance: the statistical leverage scores. This leads to a sublinear time sampling routine, and implies that we can approximate the progress of each ALS step linear in the size of the factor being updated, which can be sublinear in the number of non-zeros in T . In the remainder of this section, we present our algorithm SPALS and prove its approximation guarantee. We will also discuss its extension to other tensor related applications. 4.1 Sampling Alternating Least Squares The optimal solution to optimization problem (1) is C = T(3) (B ⊙A) ⇥* A>A + ⇤ * B>B +⇤−1 . We separate the calculation into two parts: (1) T(3) (B ⊙A), and (2) ⇥* A>A + ⇤ * B>B +⇤−1, where ⇤denotes the elementwise matrix product. The latter is to invert the gram matrix of the Khatri-Rao 5 product, which can also be efficiently computed due to its R ⇥R size. We will mostly focus on evaluating the former expression. We perform the matrix multiplication by drawing a few rows from both T> (3) and B⊙A and construct the final solution from the subset of rows. The row of B⊙A can be indexed by (i, j) for i = 1, . . . , I and j = 1, . . . , J, which correspond to the i-th and j-th row in A and B, respectively. That is, our sampling problem can be seen as to sample the entries of a I ⇥J matrix P = {pi,j}i,j. We define the sampling probability pi,j as follows, pi,j = (1 −β) ⌧A i ⌧B j R2 + β PK k=1 T 2 i,j,k kT k2 . (5) where β 2 (0, 1). The first term is a rank-1 component for matrix P. And when the input tensor is sparse, the second term is sparse, thus admitting the sparse plus low rank structure, which can be easily sampled as the mixture of two simple distributions. The sampling algorithm is described in Algorithm 1. Note that sampling by the leverage scores of the design matrix B ⊙A alone provides a guaranteed but worse approximation for each step [23]. Since that the design matrix itself is formed by two factor matrices, i.e., we are not directly utilizing the information in the data, we design the second term for the worst case scenario. When R ⌧n and n ⌧nnz(T ), where n = max(I, J, K), we can afford to calculate ⌧A i and ⌧B j exactly in each iteration. So the distribution corresponding to the first term can be efficiently sampled with preparation cost ˜O(r2n + r3) and per-sample-cost O(log n). Note that the second term requires a one-time O(nnz(T )) preprocessing before the first iteration. 4.2 Approximation Guarantees We define the following conditions: C1. The sampling probability pi,j satisfies pi,j ≥β1 ⌧A⊙B i,j R for some constant β1; C2. The sampling probability pi,j satisfies pi,j ≥β2 PK k=1 T 2 i,j,k kT k2 for some constant β2; The proposed probabilities pi,j in Equation (5) satisfy both conditions with β1 = (1 −β)/R and β2 = β. We can now prove our main approximation result. Theorem 4.1. For a tensor T 2 RI⇥J⇥K with n = max(I, J, K) and any factor matrices on the first two dimension as A 2 RI⇥R and B 2 RJ⇥R. If a step of ALS on the third dimension gives Copt, then a step of SPALS that samples m = ⇥(R2 log n/✏2) rows produces C satisfying &&T − q A, B, C y&&2 < kT −JA, B, CoptKk2 + ✏kT k2. Proof. Denote the sample-and-rescale matrix as S 2 Rm⇥IJ. By Corollary E.3, we have that &&T(3) (B ⊙A) −T(3)S>S (B ⊙A) && ✏kT k. Together with Lemma E.1, we can conclude. Note that the approximation error of our algorithm does not accumulate over iterations. Similar to the stochastic gradient descent algorithm, the error occurred in the previous iterations can be addressed in the subsequent iterations. 4.3 Extensions on Other Tensor Related Applications Importance Sampling SGD on CP Decompostion We can incorporate importance sampling in the stochastic gradient descent algorithm for CP decomposition. The gradient follows the form @ @CkT −JA, B, CKk2 = T(3) (B ⊙A) . By sampling rows according to proposed distribution, it reduces the per-step variance via importance sampling [26]. Our result addresses the computational difficulty of finding the appropriate importance. Sampling ALS on Higher-Order Singular Value Decomposition (HOSVD) For solving the HOSVD [13] on tensor, the Kronecker product is involved instead of the Khatri-Rao product. In Appendix D, we prove similar leverage score approximation results for Kronecker product. In fact, for Kronecker product, our “approximation” provides the exact leverage score. 6 Theorem 4.2. For matrix A 2 RI⇥M and matrix B 2 RJ⇥N, where I > M and J > N, let ⌧A i and ⌧B j be the statistical leverage score of the i-th and j-th row of A and B, respectively. Then, for matrix A ⌦B 2 RIJ⇥MN with statistical leverage score ⌧A⌦B i,j for the (iJ + j)-th row, we have ⌧A⌦B i,j = ⌧A i ⌧B j . 5 Related Works CP decomposition is one of the simplest, most easily-interpretable tensor decomposition. Fitting it in an ALS fashion is still considered as the state-of-art in the recent tensor analytics literature [37]. The most widely used implementation of ALS is the MATLAB Tensor Toolbox [21]. It directly performs the analytic solution of ALS steps. There is a line of work on speeding up this procedure in distributed/parallel/MapReduce settings [20, 19, 5, 33]. Such approaches are compatible with our approach, as we directly reduce the number of steps by sampling. A similar connection holds for works achieving more efficient computation of KRP steps of the ALS algorithm such as in [32]. The applicability of randomized numerical linear algebra tools to tensors was studied during their development [28]. Within the context of sampling-based tensor decomposition, early work has been published in [36, 35] that focuses though on Tucker decomposition. In [30], sampling is used as a means of extracting small representative sub-tensors out of the initial input, which are further decomposed via the standard ALS and carefully merged to form the output. Another work based on an a-priori sampling of the input tensor can be found in [2]. However, recent developments in randomized numerical linear algebra often focused on over-constrained regression problems or low rank matrices. The incorporation of such tools into tensor analytics routines was fairly recent [31, 37] Most closely related to our algorithm are the routines from [37], which gave a sketch-based CP decomposition inspired by the earlier work in [31]. Both approaches only need to examine the factorization at each iteration, followed by a number of updates that only depends on rank. A main difference is that the sketches in [37] moves the non-zeroes, while our sampling approach removes many entries instead. Their algorithm also performs a subsequent FFT step, while our routine always works on subsets of the matricizations. Our method is much more suitable for sparse tensors. Also, our routine can be considered as data dependent randomization, which enjoys better approximation accuracy than [37] in the worst case. For direct comparison, the method in [37] and ours both require nnz(T ) preprocessing at the beginning. Then, for each iteration, our method requires ˜O(nr3) operations comparing with O(r(n + Bb log b) + r3) for [37]. Here B and b for [37] are parameters for the sketching and need to be tuned for various applications. Depending on the target accuracy, b can be as large as the input size: on the cube synthetic tensors with n = 103 that the experiments in [37] focused on, b was set to between 214 ⇡⇥103 and 216 ⇡6 ⇥104 in order to converge to good relative errors. From a distance, our method can be viewed as incorporating randomization into the intermediate steps of algorithms, and can be viewed as higher dimensional analogs of weighted SGD algorithms [39]. Compared to more global uses of randomization [38], these more piecemeal invocations have several advantages. For high dimensional tensors, sketching methods need to preserve all dimensions, while the intermediate problems only involve matrices, and can often be reduced to smaller dimensions. For approximating a rank R tensor in d dimensions to error ✏, this represents the difference between poly(R, ✏) and R ✏ d. Furthermore, the lower cost of each step of alternate minimization makes it much easier to increase accuracy at the last few steps, leading to algorithms that behave the same way in the limit. The wealth of works on reducing sizes of matrices while preserving objectives such as `p norms, hinge losses, and M-estimators [11, 10, 8, 7] also suggest that this approach can be directly adapted to much wider ranges of settings and objectives. 6 Experimental Results We implemented and evaluated our algorithms in a single machine setting. The source code is available online1. Experiments are tested on a single machine with two Intel Xeon E5-2630 v3 CPU and 256GB memory. All methods are implemented in C++ with OpenMP parallelization. We report averages from 5 trials. 1https://github.com/dehuacheng/SpAls 7 Dense Synthetic Tensors We start by comparing our method against the sketching based algorithm from [37] in the single thread setting as in their evaluation. The synthetic data we tested are thirdorder tensors with dimension n = 1000, as described in [37]. We generated a rank-1000 tensor with harmonically decreasing weights on rank-1 components. And then after normalization, random Gaussian noise with noise-to-signal nsr = 0.1, 1, 10 was added. As with previous experimental evaluations [37], we set target rank to r = 10. The performances are given in Table 1a. We vary the sampling rate of our algorithm, i.e., SPALS(↵) will sample ↵r2 log2 n rows at each iteration. nsr = 0.1 nsr = 1 nsr = 10 error time error time error time ALS-dense 0.27 64.8 1.08 66.2 10.08 67.6 sketch(20, 14) 0.45 6.50 1.37 4.70 11.11 4.90 sketch(40, 16) 0.30 16.0 1.13 12.7 10.27 12.4 ALS-sparse 0.24 501 1.09 512 10.15 498 SPALS(0.3) 0.20 1.76 1.14 1.93 10.40 1.92 SPALS(1) 0.18 5.79 1.10 5.64 10.21 5.94 SPALS(3.0) 0.21 15.9 1.09 16.1 10.15 16.16 (a) Running times per iterations in seconds and errors of various alternating least squares implementations error time ALS-sparse 0.981 142 SPALS(0.3) 0.987 6.97 SPALS(1) 0.983 15.7 SPALS(3.0) 0.982 38.9 (b) Relative error and running times per iteration on the Amazon review tensor with dimensions 2.44e6 ⇥6.64e6 ⇥9.26e4 and 2.02 billion non-zeros On these instances, a call to SPALS with rate ↵samples was about 4.77↵⇥103 rows, and as the tensor is dense, 4.77↵⇥106 entries. The correspondence between running times and rates demonstrate the sublinear runtimes of SPALS with low sampling rates. Comparing with the [37], our algorithm employs data dependent random sketch with minimal overhead, which yields significantly better precision with similar amount of computation. Sparse Data Tensor Our original motivation for SPALS was to handle large sparse data tensors. We ran our algorithm on a large-scale tensor generated from Amazon review data [24]. Its sizes and convergences of SPALS with various parameters are in Table 1b. We conduct the experiments in parallel with 16 threads. The Amazon data tensor has a much higher noise to signal ratio than our other experiments which common for large-scale data tensors: Running deterministic ALS with rank 10 on it leads to a relative error of 98.1%. SPALS converges rapidly towards a good approximation with only a small fraction of time comparing with the ALS algorithm. 7 Discussion Our experiments show that SPALS provides notable speedup over previous CP decomposition routines on both dense and sparse data. There are two main sources of speedups: (1) the low target rank and moderate individual dimensions enable us to compute leverage scores efficiently; and (2) the simple representations of the sampled form also allows us to use mostly code from existing ALS routines with minimal computational overhead. It is worth noting that in the dense case, the total number of entries accessed during all 20 iterations is far fewer than the size of T . Nonetheless, the adaptive nature of the sampling scheme means all the information from T are taken into account while generating the first and subsequent iterations. From a randomized algorithms perspective, the sub-linear time sampling steps bear strong resemblances with stochastic optimization routines [34]. We believe more systematically investigating such connections can lead to more direct connections between tensors and randomized numerical linear algebra, and in turn further algorithmic improvements. Acknowledgments This work is supported in part by the U. S. Army Research Office under grant number W911NF-15-10491, NSF Research Grant IIS-1254206 and IIS-1134990. The views and conclusions are those of the authors and should not be interpreted as representing the official policies of the funding agency, or the U.S. Government. References [1] B. Barak, J. A. Kelner, and D. Steurer. Dictionary learning and tensor decomposition via the sum-of-squares method. In STOC, 2015. [2] S. Bhojanapalli and S. Sanghavi. A New Sampling Technique for Tensors. ArXiv e-prints, 2015. [3] J. D. Carroll and J.-J. Chang. Analysis of individual differences in multidimensional scaling via an n-way generalization of “eckart-young” decomposition. Psychometrika, 1970. [4] D. Cheng, Y. Cheng, Y. Liu, R. Peng, and S.-H. Teng. Spectral sparsification of random-walk matrix polynomials. arXiv preprint arXiv:1502.03496, 2015. [5] J. H. Choi and S. Vishwanathan. Dfacto: Distributed factorization of tensors. In NIPS, 2014. 8 [6] K. L. Clarkson and D. P. Woodruff. Low rank approximation and regression in input sparsity time. In STOC, 2013. [7] K. L. Clarkson and D. P. Woodruff. Input sparsity and hardness for robust subspace approximation. In FOCS, 2015. [8] K. L. Clarkson and D. P. Woodruff. Sketching for m-estimators: A unified approach to robust regression. In SODA, 2015. [9] M. B. Cohen, Y. T. Lee, C. Musco, C. Musco, R. Peng, and A. Sidford. Uniform sampling for matrix approximation. In ITCS, 2015. [10] M. B. Cohen and R. Peng. `p row sampling by Lewis weights. In STOC, 2015. [11] A. Dasgupta, P. Drineas, B. Harb, R. Kumar, and M. W. Mahoney. Sampling algorithms and coresets for \ell_p regression. SIAM Journal on Computing, 2009. [12] L. De Lathauwer and B. De Moor. From matrix to tensor: Multilinear algebra and signal processing. In Institute of Mathematics and Its Applications Conference Series, 1998. [13] L. De Lathauwer, B. De Moor, and J. Vandewalle. A multilinear singular value decomposition. SIAM journal on Matrix Analysis and Applications, 2000. [14] V. De Silva and L.-H. Lim. Tensor rank and the ill-posedness of the best low-rank approximation problem. SIAM J. Matrix Anal. Appl., 2008. [15] P. Drineas, M. W. Mahoney, S. Muthukrishnan, and T. Sarlós. Faster least squares approximation. Numerische Mathematik, 2011. [16] R. Ge, F. Huang, C. Jin, and Y. Yuan. Escaping from saddle points - online stochastic gradient for tensor decomposition. In COLT, 2015. [17] R. A. Harshman. Foundations of the parafac procedure: Models and conditions for an" explanatory" multi-modal factor analysis. 1970. [18] C. J. Hillar and L.-H. Lim. Most tensor problems are np-hard. Journal of the ACM (JACM), 2013. [19] I. Jeon, E. E. Papalexakis, U. Kang, and C. Faloutsos. Haten2: Billion-scale tensor decompositions. In ICDE, 2015. [20] U. Kang, E. Papalexakis, A. Harpale, and C. Faloutsos. Gigatensor: scaling tensor analysis up by 100 times-algorithms and discoveries. In KDD, 2012. [21] T. G. Kolda and B. W. Bader. Tensor decompositions and applications. SIAM review, 2009. [22] M. Li, G. Miller, and R. Peng. Iterative row sampling. In FOCS, 2013. [23] M. W. Mahoney. Randomized algorithms for matrices and data. Foundations and Trends R⃝in Machine Learning, 2011. [24] J. McAuley and J. Leskovec. Hidden factors and hidden topics: understanding rating dimensions with review text. In RecSys, 2013. [25] X. Meng and M. W. Mahoney. Low-distortion subspace embeddings in input-sparsity time and applications to robust linear regression. In STOC, 2013. [26] D. Needell, R. Ward, and N. Srebro. Stochastic gradient descent, weighted sampling, and the randomized kaczmarz algorithm. In NIPS, 2014. [27] J. Nelson and H. L. Nguyên. Osnap: Faster numerical linear algebra algorithms via sparser subspace embeddings. In FOCS, 2013. [28] N. H. Nguyen, P. Drineas, and T. D. Tran. Tensor sparsification via a bound on the spectral norm of random tensors. CoRR, 2010. [29] A. Novikov, D. Podoprikhin, A. Osokin, and D. P. Vetrov. Tensorizing neural networks. In NIPS, 2015. [30] E. E. Papalexakis, C. Faloutsos, and N. D. Sidiropoulos. Parcube: Sparse parallelizable tensor decompositions. In Machine Learning and Knowledge Discovery in Databases. Springer, 2012. [31] N. Pham and R. Pagh. Fast and scalable polynomial kernels via explicit feature maps. In KDD, 2013. [32] A.-H. Phan, P. Tichavsky, and A. Cichocki. Fast alternating ls algorithms for high order candecomp/parafac tensor factorizations. Signal Processing, IEEE Transactions on, 2013. [33] S. Smith, N. Ravindran, N. D. Sidiropoulos, and G. Karypis. Splatt: Efficient and parallel sparse tensormatrix multiplication. 29th IEEE International Parallel & Distributed Processing Symposium, 2015. [34] T. Strohmer and R. Vershynin. A randomized kaczmarz algorithm with exponential convergence. JFAA, 2009. [35] J. Sun, S. Papadimitriou, C.-Y. Lin, N. Cao, S. Liu, and W. Qian. Multivis: Content-based social network exploration through multi-way visual analysis. In SDM. SIAM, 2009. [36] C. E. Tsourakakis. Mach: Fast randomized tensor decompositions. In SDM. SIAM, 2010. [37] Y. Wang, H.-Y. Tung, A. J. Smola, and A. Anandkumar. Fast and guaranteed tensor decomposition via sketching. In NIPS, 2015. [38] D. P. Woodruff. Sketching as a tool for numerical linear algebra. Foundations and Trends R⃝in Theoretical Computer Science, 2014. [39] J. Yang, Y. Chow, C. Ré, and M. W. Mahoney. Weighted sgd for `p regression with randomized preconditioning. In SODA, 2016. [40] R. Yu, D. Cheng, and Y. Liu. Accelerated online low rank tensor learning for multivariate spatiotemporal streams. In ICML, pages 238–247, 2015. 9 | 2016 | 550 |
6,495 | On Multiplicative Integration with Recurrent Neural Networks Yuhuai Wu1,∗, Saizheng Zhang2,∗, Ying Zhang2, Yoshua Bengio2,4 and Ruslan Salakhutdinov3,4 1University of Toronto, 2MILA, Université de Montréal, 3Carnegie Mellon University, 4CIFAR ywu@cs.toronto.edu,2{firstname.lastname}@umontreal.ca,rsalakhu@cs.cmu.edu Abstract We introduce a general and simple structural design called “Multiplicative Integration” (MI) to improve recurrent neural networks (RNNs). MI changes the way in which information from difference sources flows and is integrated in the computational building block of an RNN, while introducing almost no extra parameters. The new structure can be easily embedded into many popular RNN models, including LSTMs and GRUs. We empirically analyze its learning behaviour and conduct evaluations on several tasks using different RNN models. Our experimental results demonstrate that Multiplicative Integration can provide a substantial performance boost over many of the existing RNN models. 1 Introduction Recently there has been a resurgence of new structural designs for recurrent neural networks (RNNs) [1, 2, 3]. Most of these designs are derived from popular structures including vanilla RNNs, Long Short Term Memory networks (LSTMs) [4] and Gated Recurrent Units (GRUs) [5]. Despite of their varying characteristics, most of them share a common computational building block, described by the following equation: φ(Wx + Uz + b), (1) where x ∈Rn and z ∈Rm are state vectors coming from different information sources, W ∈Rd×n and U ∈Rd×m are state-to-state transition matrices, and b is a bias vector. This computational building block serves as a combinator for integrating information flow from the x and z by a sum operation “+”, followed by a nonlinearity φ. We refer to it as the additive building block. Additive building blocks are widely implemented in various state computations in RNNs (e.g. hidden state computations for vanilla-RNNs, gate/cell computations of LSTMs and GRUs. In this work, we propose an alternative design for constructing the computational building block by changing the procedure of information integration. Specifically, instead of utilizing sum operation “+", we propose to use the Hadamard product “⊙” to fuse Wx and Uz: φ(Wx ⊙Uz + b) (2) The result of this modification changes the RNN from first order to second order [6], while introducing no extra parameters. We call this kind of information integration design a form of Multiplicative Integration. The effect of multiplication naturally results in a gating type structure, in which Wx and Uz are the gates of each other. More specifically, one can think of the state-to-state computation Uz (where for example z represents the previous state) as dynamically rescaled by Wx (where for example x represents the input). Such rescaling does not exist in the additive building block, in which Uz is independent of x. This relatively simple modification brings about advantages over the additive building block as it alters RNN’s gradient properties, which we discuss in detail in the next section, as well as verify through extensive experiments. ∗Equal contribution. 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. In the following sections, we first introduce a general formulation of Multiplicative Integration. We then compare it to the additive building block on several sequence learning tasks, including character level language modelling, speech recognition, large scale sentence representation learning using a Skip-Thought model, and teaching a machine to read and comprehend for a question answering task. The experimental results (together with several existing state-of-the-art models) show that various RNN structures (including vanilla RNNs, LSTMs, and GRUs) equipped with Multiplicative Integration provide better generalization and easier optimization. Its main advantages include: (1) it enjoys better gradient properties due to the gating effect. Most of the hidden units are non-saturated; (2) the general formulation of Multiplicative Integration naturally includes the regular additive building block as a special case, and introduces almost no extra parameters compared to the additive building block; and (3) it is a drop-in replacement for the additive building block in most of the popular RNN models, including LSTMs and GRUs. It can also be combined with other RNN training techniques such as Recurrent Batch Normalization [7]. We further discuss its relationship to existing models, including Hidden Markov Models (HMMs) [8], second order RNNs [6] and Multiplicative RNNs [9]. 2 Structure Description and Analysis 2.1 General Formulation of Multiplicative Integration The key idea behind Multiplicative Integration is to integrate different information flows Wx and Uz, by the Hadamard product “⊙”. A more general formulation of Multiplicative Integration includes two more bias vectors β1 and β2 added to Wx and Uz: φ((Wx + β1) ⊙(Uz + β2) + b) (3) where β1, β2 ∈Rd are bias vectors. Notice that such formulation contains the first order terms as in a additive building block, i.e., β1 ⊙Uht−1 + β2 ⊙Wxt. In order to make the Multiplicative Integration more flexible, we introduce another bias vector α ∈Rd to gate2 the term Wx ⊙Uz, obtaining the following formulation: φ(α ⊙Wx ⊙Uz + β1 ⊙Uz + β2 ⊙Wx + b), (4) Note that the number of parameters of the Multiplicative Integration is about the same as that of the additive building block, since the number of new parameters (α, β1 and β2) are negligible compared to total number of parameters. Also, Multiplicative Integration can be easily extended to LSTMs and GRUs3, that adopt vanilla building blocks for computing gates and output states, where one can directly replace them with the Multiplicative Integration. More generally, in any kind of structure where k information flows (k ≥2) are involved (e.g. residual networks [10]), one can implement pairwise Multiplicative Integration for integrating all k information sources. 2.2 Gradient Properties The Multiplicative Integration has different gradient properties compared to the additive building block. For clarity of presentation, we first look at vanilla-RNN and RNN with Multiplicative Integration embedded, referred to as MI-RNN. That is, ht = φ(Wxt + Uht−1 + b) versus ht = φ(Wxt ⊙Uht−1 + b). In a vanilla-RNN, the gradient ∂ht ∂ht−n can be computed as follows: ∂ht ∂ht−n = tY k=t−n+1 UT diag(φ′ k), (5) where φ′ k = φ′(Wxk + Uhk−1 + b). The equation above shows that the gradient flow through time heavily depends on the hidden-to-hidden matrix U, but W and xk appear to play a limited role: they only come in the derivative of φ′ mixed with Uhk−1. On the other hand, the gradient ∂ht ∂ht−n of a MI-RNN is4: ∂ht ∂ht−n = tY k=t−n+1 UT diag(Wxk)diag(φ′ k), (6) 2If α = 0, the Multiplicative Integration will degenerate to the vanilla additive building block. 3See exact formulations in the Appendix. 4Here we adopt the simplest formulation of Multiplicative Integration for illustration. In the more general case (Eq. 4), diag(Wxk) in Eq. 6 will become diag(α ⊙Wxk + β1). 2 where φ′ k = φ′(Wxk ⊙Uhk−1 + b). By looking at the gradient, we see that the matrix W and the current input xk is directly involved in the gradient computation by gating the matrix U, hence more capable of altering the updates of the learning system. As we show in our experiments, with Wxk directly gating the gradient, the vanishing/exploding problem is alleviated: Wxk dynamically reconciles U, making the gradient propagation easier compared to the regular RNNs. For LSTMs and GRUs with Multiplicative Integration, the gradient propagation properties are more complicated. But in principle, the benefits of the gating effect also persists in these models. 3 Experiments In all of our experiments, we use the general form of Multiplicative Integration (Eq. 4) for any hidden state/gate computations, unless otherwise specified. 3.1 Exploratory Experiments To further understand the functionality of Multiplicative Integration, we take a simple RNN for illustration, and perform several exploratory experiments on the character level language modeling task using Penn-Treebank dataset [11], following the data partition in [12]. The length of the training sequence is 50. All models have a single hidden layer of size 2048, and we use Adam optimization algorithm [13] with learning rate 1e−4. Weights are initialized to samples drawn from uniform[−0.02, 0.02]. Performance is evaluated by the bits-per-character (BPC) metric, which is log2 of perplexity. 3.1.1 Gradient Properties To analyze the gradient flow of the model, we divide the gradient in Eq. 6 into two parts: 1. the gated matrix products: UT diag(Wxk), and 2. the derivative of the nonlinearity φ′, We separately analyze the properties of each term compared to the additive building block. We first focus on the gating effect brought by diag(Wxk). In order to separate out the effect of nonlinearity, we chose φ to be the identity map, hence both vanilla-RNN and MI-RNN reduce to linear models, referred to as lin-RNN and lin-MI-RNN. For each model we monitor the log-L2-norm of the gradient log ||∂C/∂ht||2 (averaged over the training set) after every training epoch, where ht is the hidden state at time step t, and C is the negative log-likelihood of the single character prediction at the final time step (t = 50). Figure. 1 shows the evolution of the gradient norms for small t, i.e., 0, 5, 10, as they better reflect the gradient propagation behaviour. Observe that the norms of lin-MI-RNN (orange) increase rapidly and soon exceed the corresponding norms of lin-RNN by a large margin. The norms of lin-RNN stay close to zero (≈10−4) and their changes over time are almost negligible. This observation implies that with the help of diag(Wxk) term, the gradient vanishing of lin-MI-RNN can be alleviated compared to lin-RNN. The final test BPC (bits-per-character) of lin-MI-RNN is 1.48, which is comparable to a vanilla-RNN with stabilizing regularizer [14], while lin-RNN performs rather poorly, achieving a test BPC of over 2. Next we look into the nonlinearity φ. We chose φ = tanh for both vanilla-RNN and MI-RNN. Figure 1 (c) and (d) shows a comparison of histograms of hidden activations over all time steps on the validation set after training. Interestingly, in (c) for vanilla-RNN, most activations are saturated with values around ±1, whereas in (d) for MI-RNN, most activations are non-saturated with values around 0. This has a direct consequence in gradient propagation: non-saturated activations imply that diag(φ′ k) ≈1 for φ = tanh, which can help gradients propagate, whereas saturated activations imply that diag(φ′ k) ≈0, resulting in gradients vanishing. 3.1.2 Scaling Problem When adding two numbers at different order of magnitude, the smaller one might be negligible for the sum. However, when multiplying two numbers, the value of the product depends on both regardless of the scales. This principle also applies when comparing Multiplicative Integration to the additive building blocks. In this experiment, we test whether Multiplicative Integration is more robust to the scales of weight values. Following the same models as in Section 3.1.1, we first calculated the norms of Wxk and Uhk−1 for both vanilla-RNN and MI-RNN for different k after training. We found that in both structures, Wxk is a lot smaller than Uhk−1 in magnitude. This might be due to the fact that xk is a one-hot vector, making the number of updates for (columns of) W be smaller than U. As a result, in vanilla-RNN, the pre-activation term Wxk + Uhk−1 is largely controlled by the value of Uhk−1, while Wxk becomes rather small. In MI-RNN, on the other hand, the pre-activation term Wxk ⊙Uhk−1 still depends on the values of both Wxk and Uhk−1, due to multiplication. 3 5 10 15 20 25 number of epochs −7 −6 −5 −4 −3 −2 −1 log||dC / dh_t||_2 (a) lin-RNN, t=0 lin-RNN, t=5 lin-RNN, t=10 lin-MI-RNN, t=0 lin-MI-RNN, t=5 lin-MI-RNN, t=10 0 5 10 15 20 25 number of epochs 1.5 1.8 2.1 2.4 2.7 3.0 validation BPC (b) vanilla-RNN MI-RNN-simple MI-RNN-general −1.0 −0.5 0.0 0.5 1.0 activation values of h_t 0.0 0.1 0.2 0.3 0.4 0.5 normalized fequency (d) −1.0 −0.5 0.0 0.5 1.0 activation values of h_t 0.00 0.02 0.04 0.06 0.08 0.10 0.12 normalized fequency (d) Figure 1: (a) Curves of log-L2-norm of gradients for lin-RNN (blue) and lin-MI-RNN (orange). Time gradually changes from {1, 5, 10}. (b) Validation BPC curves for vanilla-RNN, MI-RNN-simple using Eq. 2, and MIRNN-general using Eq. 4. (c) Histogram of vanilla-RNN’s hidden activations over the validation set, most activations are saturated. (d) Histogram of MI-RNN’s hidden activations over the validation set, most activations are not saturated. We next tried different initialization of W and U to test their sensitivities to the scaling. For each model, we fix the initialization of U to uniform[−0.02, 0.02] and initialize W to uniform[−rW, rW] where rW varies in {0.02, 0.1, 0.3, 0.6}. Table 1, top left panel, shows results. As we increase the scale of W, performance of the vanilla-RNN improves, suggesting that the model is able to better utilize the input information. On the other hand, MI-RNN is much more robust to different initializations, where the scaling has almost no effect on the final performance. 3.1.3 On different choices of the formulation In our third experiment, we evaluated the performance of different computational building blocks, which are Eq. 1 (vanilla-RNN), Eq. 2 (MI-RNN-simple) and Eq. 4 (MI-RNN-general)5. From the validation curves in Figure 1 (b), we see that both MI-RNN, simple and MI-RNN-general yield much better performance compared to vanilla-RNN, and MI-RNN-general has a faster convergence speed compared to MI-RNN-simple. We also compared our results to the previously published models in Table 1, bottom left panel, where MI-RNN-general achieves a test BPC of 1.39, which is to our knowledge the best result for RNNs on this task without complex gating/cell mechanisms. 3.2 Character Level Language Modeling In addition to the Penn-Treebank dataset, we also perform character level language modeling on two larger datasets: text86 and Hutter Challenge Wikipedia7. Both of them contain 100M characters from Wikipedia while text8 has an alphabet size of 27 and Hutter Challenge Wikipedia has an alphabet size of 205. For both datasets, we follow the training protocols in [12] and [1] respectively. We use Adam for optimization with the starting learning rate grid-searched in {0.002, 0.001, 0.0005}. If the validation BPC (bits-per-character) does not decrease for 2 epochs, we half the learning rate. We implemented Multiplicative Integration on both vanilla-RNN and LSTM, referred to as MIRNN and MI-LSTM. The results for the text8 dataset are shown in Table 1, bottom middle panel. All five models, including some of the previously published models, have the same number of 5We perform hyper-parameter search for the initialization of {α, β1, β2, b} in MI-RNN-general. 6http://mattmahoney.net/dc/textdata 7http://prize.hutter1.net/ 4 rW = 0.02 0.1 0.3 0.6 std RNN 1.69 1.65 1.57 1.54 0.06 MI-RNN 1.39 1.40 1.40 1.41 0.008 WSJ Corpus CER WER DRNN+CTCbeamsearch [15] 10.0 14.1 Encoder-Decoder [16] 6.4 9.3 LSTM+CTCbeamsearch [17] 9.2 8.7 Eesen [18] 7.3 LSTM+CTC+WFST (ours) 6.5 8.7 MI-LSTM+CTC+WFST (ours) 6.0 8.2 Penn-Treebank BPC RNN [12] 1.42 HF-MRNN [12] 1.41 RNN+stabalization [14] 1.48 MI-RNN (ours) 1.39 linear MI-RNN (ours) 1.48 text8 BPC RNN+smoothReLu [19] 1.55 HF-MRNN [12] 1.54 MI-RNN (ours) 1.52 LSTM (ours) 1.51 MI-LSTM(ours) 1.44 HutterWikipedia BPC stacked-LSTM [20] 1.67 GF-LSTM [1] 1.58 grid-LSTM [2] 1.47 MI-LSTM (ours) 1.44 Table 1: Top: test BPCs and the standard deviation of models with different scales of weight initializations. Top right: test CERs and WERs on WSJ corpus. Bottom left: test BPCs on character level Penn-Treebank dataset. Bottom middle: test BPCs on character level text8 dataset. Bottom right: test BPCs on character level Hutter Prize Wikipedia dataset. parameters (≈4M). For RNNs without complex gating/cell mechanisms (the first three results), our MI-RNN (with {α, β1, β2, b} initialized as {2, 0.5, 0.5, 0}) performs the best, our MI-LSTM (with {α, β1, β2, b} initialized as {1, 0.5, 0.5, 0}) outperforms all other models by a large margin8. On Hutter Challenge Wikipedia dataset, we compare our MI-LSTM (single layer with 2048 unit, ≈17M, with {α, β1, β2, b} initialized as {1, 1, 1, 0}) to the previous stacked LSTM (7 layers, ≈27M) [20], GF-LSTM (5 layers, ≈20M) [1], and grid-LSTM (6 layers, ≈17M) [2]. Table 1, bottom right panel, shows results. Despite the simple structure compared to the sophisticated connection designs in GF-LSTM and grid-LSTM, our MI-LSTM outperforms all other models and achieves the new state-of-the-art on this task. 3.3 Speech Recognition We next evaluate our models on Wall Street Journal (WSJ) corpus (available as LDC corpus LDC93S6B and LDC94S13B), where we use the full 81 hour set “si284” for training, set “dev93” for validation and set “eval92” for test. We follow the same data preparation process and model setting as in [18], and we use 59 characters as the targets for the acoustic modelling. Decoding is done with the CTC [21] based weighted finite-state transducers (WFSTs) [22] as proposed by [18]. Our model (referred to as MI-LSTM+CTC+WFST) consists of 4 bidirectional MI-LSTM layers, each with 320 units for each direction. CTC is performed on top to resolve the alignment issue in speech transcription. For comparison, we also train a baseline model (referred to as LSTM+CTC+WFST) with the same size but using vanilla LSTM. Adam with learning rate 0.0001 is used for optimization and Gaussian weight noise with zero mean and 0.05 standard deviation is injected for regularization. We evaluate our models on the character error rate (CER) without language model and the word error rate (WER) with extended trigram language model. Table 1, top right panel, shows that MI-LSTM+CTC+WFST achieves quite good results on both CER and WER compared to recent works, and it has a clear improvement over the baseline model. Note that we did not conduct a careful hyper-parameter search on this task, hence one could potentially obtain better results with better decoding schemes and regularization techniques. 3.4 Learning Skip-Thought Vectors Next, we evaluate our Multiplicative Integration on the Skip-Thought model of [23]. Skip-Thought is an encoder-decoder model that attempts to learn generic, distributed sentence representations. The model produces sentence representation that are robust and perform well in practice, as it achieves excellent results across many different NLP tasks. The model was trained on the BookCorpus dataset that consists of 11,038 books with 74,004,228 sentences. Not surprisingly, a single pass through 8[7] reports better results but they use much larger models (≈16M) which is not directly comparable. 5 Semantic-Relatedness r ρ MSE uni-skip [23] 0.8477 0.7780 0.2872 bi-skip [23] 0.8405 0.7696 0.2995 combine-skip [23] 0.8584 0.7916 0.2687 uni-skip (ours) 0.8436 0.7735 0.2946 MI-uni-skip (ours) 0.8588 0.7952 0.2679 Paraphrase detection Acc F1 uni-skip [23] 73.0 81.9 bi-skip [23] 71.2 81.2 combine-skip [23] 73.0 82.0 uni-skip (ours) 74.0 81.9 MI-uni-skip (ours) 74.0 82.1 Classification MR CR SUBJ MPQA uni-skip [23] 75.5 79.3 92.1 86.9 bi-skip [23] 73.9 77.9 92.5 83.3 combine-skip [23] 76.5 80.1 93.6 87.1 uni-skip (ours) 75.9 80.1 93.0 87.0 MI-uni-skip (ours) 77.9 82.3 93.3 88.1 Attentive Reader Val. Err. LSTM [7] 0.5033 BN-LSTM [7] 0.4951 BN-everywhere [7] 0.5000 LSTM (ours) 0.5053 MI-LSTM (ours) 0.4721 MI-LSTM+BN (ours) 0.4685 MI-LSTM+BN-everywhere (ours) 0.4644 Table 2: Top left: skip-thought+MI on Semantic-Relatedness task. Top Right: skip-thought+MI on Paraphrase Detection task. Bottom left: skip-thought+MI on four different classification tasks. Bottom right: Multiplicative Integration (with batch normalization) on Teaching Machines to Read and Comprehend task. the training data can take up to a week on a high-end GPU (as reported in [23]). Such training speed largely limits one to perform careful hyper-parameter search. However, with Multiplicative Integration, not only the training time is shortened by a factor of two, but the final performance is also significantly improved. We exactly follow the authors’ Theano implementation of the skip-thought model9: Encoder and decoder are single-layer GRUs with hidden-layer size of 2400; all recurrent matrices adopt orthogonal initialization while non-recurrent weights are initialized from uniform distribution. Adam is used for optimization. We implemented Multiplicative Integration only for the encoder GRU (embedding MI into decoder did not provide any substantial gains). We refer our model as MI-uni-skip, with {α, β1, β2, b} initialized as {1, 1, 1, 0}. We also train a baseline model with the same size, referred to as uni-skip(ours), which essentially reproduces the original model of [23]. During the course of training, we evaluated the skip-thought vectors on the semantic relatedness task, using SICK dataset, every 2500 updates for both MI-uni-skip and the baseline model (each iteration processes a mini-batch of size 64). The results are shown in Figure 2a. Note that MI-uni-skip significantly outperforms the baseline, not only in terms of speed of convergence, but also in terms of final performance. At around 125k updates, MI-uni-skip already exceeds the best performance achieved by the baseline, which takes about twice the number of updates. We also evaluated both models after one week of training, with the best results being reported on six out of eight tasks reported in [23]: semantic relatedness task on SICK dataset, paraphrase detection task on Microsoft Research Paraphrase Corpus, and four classification benchmarks: movie review sentiment (MR), customer product reviews (CR), subjectivity/objectivity classification (SUBJ), and opinion polarity (MPQA). We also compared our results with the results reported on three models in the original skip-thought paper: uni-skip, bi-skip, combine-skip. Uni-skip is the same model as our baseline, bi-skip is a bidirectional model of the same size, and combine-skip takes the concatenation of the vectors from uni-skip and bi-skip to form a 4800 dimension vector for task evaluation. Table 2 shows that MI-uni-skip dominates across all the tasks. Not only it achieves higher performance than the baseline model, but in many cases, it also outperforms the combine-skip model, which has twice the number of dimensions. Clearly, Multiplicative Integration provides a faster and better way to train a large-scale Skip-Thought model. 3.5 Teaching Machines to Read and Comprehend In our last experiment, we show that the use of Multiplicative Integration can be combined with other techniques for training RNNs, and the advantages of using MI still persist. Recently, [7] introduced Recurrent Batch-Normalization. They evaluated their proposed technique on a uni9https://github.com/ryankiros/skip-thoughts 6 0 50 100 150 200 250 number of iterations (2.5k) 0.26 0.28 0.30 0.32 0.34 0.36 MSE (a) uni-skip (ours) MI-uni-skip (ours) 0 200 400 600 800 number of iterations (1k) 0.45 0.50 0.55 0.60 0.65 0.70 validation error (b) LSTM [7] BN-LSTM [7] MI-LSTM (ours) MI-LSTM+BN (ours) Figure 2: (a) MSE curves of uni-skip (ours) and MI-uni-skip (ours) on semantic relatedness task on SICK dataset. MI-uni-skip significantly outperforms baseline uni-skip. (b) Validation error curves on attentive reader models. There is a clear margin between models with and without MI. directional Attentive Reader Model [24] for the question answering task using the CNN corpus10. To test our approach, we evaluated the following four models: 1. A vanilla LSTM attentive reader model with a single hidden layer size 240 (same as [7]) as our baseline, referred to as LSTM (ours), 2. A multiplicative integration LSTM with a single hidden size 240, referred to as MI-LSTM, 3. MILSTM with Batch-Norm, referred to as MI-LSTM+BN, 4. MI-LSTM with Batch-Norm everywhere (as detailed in [7]), referred to as MI-LSTM+BN-everywhere. We compared our models to results reported in [7] (referred to as LSTM, BN-LSTM and BN-LSTM everywhere) 11. For all MI models, {α, β1, β2, b} were initialized to {1, 1, 1, 0}. We follow the experimental protocol of [7]12 and use exactly the same settings as theirs, except we remove the gradient clipping for MI-LSTMs. Figure. 2b shows validation curves of the baseline (LSTM), MI-LSTM, BN-LSTM, and MI-LSTM+BN, and the final validation errors of all models are reported in Table 2, bottom right panel. Clearly, using Multiplicative Integration results in improved model performance regardless of whether Batch-Norm is used. However, the combination of MI and Batch-Norm provides the best performance and the fastest speed of convergence. This shows the general applicability of Multiplication Integration when combining it with other optimization techniques. 4 Relationship to Previous Models 4.1 Relationship to Hidden Markov Models One can show that under certain constraints, MI-RNN is effectively implementing the forward algorithm of the Hidden Markov Model(HMM). A direct mapping can be constructed as follows (see [25] for a similar derivation). Let U ∈Rm×m be the state transition probability matrix with Uij = Pr[ht+1 = i|ht = j], W ∈Rm×n be the observation probability matrix with Wij = Pr[xt = i|ht = j]. When xt is a one-hot vector (e.g., in many of the language modelling tasks), multiplying it by W is effectively choosing a column of the observation matrix. Namely, if the jth entry of xt is one, then Wxt = Pr[xt|ht = j]. Let h0 be the initial state distribution with h0 = Pr[h0] and {ht}t≥1 be the alpha values in the forward algorithm of HMM, i.e., ht = Pr[x1, ..., xt, ht]. Then Uht = Pr[x1, ..., xt, ht+1]. Thus ht+1 = Wxt+1 ⊙Uht = Pr[xt+1|ht+1] · Pr[x1, ..., xt, ht+1] = Pr[x1, ..., xt+1, ht+1]. To exactly implement the forward algorithm using Multiplicative Integration, the matrices W and U have to be probability matrices, and xt needs to be a one-hot vector. The function φ needs to be linear, and we drop all the bias terms. Therefore, RNN with Multiplicative Integration can be seen as a nonlinear extension of HMMs. The extra freedom in parameter values and nonlinearity makes the model more flexible compared to HMMs. 4.2 Relations to Second Order RNNs and Multiplicative RNNs MI-RNN is related to the second order RNN [6] and the multiplicative RNN (MRNN) [9]. We first describe the similarities with these two models: The second order RNN involves a second order term st in a vanilla-RNN, where the ith element st,i is computed by the bilinear form: st,i = xT t T (i)ht−1, where T (i) ∈Rn×m(1 ≤i ≤m) is 10Note that [7] used a truncated version of the original dataset in order to save computation. 11Learning curves and the final result number are obtained by emails correspondence with authors of [7]. 12https://github.com/cooijmanstim/recurrent-batch-normalization.git. 7 the ith slice of a tensor T ∈Rm×n×m. Multiplicative Integration also involve a second order term st = α ⊙Wxt ⊙Uht−1, but in our case st,i = αi(wi · xt)(ui · ht−1) = xT t (αwi ⊗ui)ht−1, where wi and ui are ith row in W and U, and αi is the ith element of α. Note that the outer product αiwi ⊗ui is a rank-1 matrix. The Multiplicative RNN is also a second order RNN, but which approximates T by a tensor decomposition P x(i) t T (i) = Pdiag(Vxt)Q. For MI-RNN, we can also think of the second order term as a tensor decomposition: α ⊙Wxt ⊙Uht−1 = U(xt)ht−1 = [diag(α)diag(Wxt)U]ht−1. There are however several differences that make MI a favourable model: (1) Simpler Parametrization: MI uses a rank-1 approximation compared to the second order RNNs, and a diagonal approximation compared to Multiplicative RNN. Moreover, MI-RNN shares parameters across the first and second order terms, whereas the other two models do not. As a result, the number of parameters are largely reduced, which makes our model more practical for large scale problems, while avoiding overfitting. (2) Easier Optimization: In tensor decomposition methods, the products of three different (low-rank) matrices generally makes it hard to optimize [9]. However, the optimization problem becomes easier in MI, as discussed in section 2 and 3. (3) General structural design vs. vanilla-RNN design: Multiplicative Integration can be easily embedded in many other RNN structures, e.g. LSTMs and GRUs, whereas the second order RNN and MRNN present a very specific design for modifying vanilla-RNNs. Moreover, we also compared MI-RNN’s performance to the previous HF-MRNN’s results (Multiplicative RNN trained by Hessian-free method) in Table 1, bottom left and bottom middle panels, on Penn-Treebank and text8 datasets. One can see that MI-RNN outperforms HF-MRNN on both tasks. 4.3 General Multiplicative Integration Multiplicative Integration can be viewed as a general way of combining information flows from two different sources. In particular, [26] proposed the ladder network that achieves promising results on semi-supervised learning. In their model, they combine the lateral connections and the backward connections via the “combinator” function by a Hadamard product. The performance would severely degrade without this product as empirically shown by [27]. [28] explored neural embedding approaches in knowledge bases by formulating relations as bilinear and/or linear mapping functions, and compared a variety of embedding models on the link prediction task. Surprisingly, the best results among all bilinear functions is the simple weighted Hadamard product. They further carefully compare the multiplicative and additive interactions and show that the multiplicative interaction dominates the additive one. 5 Conclusion In this paper we proposed to use Multiplicative Integration (MI), a simple Hadamard product to combine information flow in recurrent neural networks. MI can be easily integrated into many popular RNN models, including LSTMs and GRUs, while introducing almost no extra parameters. Indeed, the implementation of MI requires almost no extra work beyond implementing RNN models. We also show that MI achieves state-of-the-art performance on four different tasks or 11 datasets of varying sizes and scales. We believe that the Multiplicative Integration can become a default building block for training various types of RNN models. Acknowledgments The authors acknowledge the following agencies for funding and support: NSERC, Canada Research Chairs, CIFAR, Calcul Quebec, Compute Canada, Disney research and ONR Grant N000141310721. The authors thank the developers of Theano [29] and Keras [30], and also thank Jimmy Ba for many thought-provoking discussions. References [1] Junyoung Chung, Caglar Gulcehre, Kyunghyun Cho, and Yoshua Bengio. Gated feedback recurrent neural networks. arXiv preprint arXiv:1502.02367, 2015. [2] Nal Kalchbrenner, Ivo Danihelka, and Alex Graves. Grid long short-term memory. arXiv preprint arXiv:1507.01526, 2015. 8 [3] Saizheng Zhang, Yuhuai Wu, Tong Che, Zhouhan Lin, Roland Memisevic, Ruslan Salakhutdinov, and Yoshua Bengio. Architectural complexity measures of recurrent neural networks. arXiv preprint arXiv:1602.08210, 2016. [4] Sepp Hochreiter and Jürgen Schmidhuber. Long short-term memory. Neural computation, 9(8):1735–1780, 1997. [5] Kyunghyun Cho, Bart Van Merriënboer, Caglar Gulcehre, Dzmitry Bahdanau, Fethi Bougares, Holger Schwenk, and Yoshua Bengio. Learning phrase representations using rnn encoder-decoder for statistical machine translation. arXiv preprint arXiv:1406.1078, 2014. [6] Mark W Goudreau, C Lee Giles, Srimat T Chakradhar, and D Chen. First-order versus second-order single-layer recurrent neural networks. Neural Networks, IEEE Transactions on, 5(3):511–513, 1994. [7] Tim Cooijmans, Nicolas Ballas, César Laurent, and Aaron Courville. Recurrent batch normalization. http://arxiv.org/pdf/1603.09025v4.pdf, 2016. [8] LE Baum and JA Eagon. An inequality with application to statistical estimation for probabilistic functions of markov processes and to a model for ecology. Bulletin of the American Mathematical Society, 73:360– 363, 1967. [9] Ilya Sutskever, James Martens, and Geoffrey E Hinton. Generating text with recurrent neural networks. In Proceedings of the 28th International Conference on Machine Learning (ICML-11), pages 1017–1024, 2011. [10] Kaiming He, Xiangyu Zhang, Shaoqing Ren, and Jian Sun. Deep residual learning for image recognition. arXiv preprint arXiv:1512.03385, 2015. [11] Mitchell P Marcus, Mary Ann Marcinkiewicz, and Beatrice Santorini. Building a large annotated corpus of english: The penn treebank. Computational linguistics, 19(2):313–330, 1993. [12] Tomáš Mikolov, Ilya Sutskever, Anoop Deoras, Hai-Son Le, and Stefan Kombrink. Subword language modeling with neural networks. preprint, (http://www.fit.vutbr.cz/imikolov/rnnlm/char.pdf), 2012. [13] Diederik Kingma and Jimmy Ba. Adam: A method for stochastic optimization. arXiv preprint arXiv:1412.6980, 2014. [14] David Krueger and Roland Memisevic. Regularizing rnns by stabilizing activations. arXiv preprint arXiv:1511.08400, 2015. [15] Awni Y Hannun, Andrew L Maas, Daniel Jurafsky, and Andrew Y Ng. First-pass large vocabulary continuous speech recognition using bi-directional recurrent dnns. arXiv preprint arXiv:1408.2873, 2014. [16] Dzmitry Bahdanau, Jan Chorowski, Dmitriy Serdyuk, Philemon Brakel, and Yoshua Bengio. End-to-end attention-based large vocabulary speech recognition. arXiv preprint arXiv:1508.04395, 2015. [17] Alex Graves and Navdeep Jaitly. Towards end-to-end speech recognition with recurrent neural networks. In Proceedings of the 31st International Conference on Machine Learning (ICML-14), pages 1764–1772, 2014. [18] Yajie Miao, Mohammad Gowayyed, and Florian Metze. Eesen: End-to-end speech recognition using deep rnn models and wfst-based decoding. arXiv preprint arXiv:1507.08240, 2015. [19] Marius Pachitariu and Maneesh Sahani. Regularization and nonlinearities for neural language models: when are they needed? arXiv preprint arXiv:1301.5650, 2013. [20] Alex Graves. Generating sequences with recurrent neural networks. arXiv preprint arXiv:1308.0850, 2013. [21] Alex Graves, Santiago Fernández, Faustino Gomez, and Jürgen Schmidhuber. Connectionist temporal classification: labelling unsegmented sequence data with recurrent neural networks. In Proceedings of the 23rd international conference on Machine learning, pages 369–376. ACM, 2006. [22] Mehryar Mohri, Fernando Pereira, and Michael Riley. Weighted finite-state transducers in speech recognition. Computer Speech & Language, 16(1):69–88, 2002. [23] Ryan Kiros, Yukun Zhu, Ruslan R Salakhutdinov, Richard Zemel, Raquel Urtasun, Antonio Torralba, and Sanja Fidler. Skip-thought vectors. In Advances in Neural Information Processing Systems, pages 3276–3284, 2015. [24] Karl Moritz Hermann, Tomas Kocisky, Edward Grefenstette, Lasse Espeholt, Will Kay, Mustafa Suleyman, and Phil Blunsom. Teaching machines to read and comprehend. In Advances in Neural Information Processing Systems, pages 1684–1692, 2015. [25] T. Wessels and C. W. Omlin. Refining hidden markov models with recurrent neural networks. In Neural Networks, 2000. IJCNN 2000, Proceedings of the IEEE-INNS-ENNS International Joint Conference on, volume 2, pages 271–276 vol.2, 2000. [26] Antti Rasmus, Harri Valpola, Mikko Honkala, Mathias Berglund, and Tapani Raiko. Semi-supervised learning with ladder network. arXiv preprint arXiv:1507.02672, 2015. [27] Mohammad Pezeshki, Linxi Fan, Philemon Brakel, Aaron Courville, and Yoshua Bengio. Deconstructing the ladder network architecture. arXiv preprint arXiv:1511.06430, 2015. [28] Bishan Yang, Wen-tau Yih, Xiaodong He, Jianfeng Gao, and Li Deng. Embedding entities and relations for learning and inference in knowledge bases. arXiv preprint arXiv:1412.6575, 2014. [29] Rami Al-Rfou, Guillaume Alain, Amjad Almahairi, and et al. Theano: A python framework for fast computation of mathematical expressions, 2016. [30] François Chollet. Keras. GitHub repository: https://github.com/fchollet/keras, 2015. 9 | 2016 | 551 |
6,496 | The Generalized Reparameterization Gradient Francisco J. R. Ruiz University of Cambridge Columbia University Michalis K. Titsias Athens University of Economics and Business David M. Blei Columbia University Abstract The reparameterization gradient has become a widely used method to obtain Monte Carlo gradients to optimize the variational objective. However, this technique does not easily apply to commonly used distributions such as beta or gamma without further approximations, and most practical applications of the reparameterization gradient fit Gaussian distributions. In this paper, we introduce the generalized reparameterization gradient, a method that extends the reparameterization gradient to a wider class of variational distributions. Generalized reparameterizations use invertible transformations of the latent variables which lead to transformed distributions that weakly depend on the variational parameters. This results in new Monte Carlo gradients that combine reparameterization gradients and score function gradients. We demonstrate our approach on variational inference for two complex probabilistic models. The generalized reparameterization is effective: even a single sample from the variational distribution is enough to obtain a low-variance gradient. 1 Introduction Variational inference (vi) is a technique for approximating the posterior distribution in probabilistic models (Jordan et al., 1999; Wainwright and Jordan, 2008). Given a probabilistic model p.x; z/ of observed variables x and hidden variables z, the goal of vi is to approximate the posterior p.z j x/, which is intractable to compute exactly for many models. The idea of vi is to posit a family of distributions over the latent variables q.zI v/ with free variational parameters v. vi then fits those parameters to find the member of the family that is closest in Kullback-Leibler (kl) divergence to the exact posterior, v D arg minv KL.q.zI v/jjp.z j x//. This turns inference into optimization, and different ways of doing vi amount to different optimization algorithms for solving this problem. For a certain class of probabilistic models, those where each conditional distribution is in an exponential family, we can easily use coordinate ascent optimization to minimize the kl divergence (Ghahramani and Beal, 2001). However, many important models do not fall into this class (e.g., probabilistic neural networks or Bayesian generalized linear models). This is the scenario that we focus on in this paper. Much recent research in vi has focused on these difficult settings, seeking effective optimization algorithms that can be used with any model. This has enabled the application of vi on nonconjugate probabilistic models (Carbonetto et al., 2009; Paisley et al., 2012; Ranganath et al., 2014; Titsias and Lázaro-Gredilla, 2014), deep neural networks (Neal, 1992; Hinton et al., 1995; Mnih and Gregor, 2014; Kingma and Welling, 2014), and probabilistic programming (Wingate and Weber, 2013; Kucukelbir et al., 2015; van de Meent et al., 2016). One strategy for vi in nonconjugate models is to obtain Monte Carlo estimates of the gradient of the variational objective and to use stochastic optimization to fit the variational parameters. Within this strategy, there have been two main lines of research: black-box variational inference (bbvi) (Ranganath et al., 2014) and reparameterization gradients (Salimans and Knowles, 2013; Kingma and Welling, 2014). Each enjoys different advantages and limitations. bbvi expresses the gradient of the variational objective as an expectation with respect to the variational distribution using the log-derivative trick, also called reinforce or score function method (Glynn, 1990; Williams, 1992). It then takes samples from the variational distribution to calculate noisy gradients. bbvi is generic—it can be used with any type of latent variables and any model. However, 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. the gradient estimates typically suffer from high variance, which can lead to slow convergence. Ranganath et al. (2014) reduce the variance of these estimates using Rao-Blackwellization (Casella and Robert, 1996) and control variates (Ross, 2002; Paisley et al., 2012; Gu et al., 2016). Other researchers have proposed further reductions, e.g., through local expectations (Titsias and LázaroGredilla, 2015) and importance sampling (Ruiz et al., 2016). The second approach to Monte Carlo gradients of the variational objective is through reparameterization (Price, 1958; Bonnet, 1964; Salimans and Knowles, 2013; Kingma and Welling, 2014; Rezende et al., 2014). This approach reparameterizes the latent variable z in terms of a set of auxiliary random variables whose distributions do not depend on the variational parameters (typically, a standard normal). This facilitates taking gradients of the variational objective because the gradient operator can be pushed inside the expectation, and because the resulting procedure only requires drawing samples from simple distributions, such as standard normals. We describe this in detail in Section 2. Reparameterization gradients exhibit lower variance than bbvi gradients. They typically need only one Monte Carlo sample to estimate a noisy gradient, which leads to fast algorithms. Further, for some models, their variance can be bounded (Fan et al., 2015). However, reparameterization is not as generic as bbvi. It is typically used with Gaussian variational distributions and does not easily generalize to other common distributions, such as the gamma or beta, without using further approximations. (See Knowles (2015) for an alternative approach to deal with the gamma distribution.) We develop the generalized reparameterization (g-rep) gradient, a new method to extend reparameterization to other variational distributions. The main idea is to define an invertible transformation of the latent variables such that the distribution of the transformed variables is only weakly governed by the variational parameters. (We make this precise in Section 3.) Our technique naturally combines both bbvi and reparameterization; it applies to a wide class of nonconjugate models; it maintains the blackbox criteria of reusing variational families; and it avoids approximations. We empirically show in two probabilistic models—a nonconjugate factorization model and a deep exponential family (Ranganath et al., 2015)—that a single Monte Carlo sample is enough to build an effective low-variance estimate of the gradient. In terms of speed, g-rep outperforms bbvi. In terms of accuracy, it outperforms automatic differentiation variational inference (advi) (Kucukelbir et al., 2016), which considers Gaussian variational distributions on a transformed space. 2 Background Consider a probabilistic model p.x; z/, where z denotes the latent variables and x the observations. We assume that the posterior distribution p.z j x/ is analytically intractable and we wish to apply vi. We introduce a tractable distribution q.zI v/ to approximate p.z j x/ and minimize the kl divergence DKL .q.zI v/ k p.z j x// with respect to the variational parameters v. This minimization is equivalently expressed as the maximization of the so-called evidence lower bound (elbo) (Jordan et al., 1999), L.v/ D Eq.zIv/ Œlog p.x; z/ log q.zI v/ D Eq.zIv/ Œf .z/ C H Œq.zI v/ : (1) We denote f .z/ , log p.x; z/ (2) to be the model log-joint density and H Œq.zI v/ to be the entropy of the variational distribution. When the expectation Eq.zIv/ Œf .z/ is analytically tractable, the maximization of the elbo can be carried out using standard optimization methods. Otherwise, when it is intractable, other techniques are needed. Recent approaches rely on stochastic optimization to construct Monte Carlo estimates of the gradient with respect to the variational parameters. Below, we review the two main methods for building such Monte Carlo estimates: the score function method and the reparameterization trick. Score function method. A general way to obtain unbiased stochastic gradients is to use the score function method, also called log-derivative trick or reinforce (Williams, 1992; Glynn, 1990), which has been recently applied to vi (Paisley et al., 2012; Ranganath et al., 2014; Mnih and Gregor, 2014). It is based on writing the gradient of the elbo with respect to v as rvL D Eq.zIv/ Œf .z/rv log q.zI v/ C rvH Œq.zI v/ ; (3) and then building Monte Carlo estimates by approximating the expectation with samples from q.zI v/. The resulting estimator suffers from high variance, making it necessary to apply variance reduction methods such as control variates (Ross, 2002) or Rao-Blackwellization (Casella and Robert, 1996). Such variance reduction techniques have been used in bbvi (Ranganath et al., 2014). 2 Reparameterization. The reparameterization trick (Salimans and Knowles, 2013; Kingma and Welling, 2014) expresses the latent variables z as an invertible function of another set of variables , i.e., z D T .I v/, such that the distribution of the new random variables q./ does not depend on the variational parameters v. Under these assumptions, expectations with respect to q.zI v/ can be expressed as Eq.zIv/ Œf .z/ D Eq./ Œf .T .I v//, and the gradient with respect to v can be pushed into the expectation, yielding rvL D Eq./ h rzf .z/ ˇˇ zDT .Iv/rvT .I v/ i C rvH Œq.zI v/ : (4) The assumption here is that the log-joint f .z/ is differentiable. The gradient rzf .z/ depends on the model, but it can be computed using automatic differentiation tools (Baydin et al., 2015). Monte Carlo estimates of the reparameterization gradient typically present much lower variance than those based on Eq. 3. In practice, a single sample from q./ is enough to obtain a low-variance estimate.1 The reparameterization trick is thus a powerful technique to reduce the variance of the estimator, but it requires a transformation D T 1.zI v/ such that q./ does not depend on the variational parameters v. For instance, if the variational distribution is Gaussian with mean and covariance †, a straightforward transformation consists of standardizing the random variable z, i.e., D T 1.zI ; †/ D † 1 2 .z /: (5) This transformation ensures that the (Gaussian) distribution q./ does not depend on or †. For a general variational distribution q.zI v/, Kingma and Welling (2014) discuss three families of transformations: inverse cumulative density function (cdf), location-scale, and composition. However, these transformations may not apply in certain cases.2 Notably, none of them apply to the gamma3 and the beta distributions, although these distributions are often used in vi. Next, we show how to relax the constraint that the transformed density q./ must not depend on the variational parameters v. We follow a standardization procedure similar to the Gaussian case in Eq. 5, but we allow the distribution of the standardized variable to depend (at least weakly) on v. 3 The Generalized Reparameterization Gradient We now generalize the reparameterization idea to distributions that, like the gamma or the beta, do not admit the standard reparameterization trick. We assume that we can efficiently sample from the variational distribution q.zI v/, and that q.zI v/ is differentiable with respect to z and v. We introduce a random variable defined by an invertible transformation D T 1.zI v/; and z D T .I v/; (6) where we can think of D T 1.zI v/ as a standardization procedure that attempts to make the distribution of weakly dependent on the variational parameters v. “Weakly” means that at least its first moment does not depend on v. For instance, if is defined to have zero mean, then its first moment has become independent of v. However, we do not assume that the resulting distribution of is completely independent of the variational parameters v, and therefore we write it as q.I v/. We use the distribution q.I v/ in the derivation of g-rep, but we write the final gradient as an expectation with respect to the original variational distribution q.zI v/, from which we can sample. More in detail, by the standard change-of-variable technique, the transformed density is q.I v/ D q .T .I v/I v/ J.; v/; where J.; v/ , jdet rT .I v/j ; (7) is a short-hand for the absolute value of the determinant of the Jacobian. We first use the transformation to rewrite the gradient of Eq.zIv/ Œf .z/ in (1) as rvEq.zIv/ Œf .z/ D rvEq.Iv/ Œf .T .I v// D rv Z q.I v/f .T .I v// d: (8) 1In the literature, there is no formal proof that reparameterization has lower variance than the score function estimator, except for some simple models (Fan et al., 2015). Titsias and Lázaro-Gredilla (2014) provide some intuitions, and Rezende et al. (2014) show some benefits of reparameterization in the Gaussian case. 2The inverse cdf approach sets T 1.zI v/ to the cdf. This leads to a uniform distribution over on the unit interval, but it is not practical because the inverse cdf, T .I v/, does not have analytical solution in general. We develop an approach that does not require computation of (inverse) cdf’s or their derivatives. 3Composition is only available when it is possible to express the gamma as a sum of exponentials, i.e., its shape parameter is an integer, which is not generally the case in vi. 3 We now express the gradient as the sum of two terms, which we name grep and gcorr for reasons that we will explain below. We apply the log-derivative trick and the product rule for derivatives, yielding rvEq.zIv/ Œf .z/ D Z q.I v/rvf .T .I v// d „ ƒ‚ … grep C Z q.I v/f .T .I v// rv log q.I v/d „ ƒ‚ … gcorr ; (9) We rewrite Eq. 9 as an expression that involves expectations with respect to the original variational distribution q.zI v/ only. For that, we define the following two auxiliary functions that depend on the transformation T .I v/: h.I v/ , rvT .I v/; and u.I v/ , rv log J.; v/: (10) After some algebra (see the Supplement for details), we obtain grep D Eq.zIv/ rzf .z/h T 1.zI v/I v ; gcorr D Eq.zIv/ f .z/ rz log q.zI v/h T 1.zI v/I v C rv log q.zI v/ C u T 1.zI v/I v : (11) Thus, we can finally write the full gradient of the elbo as rvL D grep C gcorr C rvH Œq.zI v/ ; (12) Interpretation of the generalized reparameterization gradient. The term grep is easily recognizable as the standard reparameterization gradient, and hence the label “rep.” Indeed, if the distribution q.I v/ does not depend on the variational parameters v, then the term rv log q.I v/ in Eq. 9 vanishes, making gcorr D 0. Thus, we may interpret gcorr as a “correction” term that appears when the transformed density depends on the variational parameters. Furthermore, we can recover the score function gradient in Eq. 3 by choosing the identity transformation, z D T .I v/ D . In such case, the auxiliary functions in Eq. 10 become zero because the transformation does not depend on v, i.e., h.I v/ D 0 and u.I v/ D 0. This implies that grep D 0 and gcorr D Eq.zIv/ Œf .z/rv log q.zI v/. Alternatively, we can interpret the g-rep gradient as a control variate of the score function gradient. For that, we rearrange Eqs. 9 and 11 to express the gradient as rvEq.zIv/ Œf .z/ D Eq.zIv/ Œf .z/rv log q.zI v/ C grep C Eq.zIv/ f .z/ rz log q.zI v/h T 1.zI v/I v C u T 1.zI v/I v ; where the second line is the control variate, which involves the reparameterization gradient. Transformations. Eqs. 9 and 11 are valid for any transformation T .I v/. However, we may expect some transformations to perform better than others, in terms of the variance of the resulting estimator. It seems sensible to search for transformations that make gcorr small, as the reparameterization gradient grep is known to present low variance in practice under standard smoothness conditions of the log-joint (Fan et al., 2015).4 Transformations that make gcorr small are such that D T 1.zI v/ becomes weakly dependent on the variational parameters v. In the standard reparameterization of Gaussian random variables, the transformation takes the form in (5), and thus is a standardized version of z. We mimic this standardization idea for other distributions as well. In particular, for exponential family distributions, we use transformations of the form (sufficient statistic expected sufficient statistic)=(scale factor). We present several examples in the next section. 3.1 Examples For concreteness, we show here some examples of the equations above for well-known probability distributions. In particular, we choose the gamma, log-normal, and beta distributions. Gamma distribution. Let q.zI ˛; ˇ/ be a gamma distribution with shape ˛ and rate ˇ. We use a transformation based on standardization of the sufficient statistic log.z/, i.e., D T 1.zI ˛; ˇ/ D log.z/ .˛/ C log.ˇ/ p 1.˛/ ; 4Techniques such as Rao-Blackwellization could additionally be applied to reduce the variance of gcorr. We do not apply any such technique in this paper. 4 where ./ denotes the digamma function, and k./ is its k-th derivative. This ensures that has zero mean and unit variance, and thus its two first moments do not depend on the variational parameters ˛ and ˇ. We now compute the auxiliary functions in Eq. 10 for the components of the gradient with respect to ˛ and ˇ, which take the form h˛.I ˛; ˇ/ D T .I ˛; ˇ/ 2.˛/ 2 p 1.˛/ C 1.˛/ ! ; hˇ.I ˛; ˇ/ D T .I ˛; ˇ/ ˇ ; u˛.I ˛; ˇ/ D 2.˛/ 2 p 1.˛/ C 1.˛/ ! C 2.˛/ 2 1.˛/; uˇ.I ˛; ˇ/ D 1 ˇ : The terms grep and gcorr are obtained after substituting these results in Eq. 11. We provide the final expressions in the Supplement. We remark here that the component of gcorr corresponding to the derivative with respect to the rate equals zero, i.e., gcorr ˇ D 0, meaning that the distribution of does not depend on the parameter ˇ. Indeed, we can compute this distribution following Eq. 7 as q.I ˛; ˇ/ D e˛ .˛/p 1.˛/ .˛/ exp ˛ p 1.˛/ exp p 1.˛/ C .˛/ ; where we can verify that it does not depend on ˇ. Log-normal distribution. For a log-normal distribution with location and scale , we can standardize the sufficient statistic log.z/ as D T 1.zI ; / D log.z/ : This leads to a standard normal distribution on , which does not depend on the variational parameters, and thus gcorr D 0. The auxiliary function h.I ; /, which is needed for grep, takes the form h.I ; / D T .I ; /; h.I ; / D T .I ; /: Thus, the reparameterization gradient is given in this case by grep D Eq.zI;/ Œzrzf .z/ ; grep D Eq.zI;/ zT 1.zI ; /rzf .z/ : This corresponds to advi (Kucukelbir et al., 2016) with a logarithmic transformation over a positive random variable, since the variational distribution over the transformed variable is Gaussian. For a general variational distribution, we recover advi if the transformation makes Gaussian. Beta distribution. For a random variable z Beta.˛; ˇ/, we could rewrite z D z0 1=.z0 1 C z0 2/ for z0 1 Gamma.˛; 1/ and z0 2 Gamma.ˇ; 1/, and apply the gamma reparameterization for z0 1 and z0 2. Instead, in the spirit of applying standardization directly over z, we define a transformation to standardize the logit function, logit .z/ , log.z=.1 z// (sum of sufficient statistics of the beta), D T 1.zI ˛; ˇ/ D logit .z/ .˛/ C .ˇ/ .˛; ˇ/ : This ensures that has zero mean. We can set the denominator to the standard deviation of logit .z/. However, for larger-scaled models we found better performance with a denominator .˛; ˇ/ that makes gcorr D 0 for the currently drawn sample z (see the Supplement for details), even though the variance of the transformed variable is not one in such case.5 The reason is that gcorr suffers from high variance in the same way as the score function estimator does. 3.2 Algorithm We now present our full algorithm for g-rep. It requires the specification of the variational family and the transformation T .I v/. Given these, the full procedure is summarized in Algorithm 1. We use the adaptive step-size sequence proposed by Kucukelbir et al. (2016), which combines rmsprop (Tieleman and Hinton, 2012) and Adagrad (Duchi et al., 2011). Let g.i/ k be the k-th component of the gradient at the i-th iteration, and .i/ k the step-size for that component. We set .i/ k D i 0:5C C q s.i/ k 1 ; with s.i/ k D
.g.i/ k /2 C .1
/s.i 1/ k ; (13) where we set D 10 16, D 1,
D 0:1, and we explore several values of . Thus, we update the variational parameters as v.iC1/ D v.i/ C .i/ ı rvL, where ‘ı’ is the element-wise product. 5Note that this introduces some bias since we are ignoring the dependence of .˛; ˇ/ on z. 5 Algorithm 1: Generalized reparameterization gradient algorithm input :data x, probabilistic model p.x; z/, variational family q.zI v/, transformation z D T .I v/ output :variational parameters v Initialize v repeat Draw a single sample z q.zI v/ Compute the auxiliary functions h T 1.zI v/I v and u T 1.zI v/I v (Eq. 10) Estimate grep and gcorr (Eq. 11, estimate the expectation with one sample) Compute (analytic) or estimate (Monte Carlo) the gradient of the entropy, rvH Œq.zI v/ Compute the noisy gradient rvL (Eq. 12) Set the step-size .i/ (Eq. 13) and take a gradient step for v until convergence 3.3 Related work A closely related vi method is advi, which also relies on reparameterization and has been incorporated into Stan (Kucukelbir et al., 2015, 2016). advi applies a transformation to the random variables such that their support is on the reals and then uses a Gaussian variational posterior on the transformed space. For instance, random variables that are constrained to be positive are first transformed through a logarithmic function and then a Gaussian variational approximating distribution is placed on the unconstrained space. Thus, advi struggles to approximate probability densities with singularities, which are useful in models where sparsity is appropriate. In contrast, the g-rep method allows to estimate the gradient for a wider class of variational distributions, including gamma and beta distributions, which are more appropriate to encode sparsity constraints. Schulman et al. (2015) also write the gradient in the form given in Eq. 12 to automatically estimate the gradient through a backpropagation algorithm in the context of stochastic computation graphs. However, they do not provide additional insight into this equation, do not apply it to general vi, do not discuss transformations for any distributions, and do not report experiments. Thus, our paper complements Schulman et al. (2015) and provides an off-the-shelf tool for general vi. 4 Experiments We apply g-rep to perform mean-field vi on two nonconjugate probabilistic models: the sparse gamma deep exponential family (def) and a beta-gamma matrix factorization (mf) model. The sparse gamma def (Ranganath et al., 2015) is a probabilistic model with several layers of latent locations and latent weights, mimicking the architecture of a deep neural network. The weights of the model are denoted by w.`/ kk0, where k and k0 run over latent components, and ` indexes the layer. The latent locations are z.`/ nk, where n denotes the observation. We consider Poisson-distributed observations xnd for each dimension d. Thus, the model is specified as z.`/ nk Gamma ˛z; ˛z P k0 z.`C1/ nk0 w.`/ k0k ! ; xnd Poisson X k0 z.1/ nk0w.0/ k0d ! : We place gamma priors over the weights w` kk0 with rate 0:3 and shape 0:1, and a gamma prior with rate 0:1 and shape 0:1 over the top-layer latent variables z.L/ nk . We set the hyperparameter ˛z D 0:1, and we use L D 3 layers with 100, 40, and 15 latent factors. The second model is a beta-gamma mf model with weights wkd and latent locations znk. We use this model to describe binary observations xnd, which are modeled as xnd Bernoulli sigmoid X k logit .znk/ wkd !! ; where logit .z/ D log.z=.1 z// and sigmoid ./ is the inverse logit function. We place a gamma prior with shape 0:1 and rate 0:3 over the weights wkd, a uniform prior over the variables znk, and we use K D 100 latent components. Datasets. We apply the sparse gamma def on two different databases: (i) the Olivetti database at AT&T,6 which consists of 400 (320 for training and 80 for test) 64 64 images of human faces in a 8 6http://www.cl.cam.ac.uk/research/dtg/attarchive/facedatabase.html 6 Dataset g-rep bbvi advi Olivetti 5 1 0:1 nips 0:5 5 1 mnist 5 5 0:1 Omniglot 5 0:1 Dataset g-rep bbvi advi Olivetti 0:46 12:90 0:17 nips 0:83 20:95 0:25 mnist 1:09 25:99 0:34 Omniglot 5:50 4:10 Table 1: (Left) Step-size constant , reported for completeness. (Right) Average time per iteration in seconds. g-rep is 1-4 times slower than advi but above one order of magnitude faster than bbvi. bit scale (0 255); and (ii) the collection of papers at the Neural Information Processing Systems (nips) 2011 conference, which consists of 305 documents and a vocabulary of 5715 effective words in a bag-of-words format (25% of words from all documents are set aside to form the test set). We apply the beta-gamma mf on: (i) the binarized mnist data,7 which consists of 28 28 images of hand-written digits (we use 5000 training and 2000 test images); and (ii) the Omniglot dataset (Lake et al., 2015), which consists of 105 105 images of hand-written characters from different alphabets (we select 10 alphabets, with 4425 training images, 1475 test images, and 295 characters). Evaluation. We apply mean-field vi and we compare g-rep with bbvi (Ranganath et al., 2014) and advi (Kucukelbir et al., 2016). We do not apply bbvi on the Omniglot dataset due to its computational complexity. At each iteration, we evaluate the elbo using one sample from the variational distribution, except for advi, for which we use 20 samples (for the Omniglot dataset, we only use one sample). We run each algorithm with a fixed computational budget of CPU time. After that time, we also evaluate the predictive log-likelihood on the test set, averaging over 100 posterior samples. For the nips data, we also compute the test perplexity (with one posterior sample) every 10 iterations, given by exp P docs P w2doc.d/ log p.w j #held out in doc.d// #held out words ! : Experimental setup. To estimate the gradient, we use 30 Monte Carlo samples for bbvi, and only 1 for advi and g-rep. For bbvi, we use Rao-Blackwellization and control variates (we use a separate set of 30 samples to estimate the control variates). For bbvi and g-rep, we use beta and gamma variational distributions, whereas advi uses Gaussian distributions on the transformed space, which correspond to log-normal or logit-normal distributions on the original space. Thus, only g-rep and bbvi optimize the same variational family. We parameterize the gamma distribution in terms of its shape and mean, and the beta in terms of its shape parameters ˛ and ˇ. To avoid constrained optimization, we apply the transformation v0 D log.exp.v/ 1/ to the variational parameters that are constrained to be positive and take stochastic gradient steps with respect to v0. We use the analytic gradient of the entropy terms. We implement advi as described by Kucukelbir et al. (2016). We use the step-size schedule in Eq. 13, and we explore the parameter 2 f0:1; 0:5; 1; 5g. For each algorithm and each dataset, we report the results based on the value of for which the best elbo was achieved. We report the values of in Table 1 (left). Results. We show in Figure 1 the evolution of the elbo as a function of the running time for three of the considered datasets. bbvi converges slower than the rest of the methods, since each iteration involves drawing multiple samples and evaluating the log-joint for each of them. advi and g-rep achieve similar bounds, except for the mnist dataset, for which g-rep provides a variational approximation that is closer to the posterior, since the elbo is higher. This is because a variational family with sparse gamma and beta distributions provides a better fit to the data than the variational family to which advi is limited (log-normal and logit-normal). advi seems to converge slower; however, we do not claim that advi converges slower than g-rep in general. Instead, the difference may be due to the different step-sizes schedules that we found to be optimal (see Table 1). We also report in Table 1 (right) the average time per iteration8 for each method: bbvi is the slowest method, and advi is the fastest because it involves simulation of Gaussian random variables only. However, g-rep provides higher likelihood values than advi. We show in Figure 2a the evolution of the perplexity (lower is better) for the nips dataset, and in Figure 2b the resulting test log-likelihood (larger is better) for the rest of the considered datasets. In Figure 2b, we report the mean and standard deviation over 100 posterior samples. advi cannot fit the data as well as g-rep or bbvi because it is constrained to log-normal and logit-normal variational distributions. These cannot capture sparsity, 7http://yann.lecun.com/exdb/mnist 8On the full mnist with 50; 000 training images, g-rep (advi) took 8:08 (2:04) seconds per iteration. 7 0 0.5 1 1.5 2 2.5 3 3.5 −2.5 −2 −1.5 −1 −0.5 x 10 7 Time (h) ELBO Olivetti G−REP BBVI ADVI (a) elbo (Olivetti dataset). 0 2 4 6 8 −3 −2.5 −2 −1.5 −1 −0.5 x 10 6 Time (h) ELBO MNIST G−REP BBVI ADVI (b) elbo (mnist dataset). 0 5 10 15 −5 −4 −3 −2 −1 x 10 7 Time (h) ELBO Omniglot G−REP ADVI (c) elbo (Omniglot dataset). Figure 1: Comparison between g-rep, bbvi, and advi in terms of the variational objective function. 0 1 2 3 4 5 6 1000 1500 2000 2500 Time (h) Test perplexity NIPS G−REP BBVI ADVI (a) Perplexity (nips dataset). Dataset g-rep bbvi advi Olivetti 4:48 ˙ 0:01 9:74 ˙ 0:08 4:63 ˙ 0:01 mnist 0:0932 ˙ 0:0004 0:0888 ˙ 0:0004 0:189 ˙ 0:009 Omniglot 0:0472 ˙ 0:0001 0:0823 ˙ 0:0009 (b) Average test log-likelihood per entry xnd. Figure 2: Comparison between g-rep, bbvi, and advi in terms of performance on the test set. g-rep outperforms bbvi because the latter has not converged in the allowed time, and it also outperforms advi because of the variational family it uses. which is an important feature for the considered models. We can also conclude this by a simple visual inspection of the fitted models. In the Supplement, we compare images sampled from the g-rep and the advi posteriors, where we can observe that the latter are more blurry or lack some details. 5 Conclusion We have introduced the generalized reparameterization gradient (g-rep), a technique to extend the standard reparameterization gradient to a wider class of variational distributions. As the standard reparameterization method, our method is applicable to any probabilistic model that is differentiable with respect to the latent variables. We have demonstrated the generalized reparameterization gradient on two nonconjugate probabilistic models to fit a variational approximation involving gamma and beta distributions. We have also empirically shown that a single Monte Carlo sample is enough to obtain a noisy estimate of the gradient, therefore leading to a fast inference procedure. Acknowledgments This project has received funding from the EU H2020 programme (Marie Skłodowska-Curie grant agreement 706760), NFS IIS-1247664, ONR N00014-11-1-0651, DARPA FA8750-14-2-0009, DARPA N66001-15-C-4032, Adobe, the John Templeton Foundation, and the Sloan Foundation. The authors would also like to thank Kriste Krstovski, Alp Kuckukelbir, and Christian A. Naesseth for helpful comments and discussions. References Baydin, A. G., Pearlmutter, B. A., and Radul, A. A. (2015). Automatic differentiation in machine learning: a survey. arXiv:1502.05767. Bonnet, G. (1964). Transformations des signaux aléatoires a travers les systemes non linéaires sans mémoire. Annals of Telecommunications, 19(9):203–220. Carbonetto, P., King, M., and Hamze, F. (2009). A stochastic approximation method for inference in probabilistic graphical models. In Advances in Neural Information Processing Systems. Casella, G. and Robert, C. P. (1996). Rao-Blackwellisation of sampling schemes. Biometrika, 83(1):81–94. Duchi, J., Hazan, E., and Singer, Y. (2011). Adaptive subgradient methods for online learning and stochastic optimization. Journal of Machine Learning Research, 12:2121–2159. Fan, K., Wang, Z., Beck, J., Kwok, J., and Heller, K. A. (2015). Fast second order stochastic backpropagation for variational inference. In Advances in Neural Information Processing Systems. Ghahramani, Z. and Beal, M. J. (2001). Propagation algorithms for variational Bayesian learning. In Advances in Neural Information Processing Systems. Glynn, P. W. (1990). Likelihood ratio gradient estimation for stochastic systems. Communications of the ACM, 33(10):75–84. 8 Gu, S., Levine, S., Sutskever, I., and Mnih, A. (2016). MuProp: Unbiased backpropagation for stochastic neural networks. In International Conference on Learning Representations. Hinton, G., Dayan, P., Frey, B. J., and Neal, R. M. (1995). The wake-sleep algorithm for unsupervised neural networks. Science, 268(5214):1158–1161. Jordan, M. I., Ghahramani, Z., Jaakkola, T. S., and Saul, L. K. (1999). An introduction to variational methods for graphical models. Machine Learning, 37(2):183–233. Kingma, D. P. and Welling, M. (2014). Auto-encoding variational Bayes. In International Conference on Learning Representations. Knowles, D. A. (2015). Stochastic gradient variational Bayes for gamma approximating distributions. arXiv:1509.01631v1. Kucukelbir, A., Ranganath, R., Gelman, A., and Blei, D. M. (2015). Automatic variational inference in Stan. In Advances in Neural Information Processing Systems. Kucukelbir, A., Tran, D., Ranganath, R., Gelman, A., and Blei, D. M. (2016). Automatic differentiation variational inference. arXiv:1603.00788. Lake, B. M., Salakhutdinov, R., and Tenenbaum, J. B. (2015). Human-level concept learning through probabilistic program induction. Science, 350(6266):1332–1338. Mnih, A. and Gregor, K. (2014). Neural variational inference and learning in belief networks. In International Conference on Machine Learning. Neal, R. (1992). Connectionist learning of belief networks. Artificial Intelligence, 56(1):71–113. Paisley, J. W., Blei, D. M., and Jordan, M. I. (2012). Variational Bayesian inference with stochastic search. In International Conference on Machine Learning. Price, R. (1958). A useful theorem for nonlinear devices having Gaussian inputs. IRE Transactions on Information Theory, 4(2):69–72. Ranganath, R., Gerrish, S., and Blei, D. M. (2014). Black box variational inference. In Artificial Intelligence and Statistics. Ranganath, R., Tang, L., Charlin, L., and Blei, D. M. (2015). Deep exponential families. In Artificial Intelligence and Statistics. Rezende, D. J., Mohamed, S., and Wierstra, D. (2014). Stochastic backpropagation and approximate inference in deep generative models. In International Conference on Machine Learning. Ross, S. M. (2002). Simulation. Elsevier. Ruiz, F. J. R., Titsias, M. K., and Blei, D. M. (2016). Overdispersed black-box variational inference. In Uncertainty in Artificial Intelligence. Salimans, T. and Knowles, D. A. (2013). Fixed-form variational posterior approximation through stochastic linear regression. Bayesian Analysis, 8(4):837–882. Schulman, J., Heess, N., Weber, T., and Abbeel, P. (2015). Gradient estimation using stochastic computation graphs. In Advances in Neural Information Processing Systems. Tieleman, T. and Hinton, G. (2012). Lecture 6.5-RMSPROP: Divide the gradient by a running average of its recent magnitude. Coursera: Neural Networks for Machine Learning, 4. Titsias, M. K. and Lázaro-Gredilla, M. (2014). Doubly stochastic variational Bayes for non-conjugate inference. In International Conference on Machine Learning. Titsias, M. K. and Lázaro-Gredilla, M. (2015). Local expectation gradients for black box variational inference. In Advances in Neural Information Processing Systems. van de Meent, J.-W., Tolpin, D., Paige, B., and Wood, F. (2016). Black-box policy search with probabilistic programs. In Artificial Intelligence and Statistics. Wainwright, M. J. and Jordan, M. I. (2008). Graphical models, exponential families, and variational inference. Foundations and Trends in Machine Learning, 1(1–2):1–305. Williams, R. J. (1992). Simple statistical gradient-following algorithms for connectionist reinforcement learning. Machine Learning, 8(3–4):229–256. Wingate, D. and Weber, T. (2013). Automated variational inference in probabilistic programming. arXiv:1301.1299. 9 | 2016 | 552 |
6,497 | Semiparametric Differential Graph Models Pan Xu University of Virginia px3ds@virginia.edu Quanquan Gu University of Virginia qg5w@virginia.edu Abstract In many cases of network analysis, it is more attractive to study how a network varies under different conditions than an individual static network. We propose a novel graphical model, namely Latent Differential Graph Model, where the networks under two different conditions are represented by two semiparametric elliptical distributions respectively, and the variation of these two networks (i.e., differential graph) is characterized by the difference between their latent precision matrices. We propose an estimator for the differential graph based on quasi likelihood maximization with nonconvex regularization. We show that our estimator attains a faster statistical rate in parameter estimation than the state-of-the-art methods, and enjoys the oracle property under mild conditions. Thorough experiments on both synthetic and real world data support our theory. 1 Introduction Network analysis has been widely used in various fields to characterize the interdependencies between a group of variables, such as molecular entities including RNAs and proteins in genetic networks [3]. Networks are often modeled as graphical models. For instance, in gene regulatory network, the gene expressions are often assumed to be jointly Gaussian. A Gaussian graphical model [18] is then employed by representing different genes as nodes and the regulation between genes as edges in the graph. In particular, two genes are conditionally independent given the others if and only if the corresponding entry of the precision matrix of the multivariate normal distribution is zero. Nevertheless, the Gaussian distribution assumption, is too restrictive in practice. For example, the gene expression values from high-throughput method, even after being normalized, do not follow a normal distribution [19, 26]. This leads to the inaccuracy in describing the dependency relationships among genes. In order to address this problem, various semiparametric Gaussian graphical models [21, 20] are proposed to relax the Gaussian distribution assumption. On the other hand, it is well-known that the interactions in many types of networks can change under various environmental and experimental conditions [1]. Take the genetic networks for example, two genes may be positively conditionally dependent under some conditions but negatively conditionally dependent under others. Therefore, in many cases, more attention is attracted not by a particular individual network but rather by whether and how the network varies with genetic and environmental alterations [6, 15]. This gives rise to differential networking analysis, which has emerged as an important method in differential expression analysis of gene regulatory networks [9, 28]. In this paper, in order to conduct differential network analysis, we propose a Latent Differential Graph Model (LDGM), where the networks under two different conditions are represented by two transelliptical distributions [20], i.e., TEd(⌃⇤ X, ⇠; f1, . . . , fd) and TEd(⌃⇤ Y , ⇠; g1, . . . , gd) respectively. Here TEd(⌃⇤ X, ⇠; f1, . . . , fd) denotes a d-dimensional transelliptical distribution with latent correlation matrix ⌃⇤ X 2 Rd⇥d, and will be defined in detail in Section 3. More specifically, the connectivity of the individual network is encoded by the latent precision matrix (e.g., ⇥⇤ X = (⌃⇤ X)−1) of the corresponding transelliptical distribution, such that [⇥⇤ X]jk 6= 0 if and only if there is an edge between the j-th node and the k-th node in the network. And the differential graph is defined as 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. the difference between the two latent precision matrices ∆⇤= ⇥⇤ Y −⇥⇤ X. Our goal is to estimate ∆⇤based on observations sampled from TEd(⌃⇤ X, ⇠; f1, . . . , fd) and TEd(⌃⇤ Y , ⇠; g1, . . . , gd). A simple procedure is estimating ⇥⇤ X and ⇥⇤ Y separately, followed by calculating their difference. However, it requires estimating 2d2 parameters (i.e., ⇥⇤ X and ⇥⇤ Y ), while our ultimate goal is only estimating d2 parameters (i.e., ∆⇤). In order to overcome this problem, we assume that the difference of the two latent precision matrices, i.e., ∆⇤is sparse and propose to directly estimate it by quasi likelihood maximization with nonconvex penalty. The nonconvex penalty is introduced in order to correct the intrinsic estimation bias incurred by convex penalty [10, 36]. We prove that, when the true differential graph is s-sparse, our estimator attains O( p s1/n + p s2 log d/n) convergence rate in terms of Frobenius norm, which is faster than the estimation error bound O( p s log d/n) of `1,1 penalty based estimator in [38]. Here n is the sample size, s1 is the number of entries in ∆⇤with large magnitude, s2 is the number of entries with small magnitude and s = s1 + s2. We show that our method enjoys the oracle property under a very mild condition. Thorough numerical experiments on both synthetic and real-world data back up our theory. The remainder of this paper is organized as follows: we review the related work in Section 2. We introduce the proposed model and the non-convex penalty in Section 3, as well as the proposed estimator. In Section 4, we present our main theories for estimation in semiparametric differential graph models. Experiments on both synthetic and real world data are provided in Section 5. Section 6 concludes with discussion. Notation For x = (x1, . . . , xd)> 2 Rd and 0 < q < 1, we define the `0, `q and `1 vector norms as kxk0 = Pd i=1 1(xi 6= 0), kxkq = # Pd i=1 |xi|q$1/q, and kxk1 = max1id |xi|, where 1(·) is the indicator function. For A = (Aij) 2 Rd⇥d, we define the matrix `0,0, `1,1, `1,1 and `F norms as: kAk0,0 = Pd i,j=1 1 (Aij 6= 0), kAk1,1 = Pd i,j=1 |Aij|, kAk1,1 = max1i,jd |Aij|, and kAkF = qP ij |Aij|2. The induced norm for matrix is defined as kAkq = maxkxkq=1 kAxkq, for 0 < q < 1. For a set of tuples S, AS denotes the set of numbers [A(jk)](jk)2S, and vec(S) is the vectorized index set of S. 2 Related Work There exist several lines of research for differential network analysis. One natural procedure is to estimate the two networks (i.e., two precision matrices) respectively by existing estimators such as graphical Lasso [12] and node-wise regression [25]. Another family of methods jointly estimates the two networks by assuming that they share common structural patterns and therefore uses joint likelihood maximization with group lasso penalty or group bridge penalty [7, 8, 14]. Based on the estimated precision matrices, the differential graph can be obtained by calculating their difference. However, both of these two types of methods suffer from the drawback that they need to estimate twice the number of parameters, and hence require roughly doubled observations to ensure the estimation accuracy. In order to address this drawback, some methods are proposed to estimate the difference of matrices directly [38, 35, 22, 11]. For example, [38] proposed a Dantzig selector type estimator for estimating the difference of the precision matrices directly. [35] proposed a D-Trace loss [37] based estimator for the difference of the precision matrices. Compared with [38, 35], our estimator is advantageous in the following aspects: (1) our model relaxes the Gaussian assumption by representing each network as a transelliptical distribution, while [38, 35] are restricted to Gaussian distribution. Thus, our model is more general and robust; and (2) by employing nonconvex penalty, our estimator achieves a sharper statistical rate than theirs. Rather than the Gaussian graphical model or its semiparametric extension, [22, 11] studied the estimation of change in the dependency structure between two high dimensional Ising models. 3 Semiparametric Differential Graph Models In this section, we will first review the transelliptical distribution and present our semiparametric differential graph model. Then we will present the estimator for differential graph, followed by the introduction to nonconvex penalty. 3.1 Transelliptical Distribution To briefly review the transelliptical distribution, we begin with the definition of elliptical distribution. 2 Definition 3.1 (Elliptical distribution). Let µ 2 Rd and ⌃⇤2 Rd⇥d with rank(⌃⇤) = q d. A random vector X 2 Rd follows an elliptical distribution, denoted by ECd(µ, ⌃⇤, ⇠), if it can be represented as X = µ + ⇠AU, where A is a deterministic matrix satisfying A>A = ⌃⇤, U is a random vector uniformly distributed on the unit sphere in Rq, and ⇠? U is a random variable. Motivated by the extension from Gaussian distribution to nonparanormal distribution [21], [20] proposed a semiparametric extension of elliptical distribution, which is called transelliptical distribution. Definition 3.2 (Transelliptical distribution). A random vector X = (X1, X2, . . . , Xd)> 2 Rd is transelliptical, denoted by TEd(⌃⇤, ⇠; f1, . . . , fd), if there exists a set of monotone univariate functions f1, . . . , fd and a nonnegative random variable ⇠, such that (f1(X1), . . . , fd(Xd))> follows an elliptical distribution ECd(0, ⌃⇤, ⇠). 3.2 Kendall’s tau Statistic In semiparametric setting, the Pearson’s sample covariance matrix can be inconsistent in estimating ⌃⇤. Given n independent observations X1, ..., Xn, where Xi = (Xi1, ..., Xid)> ⇠ TEd(⌃⇤, ⇠; f1, . . . , fd), [20] proposed a rank-based estimator, the Kendall’s tau statistic, to estimate ⌃⇤, due to its invariance under monotonic marginal transformations. The Kendall’s tau estimator is defined as b⌧jk = 2 n(n −1) X 1i<i0n sign ⇥# Xij −Xi0j $# Xik −Xi0k $⇤ . (3.1) It has been shown that b⌧jk is an unbiased estimator of ⌧jk = 2/⇡arcsin(⌃⇤ jk) [20], and the correlation matrix ⌃⇤can be estimated by b⌃= [b⌃jk] 2 Rd⇥d, where b⌃jk = sin ⇣⇡ 2 b⌧jk ⌘ . (3.2) We use T⇤to denote the matrix with entries ⌧jk and bT with entries b⌧jk, for j, k = 1, . . . d. 3.3 Latent Differential Graph Models and the Estimator Now we are ready to formulate our differential graph model. Assume that d dimensional random vectors X and Y satisfy X ⇠TEd(⌃⇤ X, ⇠; f1, . . . , fd) and Y ⇠TEd(⌃⇤ Y , ⇠; g1, . . . , gd). The differential graph is defined to be the difference of the two latent precision matrices, ∆⇤= ⇥⇤ Y −⇥⇤ X, (3.3) where ⇥⇤ X = ⌃⇤−1 X and ⇥⇤ Y = ⌃⇤−1 Y . It immediately implies ⌃⇤ X∆⇤⌃⇤ Y −(⌃⇤ X −⌃⇤ Y ) = 0, and ⌃⇤ Y ∆⇤⌃⇤ X −(⌃⇤ X −⌃⇤ Y ) = 0. (3.4) Given i.i.d. copies X1, . . . , XnX of X, and i.i.d. copies Y1, . . . , YnY of Y , without loss of generality, we assume nX = nY = n, and we denote the Kendall’s tau correlation matrices defined in (3.2) as b⌃X and b⌃Y . Following (3.4), a reasonable procedure for estimating ∆⇤is to solve the following equation for ∆ 1 2 b⌃X∆b⌃Y + 1 2 b⌃Y ∆b⌃X −(b⌃X −b⌃Y ) = 0, (3.5) where we add up the two equations in (3.4) and replace the latent population correlation matrices ⌃⇤ X, ⌃⇤ Y with the Kendall’s tau estimators b⌃X, b⌃Y . Note that (3.5) is a Z-estimator [30], which can be translated into a M-estimator, by noticing that 1/2b⌃X∆b⌃Y + 1/2b⌃Y ∆b⌃X −(b⌃X −b⌃Y ) can be seen as a score function of the following quasi log likelihood function `(∆) = 1 2 tr(∆b⌃Y ∆b⌃X) −tr # ∆(b⌃X −b⌃Y ) $ . (3.6) Let S = supp(∆⇤), in this paper, we assume that ∆⇤is sparse, i.e., |S| s with s > 0. Based on (3.6), we propose to estimate ∆⇤by the following M-estimator with non-convex penalty b∆= argmin ∆2Rd⇥d 1 2 tr(∆b⌃Y ∆b⌃X) −tr # ∆(b⌃X −b⌃Y ) $ + Gλ(∆), (3.7) 3 where λ > 0 is a regularization parameter and Gλ is a decomposable nonconvex penalty function, i.e., Gλ(∆) = Pd j,k=1 gλ(∆jk), such as smoothly clipped absolute deviation (SCAD) penalty [10] or minimax concave penalty (MCP) [36]. The key property of the nonconvex penalty is that it can avoid over-penalization when the magnitude is very large. It has been shown in [10, 36, 33] that the nonconvex penalty is able to alleviate the estimation bias and attain a refined statistical rate of convergence. The nonconvex penalty gλ(δ) can be further decomposed as the sum of the `1 penalty and a concave component hλ(δ), i.e., gλ(δ) = λ|δ| + hλ(δ). Take MCP penalty for example. The corresponding gλ(δ) and hλ(δ) are defined as follows gλ(δ) = λ Z |δ| 0 ✓ 1 −z λb ◆ + dz, for any δ 2 R, where λ > 0 is the regularization parameter and b > 0 is a fixed parameter, and hλ(δ) = −δ2 2b 1(|δ| bλ) + ✓bλ2 2 −λ|δ| ◆ 1(|δ| > bλ). In Section 4, we will show that the above family of nonconvex penalties satisfies certain common regularity conditions on gλ(β) as well as its concave component hλ(β). We will show in the next section that when the parameters of the nonconvex penalty are appropriately chosen, (3.7) is an unconstrained convex optimization problem. Thus it can be solved by the proximal gradient descent [4] very efficiently. In addition, it is easy to check that the estimator b∆from (3.7) is symmetric. So it does not need the symmetrizing process adopted in [38], which can undermine the estimation accuracy. 4 Main Theory In this section, we present our main theories. Let S = supp(∆⇤) be the support of the true differential graph. We introduce the following oracle estimator of ∆⇤: b∆O = argmin supp(∆)✓S `(∆), (4.1) where `(∆) = 1/2 tr(∆b⌃Y ∆b⌃X)−tr # ∆(b⌃X −b⌃Y ) $ . The oracle estimator b∆O is not a practical estimator, since we do not know the true support in practice. An estimator is said to have the oracle property, if it is identical to the oracle estimator b∆O under certain conditions. We will show that our estimator enjoys the oracle property under a mild condition. We first lay out some assumptions that are required through our analysis. Assumption 4.1. There exist constants 1, 2 > 0 such that 1 λmin(⌃⇤ X) λmax(⌃⇤ X) 1/1 and 2 λmin(⌃⇤ Y ) λmax(⌃⇤ Y ) 1/2. The true covariance matrices have bounded `1 norm, i.e., k⌃⇤ Xk1 σX, k⌃⇤ Y k1 σY , where σX, σY > 0 are constants. And the true precision matrices have bounded matrix `1-norm, i.e., k⇥⇤ Xk1 ✓X and k⇥⇤ Y k1 ✓Y , where ✓X, ✓Y > 0 are constants. The first part of Assumption 4.1 requires that the smallest eigenvalues of the correlation ⌃⇤ X, ⌃⇤ Y are bounded below from zero, and their largest eigenvalues are finite. This assumptions is commonly imposed in the literature for the analysis of graphical models [21, 27]. Assumption 4.2. The true difference matrix ∆⇤= ⌃⇤−1 Y −⌃⇤−1 X has s nonzero entries, i.e., k∆⇤k0,0 s and has bounded `1,1 norm, i.e., k∆⇤k1,1 M, where M > 0 does not depend on d. Assumption 4.2 requires the differential graph to be sparse. This is reasonable in differential network analysis where the networks only vary slightly under different conditions. The next assumption is about regularity conditions on the nonconvex penalty gλ(δ). Recall that gλ(δ) can be written as gλ(δ) = λ|δ| + hλ(δ). Assumption 4.3. gλ(δ) and its concave component hλ(δ) satisfy: (a) There exists a constant ⌫such that g0 λ(δ) = 0, for |δ| ≥⌫> 0. (b) There exists a constant ⇣−≥0 such that hλ(δ) + ⇣−/2 · δ2 is convex. 4 (c) hλ(δ) and h0 λ(δ) pass through the origin, i.e., hλ(0) = h0 λ(0) = 0. (d) h0 λ(δ) is bounded, i.e., |h0 λ(δ)| λ for any δ. Similar assumptions have been made in [23, 33]. Note that condition (b) in Assumption 4.3 is weaker than the smoothness condition in [33], since here it does not require hλ(δ) to be twice differentiable. Assumption 4.3 holds for a variety of nonconvex penalty functions including MCP and SCAD. In particular, MCP penalty satisfies Assumption 4.3 with ⌫= bλ and ⇣−= 1/b. Furthermore, according to condition (b), if ⇣−is smaller than the modulus of the restricted strong convexity for `(∆), (3.7) will become a convex optimization problem, even though Gλ(∆) is nonconvex. Take MCP for example, this can be achieved by choosing a sufficiently large b in MCP such that ⇣−is small enough. Now we are ready to present our main theories. We first show that under a large magnitude condition on nonzero entries of the true differential graph ∆⇤, our estimator attains a faster convergence rate, which matches the minimax rate in the classical regime. Theorem 4.4. Suppose Assumptions 4.1 and 4.2 hold, and the nonconvex penalty Gλ(∆) satisfies conditions in Assumption 4.3. If nonzero entries of ∆⇤satisfy min(j,k)2S |∆⇤ jk| ≥⌫+ C✓2 X✓2 Y σXσY M p log s/n, for the estimator b∆in (3.7) with the regularization parameter satisfying λ = 2CM p log d/n and ⇣−12/2, we have that // b∆−∆⇤// 1,1 2 p 10⇡✓2 X✓2 Y σXσY M r log s n holds with probability at least 1 −2/s. Furthermore, we have that k b∆−∆⇤kF C1M 12 r s n holds with probability at least 1 −3/s, where C1 is an absolute constant. Remark 4.5. Theorem 4.4 suggests that under the large magnitude assumption, the statistical rate of our estimator is O( p s/n) in terms of Frobenius norm. This is faster than the rate O( p s log d/n) in [38] which matches the minimax lower bound for sparse differential graph estimation. Note that our faster rate is not contradictory to the minimax lower bound, because we restrict ourselves to a smaller class of differential graphs, where the magnitude of the nonzero entries is sufficiently large. We further show that our estimator achieves oracle property under mild conditions. Theorem 4.6. Under the same conditions of Theorem 4.4, for the estimator b∆in (3.7) and the oracle estimator b∆O in (4.1), we have with probability at least 1−3/s that b∆= b∆O, which further implies supp( b∆) = supp( b∆O) = supp(∆⇤). Theorem 4.6 suggests that our estimator is identical to the oracle estimator in (4.1) with high probability, when the nonzero entries in ∆⇤satisfy min(j,k)2S |∆⇤ jk| ≥⌫+ C✓2 X✓2 Y σXσY M p log s/n. This condition is optimal up to the logarithmic factor plog s. Now we turn to the general case when the nonzero entries of ∆⇤have both large and small magnitudes. Define Sc = {(j, k) : j, k = 1, . . . , d} \ S, S1 = {(j, k) 2 S : |∆⇤ jk| > ⌫}, and S2 = {(j, k) 2 S : |∆⇤ jk| ⌫}. Denote |S1| = s1 and |S2| = s2. Clearly, we have s = s1 + s2. Theorem 4.7. Suppose Assumptions 4.1 and 4.2 hold, and the nonconvex penalty Gλ(∆) satisfies conditions in Assumption 4.3. For the estimator in (3.7) with the regularization parameter λ = 2CM p log d/n and ⇣−12/4, we have that k b∆−∆⇤kF 16 p 3⇡M 12 rs1 n + 10⇡MC 12 r s2 log d n holds with probability at least 1 −3/s1, where C is an absolute constant. Remark 4.8. Theorem 4.7 indicates that when the large magnitude condition does not hold, our estimator is still able to attain a faster rate. Specifically, for those nonzero entries of ∆⇤with large magnitude, the estimation error bound in terms of Frobenius norm is O( p s1/n), which is the same 5 as the bound in Theorem 4.4. For those nonzero entries of ∆⇤with small magnitude, the estimation error is O( p s2 log d/n), which matches the convergence rate in [38]. Overall, our estimator obtains a refined rate of convergence rate O( p s1/n + p s2 log d/n), which is faster than [38]. In particular, if s⇤ 2 = 0, the refined convergence rate in Theorem 4.7 reduces to the faster rate in Theorem 4.4. 5 Experiments In this section, we test our method on both synthetic and real world data. We conducted experiments for our estimator using both SCAD and MCP penalties. We did not find any significant difference in the results and thus we only report the results of our estimator with MCP penalty. To choose the tuning parameters λ and b, we adopt 5-fold cross-validation. Denoting our estimator with MCP penalty by LDGM-MCP, we compare it with the following methods: (1) SepGlasso: estimating the latent precision matrices separately using graphical Lasso and Kendall’s tau correlation matrices [20], followed by calculating their difference; (2) DPM: directly estimating differential precision matrix [38]. In addition, we also test differential graph model with `1,1 penalty, denoted as LDGM-L1. Note that LDGM-L1 is a special case of our method, since `1,1 norm penalty is a special case of MCP penalty when b = 1. The LDGM-MCP and LDGM-L1 estimators are obtained by solving the proximal gradient descent algorithm [4]. The implementation of DPM estimator is obtained from the author’s website, and the SepGlasso estimator is implemented by graphical Lasso. 5.1 Simulations We first show the results on synthetic data. Since the transelliptical distribution includes Gaussian distribution, it is natural to show that our approach also works well for the latter one. We consider the dimension settings n = 100, d = 100 and n = 200, d = 400 respectively. Specifically, data are generated as follows: (1) For the Gaussian distribution, we generate data {Xi}n i=1 ⇠N(0, ⌃⇤ X) and {Yi}n i=1 ⇠N(0, ⌃⇤ Y ) with precision matrices ⌃⇤−1 X and ⌃⇤−1 Y generated by huge package 1. (2) For the transelliptical distribution, we consider the following generating scheme: {Xi}n i=1 ⇠ TEd(⌃⇤ X, ⇠; f1, . . . , fd), {Yi}n i=1 ⇠TEd(⌃⇤ Y , ⇠; g1, . . . , gd), where ⇠⇠χd, f −1 1 (·) = . . . = f −1 d = sign(·)| · |3 and g−1 1 (·) = . . . = g−1 d (·) = sign(·)| · |1/2. The latent precision matrices ⌃⇤−1 X and ⌃⇤−1 Y are generated in the same way as the Gaussian data. For both Gaussian and transelliptical differential graph mdoels, we consider two settings for individual graph structures: (1) both ⌃⇤−1 X and ⌃⇤−1 Y have "random" structures; (2) ⌃⇤−1 X has a "band" structure, ⌃⇤−1 Y has a "random" structure. Given an estimator b∆, we define the true positive and negative rates of b∆as TP = Pd j,k=1 1(b∆jk 6= 0 and ∆⇤ jk 6= 0) Pd j,k=1 1(∆⇤ jk 6= 0) , TN = Pd j,k=1 1(b∆jk = 0 and ∆⇤ jk = 0) Pd j,k=1 1(∆⇤ jk = 0) . The receiver operating characteristic (ROC) curves for transelliptical differential graph models are shown in Figure 1, which report the performances of different methods on support recovery. The ROC curves were plotted by averaging the results over 10 repetitions. From Figure 1 we can see our estimator (LDGM-MCP) outperforms other methods in all settings. In addition, LDGM-L1 as a special case of our estimator also performs better than DPM and SepGlasso, although it is inferior to LDGM-MCP because the MCP penalty can correct the bias in the estimation and achieve faster rate of convergence. Note that SepGlasso’s performace is poor since it highly depends on the sparsity of both individual graphs. When n > 100, the DPM method failed to output the solution in one day and thus no result was presented. This computational burden is also stated in their paper. We use the Frobenius norm k b∆−∆⇤kF and infinity norm k b∆−∆⇤k1,1 of estimation errors to evaluate the performances of different methods in estimation. The results averaged over 10 replicates for transelliptical differential graph are summarized in Tables 1 and 2 respectively. Our estimator also achieves smaller error than the other baselines in all settings. Due to the space limit, we defer the experiment results for Gaussian differential graph model to the appendix. 1Available on http://cran.r-project.org/web/packages/huge 6 1-TN 0 0.2 0.4 0.6 0.8 1 TP 0 0.2 0.4 0.6 0.8 1 SepGlasso DPM LDGM-L1 LDGM-MCP (a) Setting 1: n=100,d=100 1-TN 0 0.2 0.4 0.6 0.8 1 TP 0 0.2 0.4 0.6 0.8 1 SepGlasso DPM LDGM-L1 LDGM-MCP (b) Setting 2: n=100,d=100 1-TN 0 0.2 0.4 0.6 0.8 1 TP 0 0.2 0.4 0.6 0.8 1 SepGlasso LDGM-L1 LDGM-MCP (c) Setting 1: n=200,d=400 1-TN 0 0.2 0.4 0.6 0.8 1 TP 0 0.2 0.4 0.6 0.8 1 SepGlasso LDGM-L1 LDGM-MCP (d) Setting 2:n=200,d=400 Figure 1: ROC curves for transelliptical differential graph models of all the 4 methods. There are two settings of graph structure. Note that DPM is not scalable to d = 400. Table 1: Comparisons of estimation errors in Frobenius norm k b∆−∆⇤kF for transelliptical differential graph models. N/A means the algorithm did not output the solution in one day. n = 100, d = 100 n = 200, d = 400 Methods Setting 1 Setting 2 Setting 1 Setting 2 SepGlasso 13.5730±0.6376 25.6664±0.6967 22.1760±0.3839 39.9847±0.1856 DPM 12.7219±0.3704 23.0548±0.2669 N/A N/A LDGM-L1 12.0738±0.4955 22.3748±0.6643 20.6537±0.3778 31.7630±0.0715 LDGM-MCP 11.2831±0.3919 19.6154±0.5106 20.1071±0.4303 28.8676±0.1425 Table 2: Comparisons of estimation errors in infinity norm k b∆−∆⇤k1,1 for transelliptical differential graph models. N/A means the algorithm did not output the solution in one day. n = 100, d = 100 n = 200, d = 400 Methods Setting 1 Setting 2 Setting 1 Setting 2 SepGlasso 2.7483±0.0575 8.0522±0.1423 2.1409±0.0906 6.0108±0.1925 DPM 2.3138±0.0681 6.3250±0.0560 N/A N/A LDGM-L1 2.2193±0.0850 6.0716±0.1150 1.8876±0.0907 5.1858±0.0218 LDGM-MCP 1.7010±0.0149 4.6522±0.1337 1.7339±0.0061 4.0133±0.0521 5.2 Experiments on Real World Data We applied our approach to the same gene expression data used in [38], which were collected from patients with stage III or IV ovarian cancer. [29] identified six molecular subtypes of ovarian cancer in this data, labeled C1 through C6. In particular, the C1 subtype was found to have much shorter survival times, and was characterized by differential expression of genes associated with stromal and immune cell types. In this experiment, we intended to investigate whether the C1 subtype was also associated with the genetic differential networks. The subjects were divided into two groups: Group 1 with n1 = 78 patients containing C1 subtype, and Group 2 with n2 = 113 patients containing C2 through C6 subtypes. We analyzed two pathways from the KEGG pathway database [16, 17] respectively. In each pathway, we applied different methods to determine whether there is any difference in the conditional dependency relationships of the gene expression levels between the aforementioned Group 1 and Group 2. Two genes were connected in the differential network if their conditional dependency relationship given the others changed in either magnitude or sign. In order to obtain a clear view of the differential graph, we only plotted genes whose conditional dependency with others changed between the two groups. To interpret the results, the genes associated with more edges in the differential networks were considered to be more important. Figure 2 shows the results of estimation for the differential graph of the TGF-β pathway, where the number of genes d = 80 is greater than n1, the sample size of Group 1. LDGM-MCP identified two important genes, COMP and THBS2, both of which have been suggested to be related to resistance to platinum-based chemotherapy in epithelial ovarian cancer by [24]. LDGM-L1 suggested that COMP 7 ● ● ● ● ● ● ● ● ● ● ● ● ● BMP4 BMP7 BMPR1B COMP DCN ID1 ID2 ID3 ID4 INHBA SMAD7 THBS1 THBS2 (a) SepGlasso ● ● ● ● ● ● ID1 BMP7 DCN THBS2 COMP INHBA (b) DPM ● ● ● ● ● ● ● CDKN2B COMP ID1 ID2 ID3 THBS1 THBS2 (c) LDGM-L1 ● ● ● ● ● ● COMP ID2 SMAD7 PITX2 THBS1 THBS2 (d) LDGM-MCP Figure 2: Estimates of the differential networks between Group 1 and Group 2. Dataset: KEGG 04350, TGF-β pathway. ● ● ● ● ● BIRC3 FAS CSF2RB IL1B TNFSF10 (a) SepGlasso ● ● ● ● ● ● ● ● ● ● TP53 IL1R1 FAS BIRC3 CSF2RB PRKAR2B TNFSF10 AIFM1 PIK3R1 ENDOG (b) DPM ● ● ● ● ● ● BIRC3 ENDOG PIK3R1 PRKAR2B TNFSF10 AIFM1 (c) LDGM-L1 ● ● ● ● ● ● BIRC3 CSF2RB ENDOG PIK3R1 TNFSF10 AIFM1 (d) LDGM-MCP Figure 3: Estimates of the differential networks between Group 1 and Group 2. Dataset: KEGG 04210, Apoptosis pathway. was important, and DPM also suggested COMP and THBS2. Separate estimation (SepGlasso) gave a relatively dense network, which made it hard to say which genes are more important. Figure 3 shows the results for the Apoptosis pathway, where the number of genes d = 87 is also greater than n1. LDGM-MCP indicated that TNFSF10 and BIRC3 were the most important. Indeed, both TNFSF10 and BRIC3 have been widely studied for use as a therapeutic target in cancer [5, 32]. LDGM-L1 and DPM also suggested TNFSF10 and BRIC3 were important. The results of LDGMMCP, LDGM-L1 and DPM are comparable. In order to overcome the nonsparsity issue encountered in TGF-β experiment, the SepGlasso estimator was thresholded more than the other methods. However, it still performed poorly and identified the wrong gene CSF2RB. 6 Conclusions In this paper, we propose a semiparametric differential graph model and an estimator for the differential graph based on quasi likelihood maximization. We employ a nonconvex penalty in our estimator, which results in a faster rate for parameter estimation than existing methods. We also prove that the proposed estimator achieves oracle property under a mild condition. Experiments on both synthetic and real world data further support our theory. Acknowledgments We would like to thank the anonymous reviewers for their helpful comments. Research was supported by NSF grant III-1618948. References [1] BANDYOPADHYAY S, K. D. E. A., MEHTA M (2010). Rewiring of genetic networks in response to dna damage. Science 330 1385–1389. [2] BARBER, R. F. and KOLAR, M. (2015). Rocket: Robust confidence intervals via kendall’s tau for transelliptical graphical models. arXiv preprint arXiv:1502.07641 . [3] BASSO, K., MARGOLIN, A. A., STOLOVITZKY, G., KLEIN, U., DALLA-FAVERA, R. and CALIFANO, A. (2005). Reverse engineering of regulatory networks in human b cells. Nature genetics 37 382–390. [4] BECK, A. and TEBOULLE, M. (2009). A fast iterative shrinkage-thresholding algorithm for linear inverse problems. SIAM journal on imaging sciences 2 183–202. [5] BELLAIL A C, M. P. E. A., QI L (2009). Trail agonists on clinical trials for cancer therapy: the promises and the challenges. Reviews on recent clinical trials 4 34–41. 8 [6] CARTER S L, G. M. E. A., BRECHBÜHLER C M (2004). Gene co-expression network topology provides a framework for molecular characterization of cellular state. Bioinformatics 20 2242–2250. [7] CHIQUET, J., GRANDVALET, Y. and AMBROISE, C. (2011). Inferring multiple graphical structures. Statistics and Computing 21 537–553. [8] DANAHER, P., WANG, P. and WITTEN, D. M. (2014). The joint graphical lasso for inverse covariance estimation across multiple classes. Journal of the Royal Statistical Society: Series B 76 373–397. [9] DE LA FUENTE, A. (2010). From ‘differential expression’to ‘differential networking’–identification of dysfunctional regulatory networks in diseases. Trends in genetics 26 326–333. [10] FAN, J. and LI, R. (2001). Variable selection via nonconcave penalized likelihood and its oracle properties. Journal of the American statistical Association 96 1348–1360. [11] FAZAYELI, F. and BANERJEE, A. (2016). Generalized direct change estimation in ising model structure. arXiv preprint arXiv:1606.05302 . [12] FRIEDMAN, J., HASTIE, T. and TIBSHIRANI, R. (2008). Sparse inverse covariance estimation with the graphical lasso. Biostatistics 9 432–441. [13] GOLUB, G. H. and LOAN, C. F. V. (1996). Matrix computations (3rd ed.). Johns Hopkins University Press, Baltimore, MD, USA. [14] GUO, J., LEVINA, E., MICHAILIDIS, G. and ZHU, J. (2011). Joint estimation of multiple graphical models. Biometrika asq060. [15] HUDSON, N. J., REVERTER, A. and DALRYMPLE, B. P. (2009). A differential wiring analysis of expression data correctly identifies the gene containing the causal mutation. PLoS Comput Biol 5 e1000382. [16] KANEHISA, M. and GOTO, S. (2000). Kegg: kyoto encyclopedia of genes and genomes. Nucleic acids research 28 27–30. [17] KANEHISA, M., GOTO, S., SATO, Y., FURUMICHI, M. and TANABE, M. (2011). Kegg for integration and interpretation of large-scale molecular data sets. Nucleic acids research gkr988. [18] LAURITZEN, S. L. (1996). Graphical models. Clarendon Press. [19] LI, P., PIAO, Y., SHON, H. S. and RYU, K. H. (2015). Comparing the normalization methods for the differential analysis of illumina high-throughput rna-seq data. BMC bioinformatics 16 1. [20] LIU, H., HAN, F. and ZHANG, C.-H. (2012). Transelliptical graphical models. In NIPS. [21] LIU, H., LAFFERTY, J. and WASSERMAN, L. (2009). The nonparanormal: Semiparametric estimation of high dimensional undirected graphs. The Journal of Machine Learning Research 10 2295–2328. [22] LIU, S., SUZUKI, T. and SUGIYAMA, M. (2014). Support consistency of direct sparse-change learning in markov networks. arXiv preprint arXiv:1407.0581 . [23] LOH, P.-L. and WAINWRIGHT, M. J. (2013). Regularized m-estimators with nonconvexity: Statistical and algorithmic theory for local optima. In NIPS. [24] MARCHINI, E. A., SERGIO (2013). Resistance to platinum-based chemotherapy is associated with epithelial to mesenchymal transition in epithelial ovarian cancer. European journal of cancer 49 520–530. [25] MEINSHAUSEN, N. and BÜHLMANN, P. (2006). High-dimensional graphs and variable selection with the lasso. The annals of statistics 1436–1462. [26] OSHLACK, A., ROBINSON, M. D., YOUNG, M. D. ET AL. (2010). From rna-seq reads to differential expression results. Genome biol 11 220. [27] RAVIKUMAR, P., WAINWRIGHT, M. J., RASKUTTI, G., YU, B. ET AL. (2011). High-dimensional covariance estimation by minimizing `1-penalized log-determinant divergence. EJS 5 935–980. [28] TIAN, D., GU, Q. and MA, J. (2016). Identifying gene regulatory network using latent differential graphical models. Nucleic Acids Research 44 e140–e140. [29] TOTHILL R W, G. J. E. A., TINKER A V (2008). Novel molecular subtypes of serous and endometrioid ovarian cancer linked to clinical outcome. Clinical Cancer Research 14 5198–5208. [30] VAN DER VAART, A. V. (1998). Asymptotic statistics. Cambridge University Press, Cambridge, UK. [31] VERSHYNIN, R. (2010). Introduction to the non-asymptotic analysis of random matrices. arXiv preprint arXiv:1011.3027 . [32] VUCIC, D. and FAIRBROTHER, W. J. (2007). The inhibitor of apoptosis proteins as therapeutic targets in cancer. Clinical Cancer Research 13 5995–6000. [33] WANG, Z., LIU, H. and ZHANG, T. (2014). Optimal computational and statistical rates of convergence for sparse nonconvex learning problems. Annals of statistics 42 2164. [34] WEGKAMP, M. and ZHAO, Y. (2013). Adaptive estimation of the copula correlation matrix for semiparametric elliptical copulas. arXiv preprint arXiv:1305.6526 . [35] YUAN, H., XI, R. and DENG, M. (2015). Differential network analysis via the lasso penalized d-trace loss. arXiv preprint arXiv:1511.09188 . [36] ZHANG, C.-H. (2010). Nearly unbiased variable selection under minimax concave penalty. The Annals of Statistics 894–942. [37] ZHANG, T. and ZOU, H. (2014). Sparse precision matrix estimation via lasso penalized d-trace loss. Biometrika ast059. [38] ZHAO, S. D., CAI, T. T. and LI, H. (2014). Direct estimation of differential networks. Biometrika 101 253–268. 9 | 2016 | 553 |
6,498 | Neural Universal Discrete Denoiser Taesup Moon DGIST Daegu, Korea 42988 tsmoon@dgist.ac.kr Seonwoo Min, Byunghan Lee, Sungroh Yoon Seoul National University Seoul, Korea 08826 {mswzeus, styxkr, sryoon}@snu.ac.kr Abstract We present a new framework of applying deep neural networks (DNN) to devise a universal discrete denoiser. Unlike other approaches that utilize supervised learning for denoising, we do not require any additional training data. In such setting, while the ground-truth label, i.e., the clean data, is not available, we devise “pseudolabels” and a novel objective function such that DNN can be trained in a same way as supervised learning to become a discrete denoiser. We experimentally show that our resulting algorithm, dubbed as Neural DUDE, significantly outperforms the previous state-of-the-art in several applications with a systematic rule of choosing the hyperparameter, which is an attractive feature in practice. 1 Introduction Cleaning noise-corrupted data, i.e., denoising, is a ubiquotous problem in signal processing and machine learning. Discrete denoising, in particular, focuses on the cases in which both the underlying clean and noisy data take their values in some finite set. Such setting covers several applications in different domains, such as image denoising [1, 2], DNA sequence denoising [3], and channel decoding [4]. A conventional approach for addressing the denoising problem is the Bayesian approach, which can often yield a computationally efficient algorithm with reasonable performance. However, limitations can arise when the assumed stochastic models do not accurately reflect the real data distribution. Particularly, while the models for the noise can often be obtained relatively reliably, obtaining the accurate model for the original clean data is more tricky; the model for the clean data may be wrong, changing, or may not exist at all. In order to alleviate the above mentioned limitations, [5] proposed a universal approach for discrete denoising. Namely, they first considered a general setting that the clean finite-valued source symbols are corrupted by a discrete memoryless channel (DMC), a noise mechanism that corrupts each source symbol independently and statistically identically. Then, they devised an algorithm called DUDE (Discrete Universal DEnoiser) and showed rigorous performance guarantees for the semi-stochastic setting; namely, that where no stochastic modeling assumptions are made on the underlying source data, while the corruption mechanism is assumed to be governed by a known DMC. DUDE is shown to universally attain the optimum denoising performance for any source data as the data size grows. In addition to the strong theoretical performance guarantee, DUDE can be implemented as a computationally efficient sliding window denoiser; hence, it has been successfully applied and extended to some practical applications, e.g., [1, 3, 4, 2]. However, it also had limitations; namely, the performance is sensitive on the choice of sliding window size k, which has to be hand-tuned without any systematic rule. Moreover, when k becomes large and the alphabet size of the signal increases, DUDE suffers from the data sparsity problem, which significantly deteriorates the performance. In this paper, we present a novel framework of addressing above limitations of DUDE by adopting the machineries of deep neural networks (DNN) [6], which recently have seen great empirical success 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. in many practical applications. While there have been some previous attempts of applying neural networks to grayscale image denoising [7, 8], they all remained in supervised learning setting, i.e., large-scale training data that consists of clean and noisy image pairs was necessary. Such approach requires significant computation resources and training time and is not always transferable to other denoising applications, in which collecting massive training data is often expensive, e.g., DNA sequence denoising [9]. Henceforth, we stick to the setting of DUDE, which requires no additional data other than the given noisy data. In this case, however, it is not straightforward to adopt DNN since there is no ground-truth label for supervised training of the networks. Namely, the target label that a denoising algorithm is trying to estimate from the observation is the underlying clean signal, hence, it can never be observed to the algorithm. Therefore, we carefully exploit the known DMC assumption and the finiteness of the data values, and devise “pseudo-labels” for training DNN. They are based on the unbiased estimate of the true loss a denoising algorithm is incurring, and we show that it is possible to train a DNN as a universal discrete denoiser using the devised pseudo-labels and generalized cross-entropy objective function. As a by-product, we also obtain an accurate estimator of the true denoising performance, with which we can systematically choose the appropriate window size k. In results, we experimentally verify that our DNN based denoiser, dubbed as Neural DUDE, can achieve significantly better performance than DUDE maintaining robustness with respect to k. Furthermore, we note that although the work in this paper is focused on discrete denoising, we believe the proposed framework can be extended to the denoising of continuous-valued signal as well, and we defer it to the future work. 2 Notations and related work 2.1 Problem setting of discrete denoising Throughout this paper, we will generally denote a sequence (n-tuple) as, e.g., an = (a1, . . . , an), and aj i refers to the subsequence (ai, . . . , aj). In discrete denoising problem, we denote the clean, underlying source data as xn and assume each component xi takes a value in some finite set X. The source sequence is corrupted by a DMC and results in a noisy version of the source zn, of which each component zi takes a value in , again, some finite set Z. The DMC is completely characterized by the channel transition matrix Π ∈R|X|×|Z|, of which the (x, z)-th element, Π(x, z), stands for Pr(Zi = z|Xi = x), i.e., the conditional probability of the noisy symbol taking value z given the original source symbol was x. An essential but natural assumption we make is that Π is of the full row rank. Upon observing the entire noisy data zn, a discrete denoiser reconstructs the original data with ˆXn = ( ˆX1(zn), . . . , ˆXn(zn)), where each reconstructed symbol ˆXi(zn) also takes its value in a finite set ˆ X. The goodness of the reconstruction by a discrete denoiser ˆXn is measured by the average loss, L ˆ Xn(Xn, Zn) = 1 n Pn i=1 Λ(xi, ˆXi(zn)), where Λ(xi, ˆxi) is a single-letter loss function that measures the loss incurred by estimating xi with ˆxi at location i. The loss function can be also represented with a loss matrix Λ ∈R|X|×| ˆ X|. Throughout the paper, for simplicity, we will assume X = Z = ˆ X, thus, assume that Π is invertible. 2.2 Discrete Universal DEnoiser (DUDE) DUDE in [5] is a two-pass algorithm that has a linear complexity in the data size n. During the first pass, the algorithm with the window size k collects the statistics vector m[zn, lk, rk](a) = {i : k + 1 ≤i ≤n −k, zi+k i−k = lkark} , (1) for all a ∈Z, which is the count of the occurrence of the symbol a ∈Z along the noisy sequence zn that has the double-sided context (lk, rk) ∈Z2k. Once the m vector is collected, for the second pass, DUDE applies the rule ˆXi,DUDE(zn) = arg min ˆx∈X m[zn, ci]⊤Π−1[λˆx ⊙πzi] for each k + 1 ≤i ≤n −k, (2) where ci ≜(zi−1 i−k, zi+k i+1) is the context of zi, πzi is the zi-th column of the channel matrix Π, λˆx is the ˆx-th column of the loss matrix Λ, and ⊙stands for the element-wise product. The form of (2) 2 shows that DUDE is a sliding window denoiser with window size 2k + 1; namely, DUDE returns the same denoised symbol at all locations i’s with the same value of zi+k i−k. We will call such denoisers as the k-th order sliding window denoiser from now on. DUDE is shown to be universal, i.e., for any underlying clean sequence xn, it can always attain the performance of the best k-th order sliding window denoiser as long as k|Z|2k = o(n/ log n) holds [5, Theorem 2]. For more rigorous analyses, we refer to the original paper [5]. 2.3 Deep neural networks (DNN) and related work Deep neural networks (DNN), often dubbed as deep learning algorithms, have recently made significant impacts in several practical applications, such as speech recognition, image recognition, and machine translation, etc. For a thorough review on recent progresses of DNN, we refer the readers to [6] and refereces therein. Regarding denoising, [7, 8, 10] have successfully applied the DNN to grayscale image denoising by utilizing supervised learning at the small image patch level. Namely, they generated clean and noisy image patches and trained neural networks to learn a mapping from noisy to clean patches. While such approach attained the state-of-the-art performance, as mentioned in Introduction, it has several limitations. That is, it typically requires massive amount of training data, and multiple copies of the data need to be generated for different noise types and levels to achieve robust performance. Such requirement of large training data cannot be always met in other applications, e.g., in DNA sequence denoising, collecting large scale clean DNA sequences is much more expensive than obtaining training images on the web. Moreover, for image denoising, working in the small patch level makes sense since the image patches may share some textual regularities, but in other applications, the characterstics of the given data for denoising could differ from those in the pre-collected training set. For instance, the characteristics of substrings of DNA sequences vary much across different species and genes, hence, the universal setting makes more sense in DNA sequence denoising. 3 An alternative interpretation of DUDE 3.1 Unbiased estimated loss In order to make an alternative interpretation of DUDE, which can be also found in [11], we need the tool developed in [12]. To be self-contained, we recap the idea here. Consider a single letter case, namely, a clean symbol x is corrupted by Π and resulted in the noisy observation1 Z. Then, suppose a single-symbol denoiser s : Z →ˆ X is applied and obtained the denoised symbol ˆX = s(Z). In this case, the true loss incurred by s for the clean symbol x and the noisy observation Z is Λ(x, s(Z)). It is clear that s cannot evaluate its loss since it does not know what x is, but the following shows an unbiased estimate of the expected true loss, which is only based on Z and s, can be derived. First, denote S as the set of all possible single-symbol denoisers. Note |S| = | ˆ X||Z|. Then, we define a matrix ρ ∈R|X|×|S| with ρ(x, s) = X z∈Z Π(x, z)Λ(x, s(z)) = ExΛ(x, s(Z)), x ∈X, s ∈S. (3) Then, we can define an estimated loss matrix2 L ≜Π−1ρ ∈R|Z|×|S|. With this definition, we can show that L(Z, s) is an unbiased estimate of ExΛ(x, s(Z)) as follows (as shown in [12]): ExL(Z, s) = X z Π(x, z) X x′ Π−1(z, x′)ρ(x′, s) = δ(x, x′)ρ(x′, s) = ρ(x, s) = ExΛ(x, s(Z)). 3.2 DUDE: Minimizing the sum of estimated losses As mentioned in Section 2.2, DUDE with context size k is the k-th order sliding window denoiser. Generally, we can denote such k-th order sliding window denoiser as sk : Z2k+1 →ˆ X, which 1We use uppercase letter Z to stress it is a random variable 2For general case in which Π is not a square matrix, Π−1 can be replaced with the right inverse of Π. 3 obtains the reconstruction at the i-th location as ˆXi(zn) = sk(zi+k i−k) = sk(ci, zi). (4) To recall, ci = (zi−1 i−k, zi+k i+1). Now, from the formulation (4), we can interpret that sk defines a single-symbol denoiser at location i, i.e., sk(ci, ·), depending on ci. With this view on sk, as derived in [11], we can show that the DUDE defined in (2) is equivalent to finding a single-symbol denoiser sk,DUDE(c, ·) = arg min s∈S X {i:ci=c} L(zi, s), (5) for each context c ∈Ck ≜{(lk, rk) : (lk, rk) ∈Z2k} and obtaining the reconstruction at location i as ˆXi,DUDE(zn) = sk,DUDE(ci, zi). The interpretation (5) gives some intuition on why DUDE enjoys strong theoretical guarantees in [5]; since L(Zi, s) is an unbiased estimate of ExiΛ(xi, s(Zi)), P i∈{i:ci=c} L(Zi, s) will concentrate on P i∈{i:ci=c} Λ(xi, s(Zi)) as long as |{i : ci = c}| is sufficiently large. Hence, the single symbol denoiser that minimizes the sum of the estimated losses for each c (i.e., (5)) will also make the sum of the true losses small, which is the goal of a denoiser. We can also express (5) using vector notations, which will become useful for deriving the Neural DUDE in the next section. That is, we let ∆|S| be a probability simplex in R|S|. (Suppose we have uniquely assigned each coordinate of R|S| to each single-symbol denoiser in S from now on.) Then, we can define a probability vector for each c, ˆp(c) ≜arg min p∈∆|S| X {i:ci=c} 1⊤ ziL p, (6) which will be on the vertex of ∆|S| that corresponds to sk,DUDE(c, ·) in (5). The reason is because the objective function in (6) is a linear function in p. Hence, we can simply obtain sk,DUDE(c, ·) = arg maxs ˆp(c)s, where ˆp(c)s stands for the s-th coordinate of ˆp(c). 4 Neural DUDE: A DNN based discrete denoiser As seen in the previous section, DUDE utilizes the estimated loss matrix L, which does not depend on the clean sequence xn. However, the main drawback of DUDE is that, as can be seen in (5), it treats each context c independently from others. Namely, when the context size k grows, then the number of different contexts |Ck| = |Z|2k will grow exponentially with k, hence, the sample size for each context |{i : ci = c}| will decrease exponentially for a given sequence length n. Such phenomenon will hinder the concentration of P i∈{i:ci=c} L(Zi, s) mentioned in the previous section, which causes the performance of DUDE deteriorate when k grows too large. In order to resolve above problem, we develop Neural DUDE, which adopts a single neural network such that the information from similar contexts can be shared via network parameters. We note that our usage of DNN resembles that of the neural language model (NLM) [13], which improved upon the conventional N-gram models. The difference is that NLM is essentially a prediction problem, hence the ground truth label for supervised training is easily availble, but in denoising, this is not the case. Before describing the algorithm more in detail, we need one following lemma. 4.1 A lemma Let R|S| + be the space of all |S|-dimensional vectors of which elements are nonnegative. Then, for any g ∈R|S| + and any p ∈∆|S|, define a cost function C(g, p) ≜−P|S| i=1 gi log pi, i.e., a generalized cross-entropy function with the first argument not normalized to a probability vector. Note C(g, p) is linear in g and convex in p. Now, following lemma shows another way of obtaining DUDE. Lemma 1 Define Lnew ≜−L + Lmax11⊤in which Lmax ≜maxz,s L(z, s), the maximum element of L. Using the cost function C(·, ·) defined above, for each c ∈Ck, let us define p∗(c) ≜arg min p∈∆|S| X {i:ci=c} C L⊤ new1zi, p . Then, we have sk,DUDE(c, ·) = arg maxs p∗(c)s. Proof: The proof of lemma is given in the Supplementary Material. 4 4.2 Neural DUDE The main idea for Neural DUDE is to use a single neural network to learn the k-th order slinding window denoising rule for all c’s. Namely, we define p(w, ·) : Z2k →∆|S| as a feed-forward neural network that takes the context vector c ∈Ck as input and outputs a probability vector on ∆|S|. We let w stand for all the parameters in the network. The network architecture of p(w, ·) has the softmax output layer, and it is analogous to that used for the multi-class classification. Thus, when the parameters are properly learned, we expect that p(w, ci) will give predictions on which single-symbol denoiser to apply at location i with the context ci. 4.2.1 Learning When not resorting to the supervised learning framework, learning the network parameters w is not straightforward as mentioned in the Introduction. However, inspired by Lemma 1, we define the objective function to minimize for learning w as L(w, zn) ≜ 1 n n X i=1 C L⊤ new1zi, p(w, ci) , (7) which resembles the widely used cross-entropy objective function in supervised multi-class classification. Namely, in (7), {(ci, L⊤ new1zi)}n i=1, which solely depends on the noisy sequence zn, can be analogously thought of as the input-label pairs in supervised learning. (Note for i ≤k and i ≥n −k, dummy variables are padded for obtaining ci.) But, unlike classification, in which the ground-truth label is given as a one-hot vector, we treat L⊤ new1zi ∈R|S| + as a target “pseudo-label” on S. Once the objective function is set as in (7), we can then use the widely used optimization techniques, namely, the back-propagation and Stochastic Gradient Descent (SGD)-based methods, for learning the parameters w. In fact, most of the well-known improvements to the SGD method, such as the momentum [14], mini-batch SGD, and several others [15, 16], can be all used for learning w. Note that there is no notion of generalization in our setting, since the goal of denoising is to simply achieve as small average loss as possible for the given noisy sequence zn, rather than performing well on the separate unseen test data. Hence, we do not use any regularization techniques such as dropout in our learning, but simply try to minimize the objective function. 4.2.2 Denoising After sufficient iterations of weight updates, the objective function (7) will converge, and we will denote the converged parameters as w∗. The Neural DUDE algorithm then applies the resulting network p(w∗, ·) to the exact same noisy sequence zn used for learning to denoise. Namely, for each c ∈Ck, we obtain a single-symbol denoiser sk,Neural DUDE(c, ·) = arg max s p(w∗, c)s (8) and the reconstruction at location i by ˆXi,DUDE(zn) = sk,Neural DUDE(ci, zi). From the objective function (7) and the definition (8), it is apparent that Neural DUDE does share information across different contexts since w∗is learnt from all data and shared across all contexts. Such property enables Neural DUDE to robustly run with much larger k’s than DUDE without running into the data sparsity problem. As shown in the experimental section, Neural DUDE with large k can significantly improve the denoising performance compared to DUDE. Furthermore, in the experimental section, we show that the concentration 1 n n X i=1 L(Zi, sk,Neural DUDE(ci, ·)) ≈1 n n X i=1 Λ(xi, sk,Neural DUDE(ci, Zi)) (9) holds with high probability even for very large k’s, whereas such concentration quickly breaks for DUDE as k grows. While deferring the analyses on why such concentration always holds to the future work, we can use the property to provide a systematic mechanism for choosing the best context size k for Neural DUDE - simply choose k∗= arg mink 1 n Pn i=1 L(Zi, sk,Neural DUDE(ci, ·)). As shown in the experiments, such choice of k for Neural DUDE gives an excellent denoising performace. Algorithm 1 summarizes the Neural DUDE algorithm. 5 Algorithm 1 Neural DUDE algorithm Input: Noisy sequence zn, Π, Λ, Maximum context size kmax Output: Denoised sequence ˆXn Neural DUDE = { ˆXi,Neural DUDE(zn)}n i=1 Compute L = Π−1ρ as in Section 3.1 and Lnew as in Lemma 1 for k = 1, . . . , kmax do Initialize p(w, ·) with input dimension 2k|Z| (using one-hot encoding of each noisy symbol) Obtain w∗ k minimizing L(w, zn) in (7) using SGD-like optimization method Obtain sk,Neural DUDE(c, ·) for all c ∈Ck as in (8) using w∗ k Compute Lk ≜1 n Pn i=1 L(zi, sk,Neural DUDE(ci, ·)) end for Get k∗= arg mink Lk and obtain ˆXi,Neural DUDE(zn) = sk∗,Neural DUDE(ci, zi) for i = 1, . . . , n Remark: We note that using the cost function in (7) is important. That is, if we use a simpler objective like (5), 1 n Pn i=1(L⊤1zi)⊤p(w, ci), it becomes highly non-convex in w, and the solution w∗becomes very unstable. Moreover, using Lnew instead of L in the cost function is important as well, since it guarantees to have the cost function C(·, ·) always convex in the second argument. 5 Experimental results In this section, we show the denoising results of Neural DUDE for the synthetic binary data, real binary images, and real Oxford Nanopore MinION DNA sequence data. All of our experiments were done with Python 2.7 and Keras package (http://keras.io) with Theano [17] backend. 5.1 Synthetic binary data We first experimented with a simple synthetic binary data to highlight the core strength of Neural DUDE. That is, we assume X = Z = ˆ X = {0, 1} and Π is a binary symmetric channel (BSC) with crossover probability δ = 0.1. We set Λ as the Hamming loss. We generated the clean binary 0 2 4 6 8 10 12 14 Window size k 0.50 0.55 0.60 0.65 0.70 0.75 0.80 0.85 0.90 (Bit Error Rate) / δ 0.563δ 0.558δ DUDE Neural DUDE (1L) Neural DUDE (2L) Neural DUDE (3L) Neural DUDE (4L) FB Recursion (a) BER/δ vs. Window size k 0 2 4 6 8 10 12 14 Window size k 0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 (Bit Error Rate) / δ BER Estimated BER FB Recursion (b) DUDE 0 2 4 6 8 10 12 14 Window size k 0.52 0.54 0.56 0.58 0.60 0.62 0.64 (Bit Error Rate) / δ BER Estimated BER FB Recursion (c) Neural DUDE (4L) Figure 1: Denoising results of DUDE and Neural DUDE for the synthetic binary data with n = 106. sequence xn of length n = 106 from a binary symmentric Markov chain (BSMC) with transition probability α = 0.1. The noise-corrupted sequence zn is generated by passing xn through Π. Since we use the Hamming loss, the average loss of a denoiser ˆXn, 1 n Pn i=1 Λ(xi, ˆXi(zn)), is equal to the bit error rate (BER). Note that in this setting, the noisy sequence zn is a hidden Markov process. Therefore, when the stochastic model of the clean sequence is exactly known to the denoiser, the Viterbi-like Forward-Backward (FB) recursion algorithm can attain the optimum BER. Figure 1 shows the denoising results of DUDE and Neural DUDE, which do not know anything about the characteristics of the clean sequence xn. For DUDE, the window size k is the single hyperparameter to choose. For Neural DUDE, we used the feed-forward fully connected neural networks for p(w, ·) and varied the depth of the network between 1 ∼4 while also varying k. Neural DUDE(1L) corresponds to the simple linear softmax regression model. For deeper models, we used 40 hidden nodes in each layer with Rectified Linear Unit (ReLU) activations. We used Adam [16] with default setting in Keras as an optimizer to minimize (7). We used the mini-batch size of 100 and ran 10 epochs for learning. The performance of Neural DUDE was robust to the initializtion of the parameters w. 6 Figure 1(a) shows the BERs of DUDE and Neural DUDE with respect to varying k. Firstly, we see that minimum BERs of both DUDE and Neural DUDE(4L), i.e., 0.563δ with k = 5, get very close to the optimum BER (0.558δ) obtained by the Forward-Backward (FB) recursion. Secondly, we observe that Neural DUDE quickly approaches the optimum BER as we increase the depth of the network. This shows that as the descriminative power of the model increases with the depth of the network, p(w, ·) can successfully learn the denoising rule for each context c with a shared parameter w. Thirdly, we clearly see that in contrast to the performance of DUDE being sensitive to k, that of Neural DUDE(4L) is robust to k by sharing information across contexts. Such robustness with respect to k is obviously a very desirable property in practice. Figure 1(b) and Figure 1(c) plot the average estimated BER, 1 n Pn i=1 L(Zi, sk(ci, ·)), against the true BER for DUDE and Neural DUDE (4L), respectively, to show the concentration phenomenon described in (9). From the figures, we can see that while the estimated BER drastically diverges from true BER for DUDE as k increases, it strongly concentrates on true BER for Neural DUDE (4L) for all k. This result suggests the concrete rule for selecting the best k described in Algorithm 1. Such rule is used for the experiments using real data in the following subsections. 5.2 Real binary image denoising In this section, we experiment with real, binary image data. The settings of Π and Λ are identical to Section 5.1, while the clean sequence was generated by converting image to a 1-D sequence via raster scanning. We tested with 5 representative binary images with various textual characteristics: Einstein, Lena, Barbara, Cameraman, and scanned Shannon paper. Einstein and Shannon images had the resolution of 256 × 256 and the rest had 512 × 512. For Neural DUDE, we tested with 4 layer model with 40 hidden nodes with ReLU activations in each layer. (a) Clean image 0 5 10 15 20 25 30 35 40 Window size k 0.3 0.4 0.5 0.6 0.7 0.8 0.9 (Bit Error Rate) / δ 0.404δ 0.563δ DUDE BER Neural DUDE(4L) BER Neural DUDE(4L) Est. BER (b) BER results Figure 2: Einstein image(256 × 256) denoising results with δ = 0.1. Figure 2(b) shows the result of denoising Einstein image in Figure 2(a) for δ = 0.1. We see that the BER of Neural DUDE(4L) continues to drop as we increase k, whereas DUDE quickly fails to denoise for larger k’s. Furthermore, we observe that the estimated BER of Neural DUDE(4L) again strongly correlates with the true BER. Note that when k = 36, we have 272 possible different contexts, which are much more than the number of pixels, 216(256 × 256). However, we see that Neural DUDE can still learn a good denoising rule from such many different contexts by aggregating information from similar contexts. δ Schemes Einstein Lena Barbara Cameraman Shannon 0.15 DUDE 0.578 (5) 0.494 (6) 0.492 (5) 0.298 (6) 0.498 (5) Neural DUDE 0.384 (38) 0.405 (38) 0.448 (33) 0.264 (39) 0.410 (38) Improvement 33.6% 18.0% 9.0% 11.5% 17.7% 0.1 DUDE 0.563 (5) 0.495 (6) 0.506 (6) 0.310 (5) 0.475 (5) Neural DUDE 0.404 (36) 0.403 (38) 0.457 (27) 0.268 (35) 0.402 (35) Improvement 28.2% 18.6% 9.7% 13.6% 15.4% Table 1: BER results for binary images. Each number represents the relative BER compared to δ and the “Improvement” stands for the relative BER improvement of Neural DUDE(4L) over DUDE. The numbers inside parentheses are the k values achieving the result. Table 1 summarizes the denoising results on six binary images for δ = 0.1, 0.15. We see that Neural DUDE always significantly outperforms DUDE using much larger context size k. We believe this is a 7 significant result since DUDE is shown to outperform many state-of-the-art sliding window denoisers in practice such as median filters [5, 1]. Furthermore, following DUDE’s extension to grayscale image denoising [2], the result gives strong motivation for extending Neural DUDE to grayscale image denoising. 5.3 Nanopore DNA sequence denoising We now go beyond binary data and apply Neural DUDE to DNA sequence denoising. As surveyed in [9], denoising DNA sequences is becoming increasingly important as the sequencing devices are getting cheaper, but injecting more noise than before. For our experiment, we used simulated MinION Nanopore reads, which were generated as follows; we obtained 16S rDNA reference sequences for 20 species [18] and randomly generated noiseless template reads from them. The number of reads and read length for each species were set as identical to those of real MinION Nanopore reads [18]. Then, based on Π of MinION Nanopore sequencer (Figure 3(a)) obtained in [19] (with 20.375% average error rate), we induced substitution errors to the reads and obtained the corresponding noisy reads. Note that we are only considering substitution errors, while there also exist insertion/deletion errors in real Nanopore sequenced data. The reason is that substitution errors can be directly handled by DUDE and Neural DUDE, so we focus on quantitatively evaluating the performance on those errors. We sequentially merged 2,372 reads from 20 species and formed 1-D sequence of 2,469,111 base pairs long. We used two Neural DUDE (4L) models with 40 and 80 hidden nodes in each layer, and denoted as (40-40-40) and (80-80-80), respectively. (a) Π for nanopore sequencer 0 20 40 60 80 100 Window size k 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 (Error Rate) / δ 0.909δ 0.544δ 0.427δ DUDE Neural DUDE (40-40-40) Neural DUDE (80-80-80) (b) BER results Figure 3: Nanopore DNA sequence denoising results. Figure 3(b) shows the denoising results. We observe that Neural DUDE with large k’s (around k = 100) can achieve less than half of the error rate of DUDE. Furthermore, as the complexity of model increases, the performance of Neural DUDE gets significantly better. We could not find a comparable baseline scheme, since most of nanopore error correction tool, e.g., Nanocorr [20], did not produce read-by-read correction sequence, but returns downstream analyses results after denoising. Coral [21], which gives read-by-read denoising result for Illumina data, completely failed for the nanopore data. Given that DUDE ourperforms state-of-the-art schemes, including Coral, for Illumina sequenced data as shown in [3], we expect the improvement of Neural DUDE over DUDE could translate into fruitful downstream analyses gain for nanopore data. 6 Concluding remark and future work We showed Neural DUDE significantly improves upon DUDE and has a systematic mechanism for choosing the best k. There are several future research directions. First, we plan to do thorough experiments on DNA sequence denoising and quantify the impact of Neural DUDE in the downstream analysis. Second, we plan to give theoretical analyses on the concentration (9) and justify the derived k selection rule. Third, extending the framework to deal with continuous-valued signal and finding connection with SURE principle [22] would be fruitful. Finally, applying recurrent neural networks (RNN) in place of DNNs could be another promising direction. Acknowledgments T. Moon was supported by DGIST Faculty Start-up Fund (2016010060) and Basic Science Research Program through the National Research Foundation of Korea (2016R1C1B2012170), both funded by Ministry of Science, ICT and Future Planning. S. Min, B. Lee, and S. Yoon were supported in part by Brain Korea 21 Plus Project (SNU ECE) in 2016. 8 References [1] E. Ordentlich, G. Seroussi, S. Verdú, M.J. Weinberger, and T. Weissman. A universal discrete image denoiser and its application to binary images. In IEEE ICIP, 2003. [2] Giovanni Motta, Erik Ordentlich, Ignacio Ramirez, Gadiel Seroussi, and Marcelo J. Weinberger. The iDUDE framework for grayscale image denoising. IEEE Trans. Image Processing, 20:1–21, 2011. [3] B. Lee, T. Moon, S. Yoon, and T. Weissman. DUDE-Seq: Fast, flexible, and robust denoising of nucleotide sequences. arXiv:1511.04836, 2016. [4] E. Ordentlich, G. Seroussi, S. Verdú, and K. Viswanathan. Universal algorithms for channel decoding of uncompressed sources. IEEE Trans. Inform. Theory, 54(5):2243–2262, 2008. [5] T. Weissman, E. Ordentlich, G. Seroussi, S. Verdú, and M. J. Weinberger. Universal discrete denoising: Known channel. IEEE Trans. on Inform. Theory, 51(1):5–28, 2005. [6] G. Hinton, Y. LeCun, and Y. Bengio. Deep learning. Nature, 521:436–444, 2015. [7] H. Burger, C. Schuler, and S. Harmeling. Image denoising: Can plain neural networks compete with BM3D? In CVPR, 2012. [8] J. Xie, L. Xu, and E. Chen. Image denoising and inpainting with deep neural networks. In NIPS, 2012. [9] D. Laehnemann, A. Borkhardt, and A.C. McHardy. Denoising DNA deep sequencing data– high-throughput sequencing errors and their corrections. Brief Bioinform, 17(1):154–179, 2016. [10] V. Jain and H.S. Seung. Natural image denoising with convolutional networks. In NIPS, 2008. [11] T. Moon and T. Weissman. Discrete denoising with shifts. IEEE Trans. on Inform. Theory, 2009. [12] T. Weissman, E. Ordentlich, M. Weinberger, A. Somekh-Baruch, and N. Merhav. Universal filtering via prediction. IEEE Trans. Inform. Theory, 53(4):1253–1264, 2007. [13] Y. Bengio, R. Ducharme, P. Vincent, and C. Jauvin. A neural probabilistic language model. JMLR, 3:1137–1155, 2003. [14] Y. Nesterov. A method of solving a convex programming problem with convergence rate o(1/sqr(k)). Soviet Mathematics Doklady, 27:372–376, 1983. [15] Tieleman and G. Hinton. RMSProp: Divide the gradient by a running average of its recent magnitude. In Lecture Note 6-5, University of Toronto, 2012. [16] D. Kingma and J. Ba. Adam: A method for stochastic optimization. In ICLR, 2015. [17] Frédéric Bastien, Pascal Lamblin, Razvan Pascanu, James Bergstra, Ian Goodfellow, Arnaud Bergeron, Nicolas Bouchard, David Warde-Farley, and Yoshua Bengio. Theano: new features and speed improvements. In NIPS Workshop on Deep Learning and Unsupervised Feature Learning, 2012. [18] A. Benitez-Paez, K. Portune, and Y. Sanz. Species level resolution of 16S rRNA gene amplicons sequenced through MinION portable nanopore sequencer. bioRxiv:021758, 2015. [19] M. Jain, I. Fiddes, K. Miga, H. Olsen, B. Paten, and M. Akeson. Improved data analysis for the MinION nanopore sequencer. Nature Methods, 12:351–356, 2015. [20] S. Goodwin, J. Gurtowski, S Ethe-Sayers, P. Deshpande, M. Schatz, and W.R. McCombie. Oxford Nanopore sequencing, hybrid error correction, and de novo assembly of a eukaryotic genome. Genome Res., 2015. [21] L. Salmela and J. Schroder. Correcting errors in short reads by multiple alignments. BioInformatics, 27(11):1455–1461, 2011. [22] C. Stein. Estimation of the mean of a multivariate normal distribution. The Annals of Statistics, 9(6):1135–1151, 1981. 9 | 2016 | 554 |
6,499 | Testing for Differences in Gaussian Graphical Models: Applications to Brain Connectivity Eugene Belilovsky 1,2,3, Gael Varoquaux2, Matthew Blaschko3 1University of Paris-Saclay, 2INRIA, 3KU Leuven {eugene.belilovsky, gael.varoquaux } @inria.fr matthew.blaschko@esat.kuleuven.be Abstract Functional brain networks are well described and estimated from data with Gaussian Graphical Models (GGMs), e.g. using sparse inverse covariance estimators. Comparing functional connectivity of subjects in two populations calls for comparing these estimated GGMs. Our goal is to identify differences in GGMs known to have similar structure. We characterize the uncertainty of differences with confidence intervals obtained using a parametric distribution on parameters of a sparse estimator. Sparse penalties enable statistical guarantees and interpretable models even in high-dimensional and low-sample settings. Characterizing the distributions of sparse models is inherently challenging as the penalties produce a biased estimator. Recent work invokes the sparsity assumptions to effectively remove the bias from a sparse estimator such as the lasso. These distributions can be used to give confidence intervals on edges in GGMs, and by extension their differences. However, in the case of comparing GGMs, these estimators do not make use of any assumed joint structure among the GGMs. Inspired by priors from brain functional connectivity we derive the distribution of parameter differences under a joint penalty when parameters are known to be sparse in the difference. This leads us to introduce the debiased multi-task fused lasso, whose distribution can be characterized in an efficient manner. We then show how the debiased lasso and multi-task fused lasso can be used to obtain confidence intervals on edge differences in GGMs. We validate the techniques proposed on a set of synthetic examples as well as neuro-imaging dataset created for the study of autism. 1 Introduction Gaussian graphical models describe well interactions in many real-world systems. For instance, correlations in brain activity reveal brain interactions between distant regions, a process know as functional connectivity. Functional connectivity is an interesting probe on brain mechanisms as it persists in the absence of tasks (the so-called “resting-state”) and is thus applicable to study populations of impaired subjects, as in neurologic or psychiatric diseases [3]. From a formal standpoint, Gaussian graphical models are well suited to estimate brain connections from functional Magnetic Resonance Imaging (fMRI) signals [28, 33]. A set of brain regions and related functional connections is then called a functional connectome [31, 3]. Its variation across subjects can capture cognition [26, 27] or pathology [17, 3]. However, the effects of pathologies are often very small, as resting-state fMRI is a weakly-constrained and noisy imaging modality, and the number of subjects in a study is often small given the cost of imaging. Statistical power is then a major concern [2]. The statistical challenge is to increase the power to detect differences between Gaussian graphical models in the small-sample regime. In these settings, estimation and comparison of Gaussian graphical models fall in the range of high-dimensional statistics: the number of degrees of freedom in the data is small compared to 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. the dimensionality of the model. In this regime, sparsity-promoting ℓ1-based penalties can make estimation well-posed and recover good estimation performance despite the scarcity of data [29, 10, 22, 6, 1]. These encompass sparse regression methods such as the lasso or recovery methods such as basis pursuit, and can be applied to estimation of Gaussian graphical models with approaches such as the graphical lasso[10]. There is now a wide body of literature which demonstrates the statistical properties of these methods [1]. Crucial to applications in medicine or neuroscience, recent work characterizes the uncertainty, with confidence intervals and p-values, of the parameters selected by these methods [15, 16, 19, 12]. These works focus primarily on the lasso and graphical lasso. Approaches to estimate statistical significance on sparse models fall into several general categories: (a) non-parameteric sampling based methods which are inherently expensive and have difficult limiting distributions [1, 24, 5], (b) characterizations of the distribution of new parameters that enter a model along a regularization path [19, 12], or (c) for a particular regularization parameter, debiasing the solution to obtain a new consistent estimator with known distribution [16, 15, 30]. While some of the latter work has been used to characterize confidence intervals on network edge selection, there is no result, to our knowledge, on the important problem of identifying differences in networks. Here the confidence on the result is even more critical, as the differences are the direct outcome used for neuroscience research or medical practice, and it is important to provide the practitioner a measure of the uncertainty. Here, we consider the setting of two datasets known to have very similar underlying signals, but which individually may not be very sparse. A motivating example is determining the difference in brain networks of subjects from different groups: population analysis of connectomes [31, 17]. Recent literature in neuroscience [20] has suggested functional networks are not sparse. On the other hand, differences in connections across subjects should be sparse. Indeed the link between functional and anatomical brain networks [13] suggests they should not differ drastically from one subject to another. From a neuroscientific standpoint we are interested in determining which edges between two populations (e.g. autistic and non-autistic) are different. Furthermore we want to provide confidence-intervals on our results. We particularly focus on the setting where one dataset is larger than the other. In many applications it is more difficult to collect one group (e.g. individuals with specific pathologies) than another. We introduce an estimator tailored to this goal: the debiased multi-task fused lasso. We show that, when the underlying parameter differences are indeed sparse, we can obtain a tractable Gaussian distribution for the parameter difference. This closed-form distribution underpins accurate hypothesis testing and confidence intervals. We then use the relationship between nodewise regression and the inverse covariance matrix to apply our estimator to learning differences of Gaussian graphical models. The paper is organized as follows. In Section 2 we review previous work on learning of GGMs and the debiased lasso. Section 3 discusses a joint debiasing procedure that specifically debiases the difference estimator. In Section 3.1 we introduce the debiased multi-task fused lasso and show how it can be used to learn parameter differences in linear models. In Section 3.2, we show how these results can be used for GGMs. In Section 4 we validate our approach on synthetic and fMRI data. 2 Background and Related Work Debiased Lasso A central starting point for our work is the debiased lasso [30, 16]. Here one considers the linear regression model, Y = Xβ + ϵ, with data matrix X and output Y , corrupted by ϵ ∼N(0, σ2 ϵ I) noise. The lasso estimator is formulated as follows: ˆβλ = arg min β 1 n∥Y −Xβ∥2 + λ∥β∥1 (1) The KKT conditions give ˆkλ = 1 nXT (Y −Xβ), where ˆk is the subgradient of λ∥β∥1. The debiased lasso estimator [30, 16] is then formulated as ˆβλ u = ˆβλ+Mˆkλ for some M that is constructed to give guarantees on the asymptotic distribution of ˆβλ u. Note that this estimator is not strictly unbiased in the finite sample case, but has a bias that rapidly approaches zero (w.r.t. n) if M is chosen appropriately, the true regressor β is indeed sparse, and the design matrix satistifes a certain restricted eigenvalue property [30, 16]. We decompose the difference of this debiased estimator and the truth as follows: ˆβλ u −β = 1 nMXT ϵ −(M ˆΣ −I)(ˆβ −β) (2) 2 The first term is Gaussian and the second term is responsible for the bias. Using Holder’s inequality the second term can be bounded by ∥M ˆΣ−I∥∞∥ˆβ−β∥1. The first part of which we can bound using an appropriate selection of M while the second part is bounded by our implicit sparsity assumptions coming from lasso theory [1]. Two approaches from the recent literature discuss how one can select M to appropriately debias this estimate. In [30] it suffices to use nodewise regression to learn an inverse covariance matrix which guarantees constraints on ∥M ˆΣ −I∥∞. A second approach by [16] proposes to solve a quadratic program to directly minimize the variance of the debiased estimator while constraining ∥M ˆΣ −I∥∞to induce sufficiently small bias. Intuitively the construction of ˆβλ u allows us to trade variance and bias via the M matrix. This allows us to overcome a naive bias-variance tradeoff by leveraging the sparsity assumptions that bound ∥ˆβ −β∥1. In the sequel we expand this idea to the case of debiased parameter difference estimates and sparsity assumptions on the parameter differences. In the context of GGMs, the debiased lasso can gives us an estimator that asymptotically converges to the partial correlations. As highlighted by [34] we can thus use the debiased lasso to obtain difference estimators with known distributions. This allows us to obtain confidence intervals on edge differences between Gaussian graphical models. We discuss this further in the sequel. Gaussian Graphical Model Structure Learning A standard approach to estimating Gaussian graphical models in high dimensions is to assume sparsity of the precision matrix and have a constraint which limits the number of non-zero entries of the precision matrix. This constraint can be achieved with a ℓ1-norm regularizer as in the popular graphical lasso [10]. Many variants of this approach that incorporate further structural assumptions have been proposed [14, 6, 23]. An alternative solution to inducing sparsity on the precision matrix indirectly is neighborhood ℓ1 regression from [22]. Here the authors make use of a long known property that connects the entries of the precision matrix to the problem of regression of one variable on all the others [21]. This property is critical to our proposed estimation as it allows relating regression models to finding edges connected to specific nodes in the GGM. GGMs have been found to be good at recovering the main brain networks from fMRI data [28, 33]. Yet, recent work in neuroscience has showed that the structural wiring of the brain did not correspond to a very sparse network [20], thus questioning the underlying assumption of sparsity often used to estimate brain network connectivity. On the other hand, for the problem of finding differences between networks in two populations, sparsity may be a valid assumption. It is well known that anatomical brain connections tend to closely follow functional ones [13]. Since anatomical networks do not differ drastically we can surmise that two brain networks should not differ much even in the presence of pathologies. The statistical method we present here leverages sparsity in the difference of two networks, to yield well-behaved estimation and hypothesis testing in the low-sample regime. Most closely related to our work, [35, 9] recently consider a different approach to estimating difference networks, but does not consider assigning significance to the detection of edges. 3 Debiased Difference Estimation In many applications one may be interested in learning multiple linear models from data that share many parameters. Situations such as this arise often in neuroimaging and bioinformatics applications. We can often improve the learning procedure of such models by incorporating fused penalties that penalize the ∥·∥1 norm of the parameter differences or ∥·∥1,2 which encourages groups of parameters to shrink together. These methods have been shown to substantially improve the learning of the joint models. However, the differences between model parameters, which can have a high sample complexity when there are few of them, are often pointed out only in passing [4, 6, 14]. On the other hand, in many situations we might be interested in actually understanding and identifying the differences between elements of the support. For example when considering brain networks of patients suffering from a pathology and healthy control subjects, the difference in brain connectivity may be of great interest. Here we focus specifically on accurately identifying differences with significance. We consider the case of two tasks (e.g. two groups of subjects), but the analysis can be easily extended to general multi-task settings. Consider the problem setting of data matrices X1 and X2, which are n1 × p and n2 × p, respectively. We model them as producing outputs Y1 and Y2, corrupted by 3 diagonal gaussian noise ϵ1 and ϵ2 as follows Y1 = X1β1 + ϵ1, Y2 = X2β2 + ϵ2 (3) Let S1 and S2 index the elements of the support of β1 and β2, respectively. Furthermore the support of β1 −β2 is indexed by Sd and finally the union of S1 and S2 is denoted Sa. Using a squared loss estimator producing independent estimates ˆβ1, ˆβ2 we can obtain a difference estimate ˆβd = ˆβ1 −ˆβ2. In general if Sd is very small relative to Sa then we will have a difficult time to identify the support Sd. This can be seen if we consider each of the individual components of the prediction errors. The larger the true support Sa the more it will drown out the subset which corresponds to the difference support. This can be true even if one uses ℓ1 regularizers over the parameter vectors. Consequently, one cannot rely on the straightforward strategy of learning two independent estimates and taking their difference. The problem is particularly pronounced in the common setting where one group has fewer samples than the other. Thus here we consider the setting where n1 > n2 and possibly n1 ≫n2. Let ˆβ1 and ˆβ2 be regularized least squares estimates. In our problem setting we wish to obtain confidence intervals on debiased versions of the difference ˆβd = ˆβ1 −ˆβ2 in a high-dimensional setting (in the sense that n2 < p), we aim to leverage assumptions about the form of the true βd, primarily that it is sparse, while the independent ˆβ1 and ˆβ2 are weakly sparse or not sparse. We consider a general case of a joint regularized least squares estimation of ˆβ1 and ˆβ2 min β1,β2 1 n1 ∥Y1 −X1β1∥2 + 1 n2 ∥Y2 −X2β2∥2 + R(β1, β2) (4) We note that the differentiating and using the KKT conditions gives ˆkλ = ˆk1 ˆk2 = 1 n1 XT 1 (Y −X1β1) 1 n2 XT 2 (Y −X2β2) (5) where ˆkλ is the (sub)gradient of R(β1, β2). Substituting Equation (3) we can now write ˆΣ1(ˆβ1 −β1) + ˆk1 = 1 n1 XT 1 ϵ1 and ˆΣ2(ˆβ2 −β2) + ˆk2 = 1 n2 XT 2 ϵ2 (6) We would like to solve for the difference ˆβ1 −ˆβ2 but the covariance matrices may not be invertible. We introduce matrices M1 and M2, which will allow us to isolate the relevant term. We will see that in addition these matrices will allow us to decouple the bias and variance of the estimators. M1 ˆΣ1(ˆβ1 −β1) + M1ˆk1 = 1 n1 M1XT 1 ϵ1 and M2 ˆΣ2(ˆβ2 −β2) + M2ˆk2 = 1 n2 M2XT 2 ϵ2 (7) subtracting these and rearranging we can now isolate the difference estimator plus a term we add back controlled by M1 and M2 (ˆβ1 −ˆβ2) −(β1 −β2) + M1ˆk1 −M2ˆk2 = 1 n1 M1XT 1 ϵ1 −1 n2 M2XT 2 ϵ2 −∆ (8) ∆= (M1 ˆΣ1 −I)(ˆβ1 −β1) −(M2 ˆΣ2 −I)(ˆβ2 −β2) (9) Denoting βd := β1 −β2 and βa := β1 + β2, we can reformulate ∆: ∆= (M1 ˆΣ1 −I + M2 ˆΣ2 −I) 2 (ˆβd −βd) + (M1 ˆΣ1 −M2 ˆΣ2) 2 (ˆβa −βa) (10) Here, ∆will control the bias of our estimator. Additionally, we want to minimize its variance, 1 n1 M1 ˆΣ1M1ˆσ2 1 + 1 n2 M2 ˆΣ2M2ˆσ2 2. (11) We can now overcome the limitations of simple bias variance trade-off by using an appropriate regularizer coupled with an assumption on the underlying signal β1 and β2. This will in turn make ∆ asymptotically vanish while maximizing the variance. Since we are interested in pointwise estimates, we can focus on bounding the infinity norm of ∆. ∥∆∥∞≤1 2 ∥M1 ˆΣ1 + M2 ˆΣ2 −2I∥∞ | {z } µ1 ∥ˆβd −βd∥1 | {z } ld +1 2 ∥M1 ˆΣ1 −M2 ˆΣ2∥∞ | {z } µ2 ∥ˆβa −βa∥1 | {z } la (12) 4 We can control the maximum bias by selecting M1 and M2 appropriately. If we use an appropriate regularizer coupled with sparsity assumptions we can bound the terms la and ld and use this knowledge to appropriately select M1 and M2 such that the bias becomes neglibile. If we had only the independent parameter sparsity assumption we can apply the results of the debiased lasso and estimate M1 and M2 independently as in [16]. In the case of interest where β1 and β2 share many weights we can do better by taking this as an assumption and applying a sparsity regularization on the difference by adding the term λ2∥β1 −β2∥1. Comparing the decoupled penalty to the fused penalty proposed we see that ld would decrease at a given sample size. We now show how to jointly estimate M1 and M2 so that ∥∆∥∞becomes negligible for a given n, p and sparsity assumption. 3.1 Debiasing the Multi-Task Fused Lasso Motivated by the inductive hypothesis from neuroscience described above we introduce a consistent low-variance estimator, the debiased multi-task fused lasso. We propose to use the following regularizer R(β1, β2) = λ1∥β1∥1 + λ1∥β2∥1 + λ2∥β1 −β2∥1. This penalty has been referred to in some literature as the multi-task fused lasso [4]. We propose to then debias this estimate as shown in (8). We estimate the M1 and M2 matrices by solving the following QP for each row m1 and m2 of the matrices M1 and M2. min m1,m2 1 n1 mT 1 ˆΣ1m1 + 1 n2 mT 2 ˆΣ2m2 (13) s.t. ∥M1 ˆΣ1 + M2 ˆΣ2 −2I∥∞≤µ1, ∥M1 ˆΣ1 −M2 ˆΣ2∥∞≤µ2 This directly minimizes the variance, while bounding the bias in the constraint. We now show how to set the bounds: Proposition 1. Take λ1 > 2 q log p n2 and λ2 = O(λ1). Denote sd the difference sparsity, s1,2 the parameter sparsity |S1| + |S2|, c > 1,a > 1, and 0 < m ≪1. When the compatibility condition [1, 11] holds the following bounds gives lau2 = o(1) and ldu1 = o(1) and thus ∥∆∥∞= o(1) with high probability. µ1 ≤ 1 cλ2sdnm 2 and µ2 ≤ 1 a(λ1s1,2 + λ2sd)nm 2 (14) The proof is given in the supplementary material. Using the prescribed Ms obtained with (13) and 14 we obtain an unbiased estimator given by (8) with variance (11) 3.2 GGM Difference Structure Discovery with Significance The debiased lasso and the debiased multi-task fused lasso, proposed in the previous section, can be used to learn the structure of a difference of Gaussian graphical models and to provide significance results on the presence of edges within the difference graph. We refer to these two procedures as Difference of Neighborhoods Debiased Lasso Selection and Difference of Neighborhoods Debiased Fused Lasso Selection. We recall that the conditional independence properties of a GGM are given by the zeros of the precision matrix and these zeros correspond to the zeros of regression parameters when regressing one variable on all the other. By obtaining a debiased lasso estimate for each node in the graph [34] notes this leads to a sparse unbiased precision matrix estimate with a known asymptotic distribution. Subtracting these estimates for two different datasets gives us a difference estimate whose zeros correspond to no difference of graph edges in two GGMs. We can similarly use the debiased multitask fused lasso described above and the joint debiasing procedure to obtain a test statistic for the difference of networks. We now formalize this procedure. Notation Given GGMs j = 1, 2. Let Xj denote the random variable in Rp associated with GGM j. We denote Xj,v the random variable associated with a node, v of the GGM and Xj,vc all other nodes in the graph. We denote ˆβj,v the lasso or multi-task fused lasso estimate of Xj,vc onto Xj,v, then ˆβj,dL,v is the debiased version of ˆβj,v. Finally let βj,v denote the unknown regression, Xj,v = Xj,vcβj,v + ϵj where ϵj ∼N(0, σjI). Define βi D,v = ˆβi 1,dL,v −ˆβi 2,dL,v the test statistic associated with the edge v, i in the difference of GGMs j = 1, 2. 5 Algorithm 1 Difference Network Selection with Neighborhood Debiased Lasso V = {1, ..., P} NxP Data Matrices, X1 and X2 Px(P-1) Output Matrix B of test statistics for v ∈V do Estimate unbiased ˆσ1, ˆσ2 from X1,v, X2,v for j ∈{1, 2} do βj ←SolveLasso(Xj,vc, Xj,v) Mj ←MEstimator(Xj,vc) βj,U ←βj+MjXT j,vc(Xj,v −Xj,vcβj) end for σ2 d ←diag( ˆσ2 1 n1 M T 1 ˆΣ1M1 + ˆσ2 2 n2 M T 2 ˆΣ2M2) for j ∈vc do Bv,j = (β1,U,j −β2,U,j)/ q σ2 d,j end for end for Algorithm 2 Difference Network Selection with Neighborhood Debiased Fused Lasso V = {1, ..., P} NxP Data Matrices, X1 and X2 Px(P-1) Output Matrix B of test statistics for v ∈V do Estimate unbiased ˆσ1, ˆσ2 from X1,v, X2,v β1,β2 ←FusedLasso(X1,vc, X1,v, X2,vc, X2,v) M1, M2 ←MEstimator(X1,vc, X2,vc) for j ∈{1, 2} do βj,U ←βj+MjXT j,vc(Xj,v −Xj,vcβj) end for σ2 d ←diag( ˆσ2 1 n1 M T 1 ˆΣ1M1 + ˆσ2 2 n2 M T 2 ˆΣ2M2) for j ∈vc do Bv,j = (β1,U,j −β2,U,j)/ q σ2 d,j end for end for Proposition 2. Given the ˆβi D,v, M1 and M2 computed as in [16] for the debiased lasso or as in Section 3.1 for the debiased multi-task fused lasso. When the respective assumptions of these estimators are satisfied the following holds w.h.p. ˆβi D,v −βi D,v = W + o(1) where W ∼N(0, [σ2 1M1 ˆΣ1M T 1 + σ2 2M2 ˆ Σ2M T 2 ]i,i) (15) This follows directly from the asymptotic consistency of each individual ˆβi j,dL,v for the debiased lasso and multi-task fused lasso. We can now define the the null hypothesis of interest as H0 : Θ1,(i,j) = Θ2,(i,j). Obtaining a test statistic for each element βi D,v allows us to perform hypothesis testing on individual edges, all the edges, or groups of edges (controlling for the FWER). We summarize the Neighbourhood Debiased Lasso Selection process in Algorithm 1 and the Neighbourhood Debiased Multi-Task Fused Lasso Selection in Algorithm 2 which can be used to obtain a matrix of all the relevant test statistics. 4 Experiments 4.1 Simulations We generate synthetic data based on two Gaussian graphical models with 75 vertices. Each of the individual graphs have a sparsity of 19% and their difference sparsity is 3%. We construct the models by taking two identical precision matrices and randomly removing some edges from both. We generate synthetic data using both precision matrices. We use n1 = 800 samples for the first dataset and vary the second dataset n2 = 20, 30, ...150. We perform a regression using the debiased lasso and the debiased multi-task fused lasso on each node of the graphs. As an extra baseline we consider the projected ridge method from the R package “hdi” [7]. We use the debiased lasso of [16] where we set λ = kˆσ p log p/n. We select c by 3fold cross validation k = {0.1, ..100} and M as prescribed in [16] which we obtain by solving a quadratic program. ˆσ is an unbiased estimator of the noise variance. For the debiased lasso we let both λ1 = k1 ˆσ2 p log p/n2 and λ2 = k2 ˆσ2 p log p/n2, and select based on 3-fold cross-validation from the same range as k. M1 and M2 are obtained as in Equation (13) with the bounds (14) being set with c = a = 2, sd = 2, s1,2 = 15, m = 0.01, and the cross validated λ1 and λ2. In both debiased lasso and fused multi-task lasso cases we utilize the Mosek QP solver package to obtain M. For the projected ridge method we use the hdi package to obtain two estimates of β1 and β2 along with their upper bounded biases which are then used to obtain p-values for the difference. We report the false positive rate, the power, the coverage and interval length as per [30] for the difference of graphs. In these experiments we aggregate statistics to demonstrate power of the test statistic, as such we consider each edge as a separate test and do not perform corrections. Table 1 gives the numerical results for n2 = 60: the power and coverage is substantially better for the debiased fused multi-task lasso, while at the same time the confidence interval smaller. 6 30 40 50 60 70 80 90 100 110 120 130 140 150 n2 0.0 0.2 0.4 0.6 0.8 1.0 Power Power ridge lasso fusedlasso Figure 1: Power of the test for different number of samples in the second simulation, with n1 = 800. The debiased fused lasso has highest statistical power. Method FP TP(Power) Cov S Cov Sc d len S len Sc d Deb. Lasso 3.7% 80.6% 96.2% 92% 2.199 2.195 Deb. Fused Lasso 0.0% 93.3% 100% 98.6% 2.191 2.041 Ridge Projection 0.0% 18.6% 100% 100% 5.544 5.544 Table 1: Comparison of Debiased Lasso, Debiased Fused Lasso, and Projected Ridge Regression for edge selection in difference of GGM. The significance level is 5%, n1 = 800 and n2 = 60. All methods have false positive below the significance level and the debiased fused lasso dominates in terms of power. The coverage of the difference support and non-difference support is also best for the debiased fused lasso, which simultaneously has smaller confidence intervals on average. Figure 1 shows the power of the test for different values of n2. The fusedlasso outperforms the other methods substantially. Projected ridge regression is particularly weak, in this scenario, as it uses a worst case p-value obtained using an estimate of an upper bound on the bias [7]. 4.2 Autism Dataset Correlations in brain activity measured via fMRI reveal functional interactions between remote brain regions [18]. In population analysis, they are used to measure how connectivity varies between different groups. Such analysis of brain function is particularly important in psychiatric diseases, that have no known anatomical support: the brain functions in a pathological aspect, but nothing abnormal is clearly visible in the brain tissues. Autism spectrum disorder is a typical example of such ill-understood psychiatric disease. Resting-state fMRI is accumulated in an effort to shed light on this diseases mechanisms: comparing the connectivity of autism patients versus control subjects. The ABIDE (Autism Brain Imaging Data Exchange) dataset [8] gathers rest-fMRI from 1 112 subjects across, with 539 individuals suffering from autism spectrum disorder and 573 typical controls. We use the preprocessed and curated data1. In a connectome analysis [31, 26], each subject is described by a GGM measuring functional connectivity between a set of regions. We build a connectome from brain regions of interest based on a multi-subject atlas2 of 39 functional regions derived from resting-state fMRI [32] (see. Fig. 4). We are interested in determining edge differences between the autism group and the control group. We use this data to show how our parametric hypothesis test can be used to determine differences in brain networks. Since no ground truth exists for this problem, we use permutation testing to evaluate the statistical procedures [25, 5]. Here we permute the two conditions (e.g. autism and control group) to compute a p-value and compare it to our test statistics. This provides us with a finite sample strict control on the error rate: a non-parametric validation of our parametric test. For our experiments we take 2000 randomly chosen volumes from the control group subjects and 100 volumes from the autism group subjects. We perform permutation testing using the de-biased lasso, de-biased multi-task fused lasso, and projected ridge regression. Parameters for the de-biased fused lasso are chosen as in the previous section. For the de-biased lasso we use the exact settings for λ and constraints on M provided in the experimental section of [16]. Projected ridge regression is evaluated as in the previous section. Figure 2 shows a comparison of three parametric approaches versus their analogue obtained with a permutation test. The chart plots the permutation p-values of each entry in the 38 × 39 B matrix against the expected parametric p-value. For all the methods the points are above the line indicating the tests are not breaching the expected false positive rates. However the de-biased lasso and ridge projecting are very conservative and lead to few detections. The de-biased multi-task fused lasso yields far more detections on the same dataset, within the expected false positive rate or near it. We now analyse the reproducibility of the results by repeatedly sampling 100 subsets of the data (with the same proportions n1 = 2000 and n2 = 100), obtaining the matrix of test statistics, selecting edges that fall below the 5% significance level. Figure 3 shows how often edges are selected multiple times across subsamples. We report results with a threshold on uncorrected p-values as the lasso procedure 1http://preprocessed-connectomes-project.github.io/abide/ 2https://team.inria.fr/parietal/research/spatial_patterns/ spatial-patterns-in-resting-state/ 7 0.0 0.2 0.4 0.6 0.8 1.0 permutation p-values 0.0 0.2 0.4 0.6 0.8 1.0 parametric p-values fusedlasso 0.00 0.05 0.10 0.15 0.20 permutation p-values 0.00 0.02 0.04 0.06 0.08 0.10 parametric p-values fusedlasso pvalues at tail 0.0 0.2 0.4 0.6 0.8 1.0 permutation p-values 0.0 0.2 0.4 0.6 0.8 1.0 parametric p-values lasso 0.00 0.05 0.10 0.15 0.20 permutation p-values 0.00 0.02 0.04 0.06 0.08 0.10 parametric p-values lasso pvalues at tail 0.0 0.2 0.4 0.6 0.8 1.0 permutation p-values 0.0 0.2 0.4 0.6 0.8 1.0 parametric p-values ridge 0.00 0.05 0.10 0.15 0.20 permutation p-values 0.00 0.02 0.04 0.06 0.08 0.10 parametric p-values ridge pvalues at tail Figure 2: Permutation testing comparing debiased fused lasso, debiased lasso, and projected ridge regression on the ABIDE dataset. The chart plots the permutation p-values of each method on each possible edge against the expected parametric p-value. The debiased lasso and ridge projection are very conservative and lead to few detections. The fused lasso yields far more detections on the same dataset, almost all within the expected false positive rate. 1 2 3 4 5 6 7 8 9 Number of occurences (t) 0.0 0.2 0.4 0.6 0.8 1.0 Fraction of connections occuring at least t times Reproducibility across subsamples lasso fusedlasso Figure 3: Reproducibility of results from sub-sampling using uncorrected error rate. The fused lasso is much more likely to detect edges and produce stable results. Using corrected p-values no detections are made by lasso (figure in supplementary material). x=2 L R z=20 Figure 4: Outlines of the regions of the MSDL atlas. Figure 5: Connectome of repeatedly picked up edges in 100 trials. We only show edges selected more than once. Darker red indicates more frequent selection. selects no edges with multiple comparison correction (supplementary materials give FDR-corrected results for the de-biased fused multi-task lasso selection). Figure 5 shows a connectome of the edges frequently selected by the de-biased fused multi-task lasso (with FDR correction). 5 Conclusions We have shown how to characterize the distribution of differences of sparse estimators and how to use this distribution for confidence intervals and p-values on GGM network differences. For this purpose, we have introduced the de-biased multi-task fused lasso. We have demonstrated on synthetic and real data that this approach can provide accurate p-values and a sizable increase of statistical power compared to standard procedures. The settings match those of population analysis for functional brain connectivity, and the gain in statistical power is direly needed to tackle the low sample sizes [2]. Future work calls for expanding the analysis to cases with more than two groups as well as considering a ℓ1,2 penalty sometimes used at the group level [33]. Additionally the squared loss objective optimizes excessively the prediction and could be modified to lower further the sample complexity in terms of parameter estimation. 8 Acknowledgements This work is partially funded by Internal Funds KU Leuven, ERC Grant 259112, FP7-MC-CIG 334380, and DIGITEO 2013-0788D - SOPRANO, and ANR-11-BINF-0004 NiConnect. References [1] P. Bühlmann and S. van de Geer. Statistics for High-Dimensional Data. Springer, 2011. [2] K. Button et al. Power failure: Why small sample size undermines the reliability of neuroscience. Nature Reviews Neuroscience, 14:365, 2013. [3] F. X. Castellanos et al. Clinical applications of the functional connectome. Neuroimage, 80:527, 2013. [4] X. Chen et al. Smoothing proximal gradient method for general structured sparse learning. In UAI, 2011. [5] B. Da Mota et al. Randomized parcellation based inference. NeuroImage, 89:203–215, 2014. [6] P. Danaher, P. Wang, and D. Witten. The joint graphical lasso for inverse covariance estimation across multiple classes. Journal of the Royal Statistical Society (B), 76(2):373–397, 2014. [7] R. Dezeure, P. Bühlmann, L. Meier, and N. Meinshausen. High-dimensional inference: Confidence intervals, p-values and R-software hdi. Statist. Sci., 30(4):533–558, 11 2015. [8] A. Di Martino et al. The autism brain imaging data exchange: Towards a large-scale evaluation of the intrinsic brain architecture in autism. Mol. Psychiatry, 19:659, 2014. [9] F. Fazayeli and A. Banerjee. Generalized direct change estimation in ising model structure. In ICML, 2016. [10] J. Friedman, T. Hastie, and R. Tibshirani. Sparse inverse covariance estimation with the graphical lasso. Biostatistics, 9(3):432–441, 2008. [11] A. Ganguly and W. Polonik. Local neighborhood fusion in locally constant Gaussian graphical models. arXiv:1410.8766, 2014. [12] M. G. G’Sell, J. Taylor, and R. Tibshirani. Adaptive testing for the graphical lasso. arXiv:1307.4765, 2013. [13] C. Honey, O. Sporns, L. Cammoun, X. Gigandet, et al. Predicting human resting-state functional connectivity from structural connectivity. Proc. Nat. Acad. Sciences, 106:2035, 2009. [14] J. Honorio and D. Samaras. Multi-task learning of Gaussian graphical models. In ICML, 2010. [15] J. Janková and S. van de Geer. Confidence intervals for high-dimensional inverse covariance estimation. Electron. J. Statist., 9(1):1205–1229, 2015. [16] A. Javanmard and A. Montanari. Confidence intervals and hypothesis testing for high-dimensional regression. The Journal of Machine Learning Research, 15(1):2869–2909, 2014. [17] C. Kelly, B. B. Biswal, R. C. Craddock, F. X. Castellanos, and M. P. Milham. Characterizing variation in the functional connectome: Promise and pitfalls. Trends in Cog. Sci., 16:181, 2012. [18] M. A. Lindquist et al. The statistical analysis of fMRI data. Stat. Sci., 23(4):439–464, 2008. [19] R. Lockhart et al. A significance test for the lasso. Ann. Stat., 42:413, 2014. [20] N. T. Markov, M. Ercsey-Ravasz, D. C. Van Essen, K. Knoblauch, Z. Toroczkai, and H. Kennedy. Cortical high-density counterstream architectures. Science, 342(6158):1238406, 2013. [21] G. Marsaglia. Conditional means and covariances of normal variables with singular covariance matrix. Journal of the American Statistical Association, 59(308):1203–1204, 1964. [22] N. Meinshausen and P. Bühlmann. High-dimensional graphs and variable selection with the lasso. Ann. Stat., pages 1436–1462, 2006. [23] K. Mohan et al. Structured learning of Gaussian graphical models. In NIPS, pages 620–628, 2012. [24] M. Narayan and G. I. Allen. Mixed effects models to find differences in multi-subject functional connectivity. bioRxiv:027516, 2015. [25] T. E. Nichols and A. P. Holmes. Nonparametric permutation tests for functional neuroimaging: A primer with examples. Human Brain Mapping, 15(1):1–25, 2002. [26] J. Richiardi, H. Eryilmaz, S. Schwartz, P. Vuilleumier, and D. Van De Ville. Decoding brain states from fMRI connectivity graphs. NeuroImage, 56:616–626, 2011. [27] W. R. Shirer, S. Ryali, E. Rykhlevskaia, V. Menon, and M. D. Greicius. Decoding subject-driven cognitive states with whole-brain connectivity patterns. Cerebral Cortex, 22(1):158–165, 2012. [28] S. M. Smith et al. Network modelling methods for fMRI. NeuroImage, 54:875, 2011. [29] R. Tibshirani. Regression shrinkage and selection via the lasso. Journal of the Royal Statistical Society. Series B, pages 267–288, 1996. [30] S. Van de Geer, P. Bühlmann, Y. Ritov, and R. Dezeure. On asymptotically optimal confidence regions and tests for high-dimensional models. Ann. Stat., 42(3):1166–1202, 2014. [31] G. Varoquaux and R. C. Craddock. Learning and comparing functional connectomes across subjects. NeuroImage, 80:405–415, 2013. [32] G. Varoquaux, A. Gramfort, F. Pedregosa, V. Michel, and B. Thirion. Multi-subject dictionary learning to segment an atlas of brain spontaneous activity. In IPMI, 2011. [33] G. Varoquaux, A. Gramfort, J.-B. Poline, and B. Thirion. Brain covariance selection: Better individual functional connectivity models using population prior. In NIPS, 2010. [34] L. Waldorp. Testing for graph differences using the desparsified lasso in high-dimensional data. Statistics Survey, 2014. [35] S. D. Zhao et al. Direct estimation of differential networks. Biometrika, 101(2):253–268, 2014. 9 | 2016 | 555 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.