6b106ab4ec9a1c0eb3e24ae590ce63f84022ad40,keras/backend/tensorflow_backend.py,,separable_conv2d,#Any#Any#Any#Any#Any#Any#Any#,3318
Before Change
x = _preprocess_conv2d_input(x, data_format)
padding = _preprocess_padding(padding)
strides = (1,) + strides + (1,)
x = tf.nn.separable_conv2d(x, depthwise_kernel, pointwise_kernel,
strides=strides,
padding=padding,
rate=dilation_rate)
return _postprocess_conv2d_output(x, data_format)
def depthwise_conv2d(x, depthwise_kernel, strides=(1, 1), padding="valid",
data_format=None, dilation_rate=(1, 1)):
After Change
if data_format not in {"channels_first", "channels_last"}:
raise ValueError("Unknown data_format " + str(data_format))
x, tf_data_format = _preprocess_conv2d_input(x, data_format)
padding = _preprocess_padding(padding)
if tf_data_format == "NHWC":
strides = (1,) + strides + (1,)
else:
strides = (1, 1) + strides
x = tf.nn.separable_conv2d(x, depthwise_kernel, pointwise_kernel,
strides=strides,
padding=padding,
rate=dilation_rate,
data_format=tf_data_format)
if data_format == "channels_first" and tf_data_format == "NHWC":
x = tf.transpose(x, (0, 3, 1, 2)) // NHWC -> NCHW
return x
def depthwise_conv2d(x, depthwise_kernel, strides=(1, 1), padding="valid",
data_format=None, dilation_rate=(1, 1)):
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 19
Instances
Project Name: keras-team/keras
Commit Name: 6b106ab4ec9a1c0eb3e24ae590ce63f84022ad40
Time: 2017-10-16
Author: francois.chollet@gmail.com
File Name: keras/backend/tensorflow_backend.py
Class Name:
Method Name: separable_conv2d
Project Name: keras-team/keras
Commit Name: 6b106ab4ec9a1c0eb3e24ae590ce63f84022ad40
Time: 2017-10-16
Author: francois.chollet@gmail.com
File Name: keras/backend/tensorflow_backend.py
Class Name:
Method Name: pool2d
Project Name: keras-team/keras
Commit Name: 6b106ab4ec9a1c0eb3e24ae590ce63f84022ad40
Time: 2017-10-16
Author: francois.chollet@gmail.com
File Name: keras/backend/tensorflow_backend.py
Class Name:
Method Name: separable_conv2d
Project Name: keras-team/keras
Commit Name: 6b106ab4ec9a1c0eb3e24ae590ce63f84022ad40
Time: 2017-10-16
Author: francois.chollet@gmail.com
File Name: keras/backend/tensorflow_backend.py
Class Name:
Method Name: depthwise_conv2d