From 9969b47ba46cfdcba14074208deb14c0e130a067 Mon Sep 17 00:00:00 2001
From: pswietojanski
Date: Tue, 17 Nov 2015 13:59:16 +0000
Subject: [PATCH] fixing naming of bprop_cost (thanks to anyone who reported
this to Matt)
---
mlp/layers.py | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/mlp/layers.py b/mlp/layers.py
index 777cda3..f87dab2 100644
--- a/mlp/layers.py
+++ b/mlp/layers.py
@@ -401,7 +401,7 @@ class Sigmoid(Linear):
___, ograds = super(Sigmoid, self).bprop(h=None, igrads=deltas)
return deltas, ograds
- def cost_bprop(self, h, igrads, cost):
+ def bprop_cost(self, h, igrads, cost):
if cost is None or cost.get_name() == 'bce':
return super(Sigmoid, self).bprop(h=h, igrads=igrads)
else:
@@ -475,7 +475,7 @@ class Relu(Linear):
___, ograds = super(Relu, self).bprop(h=None, igrads=deltas)
return deltas, ograds
- def cost_bprop(self, h, igrads, cost):
+ def bprop_cost(self, h, igrads, cost):
raise NotImplementedError('Relu.bprop_cost method not implemented '
'for the %s cost' % cost.get_name())
@@ -502,7 +502,7 @@ class Tanh(Linear):
___, ograds = super(Tanh, self).bprop(h=None, igrads=deltas)
return deltas, ograds
- def cost_bprop(self, h, igrads, cost):
+ def bprop_cost(self, h, igrads, cost):
raise NotImplementedError('Tanh.bprop_cost method not implemented '
'for the %s cost' % cost.get_name())
@@ -548,7 +548,7 @@ class Maxout(Linear):
___, ograds = super(Maxout, self).bprop(h=None, igrads=deltas)
return deltas, ograds
- def cost_bprop(self, h, igrads, cost):
+ def bprop_cost(self, h, igrads, cost):
raise NotImplementedError('Maxout.bprop_cost method not implemented '
'for the %s cost' % cost.get_name())