Skip to content

Commit 06a1545

Browse files
committed
Style fixes
1 parent 461573a commit 06a1545

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

keras/callbacks.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -479,6 +479,8 @@ def on_epoch_end(self, epoch, logs={}):
479479
else:
480480
test_function = self.model._test
481481
names = [v.name for v in test_function.inputs]
482+
# TODO: implement batched calls to sess.run
483+
# (current call will likely go OOM on GPU)
482484
feed_dict = dict(zip(names, self.model.validation_data))
483485
result = self.sess.run([self.merged], feed_dict=feed_dict)
484486
summary_str = result[0]

keras/layers/core.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -108,7 +108,7 @@ def __call__(self, X, mask=None, train=False):
108108
layer.name = "dummy"
109109
layer.input = X
110110
if hasattr(self, 'get_input_mask'):
111-
layer.get_input_mask = lambda _: mask
111+
layer.get_input_mask = lambda _: mask
112112
# set temporary previous
113113
tmp_previous = None
114114
if hasattr(self, 'previous'):
@@ -136,7 +136,7 @@ def set_previous(self, layer, reset_weights=True):
136136
if layer.get_output_mask() is not None:
137137
assert self.supports_masked_input(), 'Cannot connect non-masking layer to layer with masked output.'
138138
if not reset_weights:
139-
assert layer.output_shape == self.input_shape, ('Cannot connect layers without resetting weights: ' +
139+
assert layer.output_shape == self.input_shape, ('Cannot connect layers without resetting weights: ' +
140140
'expected input with shape ' +
141141
str(self.input_shape) +
142142
' but previous layer has output_shape ' +

0 commit comments

Comments
 (0)