Fixing missing bias term from model visualisation.
This commit is contained in:
parent
905545fd23
commit
60edabd261
@ -257,6 +257,7 @@
|
|||||||
"ax = fig.add_subplot(1, 1, 1)\n",
|
"ax = fig.add_subplot(1, 1, 1)\n",
|
||||||
"for weight, centre in zip(weights, centres):\n",
|
"for weight, centre in zip(weights, centres):\n",
|
||||||
" ys += weight * basis_function(xs, centre, scale)\n",
|
" ys += weight * basis_function(xs, centre, scale)\n",
|
||||||
|
"ys += bias\n",
|
||||||
"ax.plot(xs, ys)\n",
|
"ax.plot(xs, ys)\n",
|
||||||
"ax.set_xlabel('Input', fontsize=14)\n",
|
"ax.set_xlabel('Input', fontsize=14)\n",
|
||||||
"ax.set_ylabel('Output', fontsize=14)"
|
"ax.set_ylabel('Output', fontsize=14)"
|
||||||
|
Loading…
Reference in New Issue
Block a user