Skip to content

Commit

Permalink
Replace C with self.C, fixes ageron#386
Browse files Browse the repository at this point in the history
  • Loading branch information
ageron committed Mar 1, 2021
1 parent 3d104c2 commit f7608ba
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion 05_support_vector_machines.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -1631,7 +1631,7 @@
" self.Js.append(J)\n",
"\n",
" w_gradient_vector = w - self.C * np.sum(X_t_sv, axis=0).reshape(-1, 1)\n",
" b_derivative = -C * np.sum(t_sv)\n",
" b_derivative = -self.C * np.sum(t_sv)\n",
" \n",
" w = w - self.eta(epoch) * w_gradient_vector\n",
" b = b - self.eta(epoch) * b_derivative\n",
Expand Down

0 comments on commit f7608ba

Please sign in to comment.