48e056d31fa3be6b53b46aac46e39c576fc4e89c,keras/layers/wrappers.py,Bidirectional,call,#Bidirectional#Any#Any#Any#,212
Before Change
def call(self, inputs, training=None, mask=None):
func_args = inspect.getargspec(self.layer.call).args
kwargs = {}
for arg in ("training", "mask"):
if arg in func_args:
kwargs[arg] = eval(arg)
y = self.forward_layer.call(inputs, **kwargs)
y_rev = self.backward_layer.call(inputs, **kwargs)
if self.return_sequences:
y_rev = K.reverse(y_rev, 1)
After Change
if "training" in func_args:
kwargs["training"] = training
if "mask" in func_args:
kwargs["mask"] = mask
y = self.forward_layer.call(inputs, **kwargs)
y_rev = self.backward_layer.call(inputs, **kwargs)
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 3
Instances Project Name: keras-team/keras
Commit Name: 48e056d31fa3be6b53b46aac46e39c576fc4e89c
Time: 2017-04-02
Author: francois.chollet@gmail.com
File Name: keras/layers/wrappers.py
Class Name: Bidirectional
Method Name: call
Project Name: keras-team/keras
Commit Name: 94dbc3042f5a85b399f5ce2859d4e8fbafd235b9
Time: 2017-07-06
Author: me@taehoonlee.com
File Name: tests/keras/backend/backend_test.py
Class Name:
Method Name: check_two_tensor_operation
Project Name: keras-team/keras
Commit Name: 94dbc3042f5a85b399f5ce2859d4e8fbafd235b9
Time: 2017-07-06
Author: me@taehoonlee.com
File Name: tests/keras/backend/backend_test.py
Class Name:
Method Name: check_single_tensor_operation