code: def create_generator_layers(x):
      with tf.variable_scope("generator", reuse=tf.AUTO_REUSE):
          x_reshaped = tf.reshape(x, [-1, 1, 1, x.get_shape()[1]])
          # 1rst HIDDEN LAYER
          conv1 = tf.layers.conv2d_transpose(
              x_reshaped, 1024, [4, 4], strides=(1, 1), padding="valid"
          )
          normalized1 = tf.layers.batch_normalization(conv1)
          lrelu1 = tf.nn.leaky_relu(normalized1)
  
          # 2nd HIDDEN LAYER
          conv2 = tf.layers.conv2d_transpose(
              lrelu1, 512, [4, 4], strides=(2, 2), padding="same"
          )
          normalized2 = tf.layers.batch_normalization(conv2)
          lrelu2 = tf.nn.leaky_relu(normalized2)
  
          # 3rd HIDDEN LAYER
          conv3 = tf.layers.conv2d_transpose(
              lrelu2, 256, [4, 4], strides=(2, 2), padding="same"
          )
          normalized3 = tf.layers.batch_normalization(conv3)
          lrelu3 = tf.nn.leaky_relu(normalized3)
  
          # 4th HIDDEN LAYER
          conv4 = tf.layers.conv2d_transpose(
              lrelu3, 128, [4, 4], strides=(2, 2), padding="same"
          )
          normalized4 = tf.layers.batch_normalization(conv4)
          lrelu4 = tf.nn.leaky_relu(normalized4)
  
          # OUTPUT LAYER
          conv5 = tf.layers.conv2d_transpose(
              lrelu4, 1, [4, 4], strides=(2, 2), padding="same"
          )
          output = tf.nn.tanh(conv5, name="output_non_normalized")
  
          # denormalizing images
          output_resized = tf.image.resize_images(output, [28, 28])
          return tf.add(
              tf.multiply(output_resized, 0.5), 0.5, name="output"
          )
  
file_path: adversarial-robustness-toolbox/utils/resources/create_inverse_gan_models.py
imports: import logging
  import time
  import os
  import numpy
  import tensorflow
  from art.utils import load_mnist
label_desc: Use image node_id 1 for calling a global function with example usage: create_generator_layers(x) and returns: tf