Package parsimony :: Package functions :: Module penalties :: Class SufficientDescentCondition
[hide private]
[frames] | no frames]

Class SufficientDescentCondition

source code

           object --+    
                    |    
  properties.Function --+
                        |
           object --+   |
                    |   |
properties.Constraint --+
                        |
                       SufficientDescentCondition

Nested Classes [hide private]

Inherited from properties.Function: __metaclass__

Instance Methods [hide private]
 
__init__(self, function, p, c=0.0001)
The sufficient condition
source code
 
f(self, x, a)
Function value.
source code
 
feasible(self, xa)
Feasibility of the constraint at point x with step a.
source code

Inherited from properties.Function: get_params, reset, set_params

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Class Variables [hide private]
  __abstractmethods__ = frozenset([])
Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self, function, p, c=0.0001)
(Constructor)

source code 
The sufficient condition

    f(x + a * p) <= f(x) + c * a * grad(f(x))'p

for descent. This condition is sometimes called the Armijo condition.

Parameters
----------
p : Numpy array. The descent direction.

c : Float, 0 < c < 1. A constant for the condition. Should be small.

Overrides: object.__init__

f(self, x, a)

source code 

Function value.

Overrides: properties.Function.f
(inherited documentation)

feasible(self, xa)

source code 

Feasibility of the constraint at point x with step a.

From the interface "Constraint".

Overrides: properties.Constraint.feasible