code: def get_variable(self, name, initializer):
      
      v = tf.get_variable(name, shape=initializer.shape,
                          initializer=(lambda shape, dtype, partition_info:
                                       initializer),
                          trainable=self.training)
      return v
docs: Create and initialize a variable using a numpy array and set trainable.
      :param name: (required str) name of the variable
      :param initializer: a numpy array or a tensor