-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Gradient Descent
<math>x=\left[\begin{array}{cc} 1]</math>
<math>y=\left[\begin{array}{c} 8\\ 26 \end{array}\right]</math>
<math>\theta=\left[\begin{array}{c} 0\\ 0 \end{array}\right]</math>
<math>t=x\theta=\left[\begin{array}{cc} 1]\left[\begin{array}{c} 0\\ 0 \end{array}\right]=\left[\begin{array}{c} 0\\ 0 \end{array}\right] </math>
<math>e=t-y=\left[\begin{array}{c} 0\\ 0 \end{array}\right]-\left[\begin{array}{c} 8\\ 26 \end{array}\right]=\left[\begin{array}{c} -8\\ -26 \end{array}\right]</math>
<math>g=\frac{e\alpha}{m}=\left[\begin{array}{c} -4\\ -13 \end{array}\right]\times0.005</math>
<math>\theta=\theta-g=\left[\begin{array}{c} 0.02\\ 0.065 \end{array}\right] </math>
<math> t=\left[\begin{array}{cc} 1]\left[\begin{array}{c} 0.020\\ 0.065 \end{array}\right]=\left[\begin{array}{c} 0.215\\ 0.620 \end{array}\right] </math>
<math> e=\left[\begin{array}{c} 0.215\\ 0.620 \end{array}\right]-\left[\begin{array}{c} 8\\ 26 \end{array}\right]=\left[\begin{array}{c} -7.785\\ -25.388 \end{array}\right] </math>
<math> g=\left[\begin{array}{c} -0.0195\\ -0.0635 \end{array}\right] </math>
<math> \theta=\left[\begin{array}{c} 0.020\\ 0.065 \end{array}\right]-\left[\begin{array}{c} -0.0195\\ -0.0635 \end{array}\right] </math>