@classmethod
def upconv(cls, in_tensor, layer_name, output_shape, kernel_size, stride, trainable=True):
    with tf.variable_scope(layer_name):
        in_size = in_tensor.get_shape().as_list()
        kernel_shape = [kernel_size, kernel_size, in_size[3], in_size[3]]
        strides = [1, stride, stride, 1]
        kernel = cls.get_deconv_filter(kernel_shape, trainable)
        tmp_result = tf.nn.conv2d_transpose(value=in_tensor, filter=kernel, output_shape=output_shape, strides=strides, padding='SAME')
        biases = tf.get_variable('biases', [kernel_shape[2]], tf.float32, tf.constant_initializer(0.0), trainable=trainable, collections=['wd', 'variables', 'biases'])
        out_tensor = tf.nn.bias_add(tmp_result, biases)
        return out_tensor
@classmethod
def upconv(cls, in_tensor, layer_name, output_shape, kernel_size, stride, trainable=True):
    with tf.variable_scope(layer_name):
        in_size = in_tensor.get_shape().as_list()
        kernel_shape = [kernel_size, kernel_size, in_size[3], in_size[3]]
        strides = [1, stride, stride, 1]
        kernel = cls.get_deconv_filter(kernel_shape, trainable)
        tmp_result = tf.nn.conv2d_transpose(value=in_tensor, filter=kernel, output_shape=output_shape, strides=strides, padding='SAME')
        biases = tf.get_variable('biases', [kernel_shape[2]], tf.float32, tf.constant_initializer(0.0), trainable=trainable, collections=['wd', 'variables', 'biases'])
        out_tensor = tf.nn.bias_add(tmp_result, biases)
        return out_tensor