class_docstr: Embedding mapper relying on an adversarially trained network.
  
  This class makes use of a generator which generates clean embeddings provided
  obfuscated embeddings as input, as well as a discriminator which decides
  whether the provided embeddings come from clean images or from the generator.
  Both of these models are defined using MLPs, mapping from the space of
  obfuscated embedddings to the space of clean embeddings.
  
  Attributes:
    generator: Generator MLP, mapping obfuscated embeddings to clean ones.
    discriminator: Discriminator MLP, identifying whether its input embedding is
      real or created by the generator.
class_docstr_tok: ["Embedding","mapper","relying","on","an","adversarially","trained","network",".","This","class","makes","use","of","a","generator","which","generates","clean","embeddings","provided","obfuscated","embeddings","as","input",",","as","well","as","a","discriminator","which","decides","whether","the","provided","embeddings","come","from","clean","images","or","from","the","generator",".","Both","of","these","models","are","defined","using","MLPs",",","mapping","from","the","space","of","obfuscated","embedddings","to","the","space","of","clean","embeddings",".","Attributes",":","generator",":","Generator","MLP",",","mapping","obfuscated","embeddings","to","clean","ones",".","discriminator",":","Discriminator","MLP",",","identifying","whether","its","input","embedding","is","real","or","created","by","the","generator","."]
code: def __init__(
      self,
      embed_dim: int,
      generator_mlp_sizes: Sequence[int],
      discriminator_mlp_sizes: Sequence[int],
      weight_decay: float = 1e-4,
  ):
      super().__init__()
      self.generator = MLPEmbeddingMapper(
          embed_dim=embed_dim,
          mlp_sizes=generator_mlp_sizes,
          weight_decay=weight_decay,
      )
  
      self.discriminator = MLPEmbeddingMapper(
          embed_dim=1,
          mlp_sizes=discriminator_mlp_sizes,
          weight_decay=weight_decay,
      )
  
      # Start with generator trainable and discriminator frozen.
      self.generator.trainable = True
      self.discriminator.trainable = False
  
imports: import abc
  from typing import Union, Tuple, Sequence, Optional
  import tensorflow
  import tensorflow_hub
label_desc: Use image node_id 1 to create a new GANEmbeddingMapper object from inherited base classes: EmbeddingMapper with example: obj = GANEmbeddingMapper(embed_dim, generator_mlp_sizes, discriminator_mlp_sizes, weight_decay)