class_docstr: Performs spectral normalization on weights.
  
  This wrapper controls the Lipschitz constant of the layer by
  constraining its spectral norm, which can stabilize the training of GANs.
  
  See [Spectral Normalization for Generative Adversarial Networks](https://arxiv.org/abs/1802.05957).
  
  Wrap `tf.keras.layers.Conv2D`:
  
  >>> x = np.random.rand(1, 10, 10, 1)
  >>> conv2d = SpectralNormalization(tf.keras.layers.Conv2D(2, 2))
  >>> y = conv2d(x)
  >>> y.shape
  TensorShape([1, 9, 9, 2])
  
  Wrap `tf.keras.layers.Dense`:
  
  >>> x = np.random.rand(1, 10, 10, 1)
  >>> dense = SpectralNormalization(tf.keras.layers.Dense(10))
  >>> y = dense(x)
  >>> y.shape
  TensorShape([1, 10, 10, 10])
  
  Args:
    layer: A `tf.keras.layers.Layer` instance that
      has either `kernel` or `embeddings` attribute.
    power_iterations: `int`, the number of iterations during normalization.
  Raises:
    AssertionError: If not initialized with a `Layer` instance.
    ValueError: If initialized with negative `power_iterations`.
    AttributeError: If `layer` does not has `kernel` or `embeddings` attribute.
code: def get_config(self):
      config = {"power_iterations": self.power_iterations}
      base_config = super().get_config()
      return {**base_config, **config}
  
file_path: addons/tensorflow_addons/layers/spectral_normalization.py
imports: import tensorflow
  from typeguard import typechecked
label_desc: Use image node_id 6 for calling the SpectralNormalization obj's underlying member method code with example usage: obj.get_config() and returns: dict