abstract class StochasticGradientDescent[T] extends FirstOrderMinimizer[T, StochasticDiffFunction[T]] with SerializableLogging

Minimizes a function using stochastic gradient descent

Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. StochasticGradientDescent
  2. FirstOrderMinimizer
  3. SerializableLogging
  4. Serializable
  5. Minimizer
  6. AnyRef
  7. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. Protected

Instance Constructors

  1. new StochasticGradientDescent(defaultStepSize: Double, maxIter: Int, tolerance: Double = 1E-5, fvalMemory: Int = 100)(implicit vspace: NormedModule[T, Double])

Type Members

  1. abstract type History

    Any history the derived minimization function needs to do its updates.

    Any history the derived minimization function needs to do its updates. typically an approximation to the second derivative/hessian matrix.

    Definition Classes
    FirstOrderMinimizer
  2. type State = FirstOrderMinimizer.State[T, Info, History]
    Definition Classes
    FirstOrderMinimizer

Abstract Value Members

  1. abstract def initialHistory(f: StochasticDiffFunction[T], init: T): History
    Attributes
    protected
    Definition Classes
    FirstOrderMinimizer
  2. abstract def updateHistory(newX: T, newGrad: T, newVal: Double, f: StochasticDiffFunction[T], oldState: State): History
    Attributes
    protected
    Definition Classes
    FirstOrderMinimizer

Concrete Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##: Int
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  4. def adjust(newX: T, newGrad: T, newVal: Double): (Double, T)
    Attributes
    protected
    Definition Classes
    FirstOrderMinimizer
  5. def adjustFunction(f: StochasticDiffFunction[T]): StochasticDiffFunction[T]
    Attributes
    protected
    Definition Classes
    FirstOrderMinimizer
  6. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  7. def calculateObjective(f: StochasticDiffFunction[T], x: T, history: History): (Double, T)
    Attributes
    protected
    Definition Classes
    FirstOrderMinimizer
  8. def chooseDescentDirection(state: State, fn: StochasticDiffFunction[T]): T
    Attributes
    protected
    Definition Classes
    StochasticGradientDescentFirstOrderMinimizer
  9. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.CloneNotSupportedException]) @native() @IntrinsicCandidate()
  10. val convergenceCheck: ConvergenceCheck[T]
    Definition Classes
    FirstOrderMinimizer
  11. val defaultStepSize: Double
  12. def determineStepSize(state: State, f: StochasticDiffFunction[T], dir: T): Double

    Choose a step size scale for this iteration.

    Choose a step size scale for this iteration.

    Default is eta / math.pow(state.iter + 1,2.0 / 3.0)

    Definition Classes
    StochasticGradientDescentFirstOrderMinimizer
  13. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  14. def equals(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef → Any
  15. final def getClass(): Class[_ <: AnyRef]
    Definition Classes
    AnyRef → Any
    Annotations
    @native() @IntrinsicCandidate()
  16. def hashCode(): Int
    Definition Classes
    AnyRef → Any
    Annotations
    @native() @IntrinsicCandidate()
  17. def infiniteIterations(f: StochasticDiffFunction[T], state: State): Iterator[State]
    Definition Classes
    FirstOrderMinimizer
  18. def initialState(f: StochasticDiffFunction[T], init: T): State
    Attributes
    protected
    Definition Classes
    FirstOrderMinimizer
  19. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  20. def iterations(f: StochasticDiffFunction[T], init: T): Iterator[State]
    Definition Classes
    FirstOrderMinimizer
  21. def logger: LazyLogger
    Attributes
    protected
    Definition Classes
    SerializableLogging
  22. val maxIter: Int
  23. def minimize(f: StochasticDiffFunction[T], init: T): T
    Definition Classes
    FirstOrderMinimizerMinimizer
  24. def minimizeAndReturnState(f: StochasticDiffFunction[T], init: T): State
    Definition Classes
    FirstOrderMinimizer
  25. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  26. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native() @IntrinsicCandidate()
  27. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native() @IntrinsicCandidate()
  28. final def synchronized[T0](arg0: => T0): T0
    Definition Classes
    AnyRef
  29. def takeStep(state: State, dir: T, stepSize: Double): T

    Projects the vector x onto whatever ball is needed.

    Projects the vector x onto whatever ball is needed. Can also incorporate regularization, or whatever.

    Default just takes a step

    Attributes
    protected
    Definition Classes
    StochasticGradientDescentFirstOrderMinimizer
  30. def toString(): String
    Definition Classes
    AnyRef → Any
  31. implicit val vspace: NormedModule[T, Double]
    Attributes
    protected
  32. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  33. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException]) @native()
  34. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])

Deprecated Value Members

  1. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.Throwable]) @Deprecated
    Deprecated

Inherited from SerializableLogging

Inherited from Serializable

Inherited from Minimizer[T, StochasticDiffFunction[T]]

Inherited from AnyRef

Inherited from Any

Ungrouped