关于Newton-Raphson Algorithm及其NDT实现[20151124]

来源:互联网 发布:caffe.io.transformer 编辑:程序博客网 时间:2024/05/22 15:43

须要保证当前迭代方向为负梯度方向,即:

f(x)x|x=x(i1)Δp<0

其中Δp满足HΔp=g

  // Set the value of phi(0), Equation 1.3 [More, Thuente 1994]  double phi_0 = -score;  // Set the value of phi'(0), Equation 1.3 [More, Thuente 1994]  double d_phi_0 = -(score_gradient.dot (step_dir));  if (d_phi_0 >= 0)  {    // Not a decent direction    if (d_phi_0 == 0)      return 0;    else    {      // Reverse step direction and calculate optimal step.      d_phi_0 *= -1;      step_dir *= -1;    }  }

根据[More, Thuente 1994],定义

ϕ(α)f(x+αp)

对于可接受步长α>0应满足
ϕ(α)ϕ(0)+μϕ(0)α


|ϕ(α)|η|ϕ(0)|

分别定义了sufficient decrease和positive average curvature of ϕ on (0,α)
其中μ,η(0,1)ϕ(0)<0

0 0
原创粉丝点击