File tree Expand file tree Collapse file tree 1 file changed +4
-9
lines changed Expand file tree Collapse file tree 1 file changed +4
-9
lines changed Original file line number Diff line number Diff line change @@ -119,17 +119,12 @@ def evaluate(self, test_data):
119
119
for (x , y ) in test_data ]
120
120
return sum (int (x == y ) for (x , y ) in test_results )
121
121
122
- def cost (self , x , y ):
123
- """Return the quadratic cost associated to the network, with
124
- input ``x`` and desired output ``y``. Note that there is no
125
- regularization."""
126
- return np .sum ((self .feedforward (x )- y )** 2 )/ 2.0
127
-
128
122
def cost_derivative (self , output_activations , y ):
129
123
"""Return the vector of partial derivatives \partial C_x /
130
- \partial a for the output activations, ``a``. For the
131
- unregularized quadratic cost this is just the difference
132
- between the output activations and the desired output, ``y``."""
124
+ \partial a for the ``output_activations``. For the
125
+ (unregularized) quadratic cost this is just the difference
126
+ between the ``output_activations`` and the desired output,
127
+ ``y``."""
133
128
return (output_activations - y )
134
129
135
130
#### Miscellaneous functions
You can’t perform that action at this time.
0 commit comments