import tensorflow as tf

                elif norm == 'G':
                    X = tf.contrib.layers.group_norm(X, groups=16, scope=scope, reuse=reuse)
                if nonlin:
                    X = tf.nn.leaky_relu(X, 0.2)
                return X

        with tf.variable_scope('discriminator') as scope:
            if reuse:
                scope.reuse_variables()

            print('D in:', X.get_shape().as_list())

            X = self.conv('DZ1', X, 512, 1, 1)
            X = tf.nn.leaky_relu(X, 0.2)
            X = self.conv('DZ2', X, 512, 1, 1)
            X = tf.nn.leaky_relu(X, 0.2)
            X = self.conv('DZ3', X, 512, 1, 1)
            X = tf.nn.leaky_relu(X, 0.2)
            X = self.conv('DZ4', X, 512, 1, 1)
            X = tf.nn.leaky_relu(X, 0.2)

            X = discrim_conv('d_out', X, 1, 1, norm=False, nonlin=False, init_stddev=0.02)

            print('D out:', X.get_shape().as_list())

            return X
