def Conv2d(net, n_filter=32, filter_size=(3, 3), strides=(1, 1), act=None, padding='SAME', W_init=tf.truncated_normal_initializer(stddev=0.02), b_init=tf.constant_initializer(value=0.0), W_init_args={}, b_init_args={}, name='conv2d'):
 if (act is None):
  act = tf.identity
 net = Conv2dLayer(net, act=act, shape=[filter_size[0], filter_size[1], int(net.outputs.get_shape()[(-1)]), n_filter], strides=[1, strides[0], strides[1], 1], padding=padding, W_init=W_init, W_init_args=W_init_args, b_init=b_init, b_init_args=b_init_args, name=name)
 return net

def Conv2d ( net , n_filter = 32 , filter_size = ( 3 , 3 ) , strides = ( 1 , 1 ) , act = None , padding = 'SAME' , W_init = tf . truncated_normal_initializer ( stddev = 0.02 ) , b_init = tf . constant_initializer ( value = 0.0 ) , W_init_args = { } , b_init_args = { } , name = 'conv2d' ) : if ( act is None ) : act = tf . identity net = Conv2dLayer ( net , act = act , shape = [ filter_size [ 0 ] , filter_size [ 1 ] , int ( net . outputs . get_shape ( ) [ ( - 1 ) ] ) , n_filter ] , strides = [ 1 , strides [ 0 ] , strides [ 1 ] , 1 ] , padding = padding , W_init = W_init , W_init_args = W_init_args , b_init = b_init , b_init_args = b_init_args , name = name ) return net
wrapper for :class:conv2dlayer .