Class/Object

breeze.optimize.proximal

QuadraticMinimizer

Related Docs: object QuadraticMinimizer | package proximal

Permalink

class QuadraticMinimizer extends SerializableLogging

Proximal operators and ADMM based Primal-Dual QP Solver

Reference: http://www.stanford.edu/~boyd/papers/admm/quadprog/quadprog.html

It solves problem that has the following structure

1/2 x'Hx + f'x + g(x) s.t Aeqx = b

g(x) represents the following constraints which covers ALS based matrix factorization use-cases

1. x >= 0 2. lb <= x <= ub 3. L1(x) 4. L2(x) 5. Generic regularization on x

Linear Supertypes
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. QuadraticMinimizer
  2. SerializableLogging
  3. Serializable
  4. Serializable
  5. AnyRef
  6. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Instance Constructors

  1. new QuadraticMinimizer(nGram: Int, proximal: Proximal = null, Aeq: DenseMatrix[Double] = null, beq: DenseVector[Double] = null, maxIters: Int = 1, abstol: Double = 1e-6, reltol: Double = 1e-4, alpha: Double = 1.0)

    Permalink

    nGram

    rank of dense gram matrix

    proximal

    proximal operator to be used

    Aeq

    rhs matrix for equality constraints

    beq

    lhs constants for equality constraints

    abstol

    ADMM absolute tolerance

    reltol

    ADMM relative tolerance

    alpha

    over-relaxation parameter default 1.0 1.5 - 1.8 can improve convergence

Type Members

  1. type BDM = DenseMatrix[Double]

    Permalink
  2. type BDV = DenseVector[Double]

    Permalink
  3. case class State extends Product with Serializable

    Permalink

Value Members

  1. final def !=(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  4. val admmIters: Int

    Permalink
  5. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  6. def clone(): AnyRef

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  7. final def eq(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  8. def equals(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  9. def finalize(): Unit

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  10. val full: Int

    Permalink
  11. final def getClass(): Class[_]

    Permalink
    Definition Classes
    AnyRef → Any
  12. def getProximal: Proximal

    Permalink
  13. def hashCode(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  14. def initialize: State

    Permalink

    Public API to get an initialState for solver hot start such that subsequent calls can reuse state memmory

    Public API to get an initialState for solver hot start such that subsequent calls can reuse state memmory

    returns

    the state for the optimizer

  15. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  16. val linearEquality: Int

    Permalink
  17. def logger: LazyLogger

    Permalink
    Attributes
    protected
    Definition Classes
    SerializableLogging
  18. def minimize(q: DenseVector[Double]): DenseVector[Double]

    Permalink
  19. def minimize(H: DenseMatrix[Double], q: DenseVector[Double]): DenseVector[Double]

    Permalink
  20. def minimize(upper: Array[Double], q: DenseVector[Double], initialState: State): DenseVector[Double]

    Permalink

    minimize API for cases where upper triangular gram matrix is provided by user as primitive array.

    minimize API for cases where upper triangular gram matrix is provided by user as primitive array. If a initialState is not provided by default it constructs it through initialize

    upper

    upper triangular gram matrix of size rank x (rank + 1)/2

    q

    linear term for quadratic optimization

    initialState

    provide an optional initialState for memory optimization

    returns

    converged solution

  21. def minimize(H: DenseMatrix[Double], q: DenseVector[Double], initialState: State): DenseVector[Double]

    Permalink

    minimize API for cases where gram matrix is provided by the user.

    minimize API for cases where gram matrix is provided by the user. If a initialState is not provided by default it constructs it through initialize

    H

    symmetric gram matrix of size rank x rank

    q

    linear term for quadratic optimization

    initialState

    provide an optional initialState for memory optimization

    returns

    converged solution

  22. def minimize(q: DenseVector[Double], initialState: State): DenseVector[Double]

    Permalink

    minimize API for cases where gram matrix is updated through updateGram API.

    minimize API for cases where gram matrix is updated through updateGram API. If a initialState is not provided by default it constructs it through initialize

    q

    linear term for quadratic optimization

    initialState

    provide an optional initialState for memory optimization

    returns

    converged solution

  23. def minimizeAndReturnState(q: DenseVector[Double]): State

    Permalink
  24. def minimizeAndReturnState(H: DenseMatrix[Double], q: DenseVector[Double]): State

    Permalink
  25. def minimizeAndReturnState(upper: Array[Double], q: DenseVector[Double], initialState: State): State

    Permalink

    minimizeAndReturnState API that takes upper triangular entries of the gram matrix specified through primitive array for performance reason and the linear term for quadratic minimization

    minimizeAndReturnState API that takes upper triangular entries of the gram matrix specified through primitive array for performance reason and the linear term for quadratic minimization

    upper

    upper triangular gram matrix specified as primitive array

    q

    linear term

    initialState

    provide a initialState using initialState API for memory optimization

    returns

    converged state from QuadraticMinimizer

  26. def minimizeAndReturnState(H: DenseMatrix[Double], q: DenseVector[Double], initialState: State): State

    Permalink

    minimizeAndReturnState API that takes a symmetric full gram matrix and the linear term for quadratic minimization

    minimizeAndReturnState API that takes a symmetric full gram matrix and the linear term for quadratic minimization

    H

    gram matrix, symmetric of size rank x rank

    q

    linear term

    initialState

    provide a initialState using initialState API for memory optimization

    returns

    converged state from QuadraticMinimizer

  27. def minimizeAndReturnState(q: DenseVector[Double], initialState: State): State

    Permalink

    minimizeAndReturnState API gives an advanced control for users who would like to use QuadraticMinimizer in 2 steps, update the gram matrix first using updateGram API and followed by doing the solve by providing a user defined initialState.

    minimizeAndReturnState API gives an advanced control for users who would like to use QuadraticMinimizer in 2 steps, update the gram matrix first using updateGram API and followed by doing the solve by providing a user defined initialState. rho is automatically calculated by QuadraticMinimizer from problem structure

    q

    linear term for the quadratic optimization

    initialState

    provide a initialState using initialState API

    returns

    converged state from QuadraticMinimizer

  28. def minimizeAndReturnState(q: DenseVector[Double], rho: Double, initialState: State, resetState: Boolean = true): State

    Permalink

    minimizeAndReturnState API gives an advanced control for users who would like to use QuadraticMinimizer in 2 steps, update the gram matrix first using updateGram API and followed by doing the solve by providing a user defined initialState.

    minimizeAndReturnState API gives an advanced control for users who would like to use QuadraticMinimizer in 2 steps, update the gram matrix first using updateGram API and followed by doing the solve by providing a user defined initialState. It also exposes rho control to users who would like to experiment with rho parameters of the admm algorithm. Use user-defined rho only if you understand the proximal algorithm well

    q

    linear term for the quadratic optimization

    rho

    rho parameter for ADMM algorithm

    initialState

    provide a initialState using initialState API

    resetState

    use true if you want to hot start based on the provided state

    returns

    converged state from ADMM algorithm

  29. val n: Int

    Permalink
  30. final def ne(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  31. final def notify(): Unit

    Permalink
    Definition Classes
    AnyRef
  32. final def notifyAll(): Unit

    Permalink
    Definition Classes
    AnyRef
  33. final def synchronized[T0](arg0: ⇒ T0): T0

    Permalink
    Definition Classes
    AnyRef
  34. def toString(): String

    Permalink
    Definition Classes
    AnyRef → Any
  35. val transAeq: DenseMatrix[Double]

    Permalink
  36. def updateGram(upper: Array[Double]): Unit

    Permalink

    updateGram API allows user to seed QuadraticMinimizer with upper triangular gram matrix (memory optimization by 50%) specified through primitive arrays.

    updateGram API allows user to seed QuadraticMinimizer with upper triangular gram matrix (memory optimization by 50%) specified through primitive arrays. It is exposed for advanced users like Spark ALS where ALS constructs normal equations as primitive arrays

    upper

    upper triangular gram matrix specified in primitive array

  37. def updateGram(H: DenseMatrix[Double]): Unit

    Permalink

    updateGram allows the user to seed QuadraticMinimizer with symmetric gram matrix most useful for cases where the gram matrix does not change but the linear term changes for multiple solves.

    updateGram allows the user to seed QuadraticMinimizer with symmetric gram matrix most useful for cases where the gram matrix does not change but the linear term changes for multiple solves. It should be called iteratively from Normal Equations constructed by the user

    H

    rank * rank size full gram matrix

  38. val upperSize: Int

    Permalink
  39. final def wait(): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  40. final def wait(arg0: Long, arg1: Int): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  41. final def wait(arg0: Long): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )

Inherited from SerializableLogging

Inherited from Serializable

Inherited from Serializable

Inherited from AnyRef

Inherited from Any

Ungrouped