code: def default_embedding_hparams():
      r"""Returns a ``dict`` of hyperparameters and default values of a embedder.
  
      See :meth:`~texar.tf.modules.WordEmbedder.default_hparams` for details.
  
         .. code-block:: python
  
             {
                 "name": "embedding",
                 "dim": 100,
                 "initializer": None,
                 "regularizer": {
                     "type": "L1L2",
                     "kwargs": {
                         "l1": 0.,
                         "l2": 0.
                     }
                 },
                 "dropout_rate": 0.,
                 "dropout_strategy": 'element',
                 "trainable": True,
             }
  
         Here:
  
         `"name"`: str
             Name of the embedding variable.
  
         `"dim"`: int or list
             Embedding dimension. Can be a list of integers to yield embeddings
             with dimensionality > 1.
  
         `"initializer"`: dict or None
             Hyperparameters of the initializer for the embedding values. An
             example is as
  
             .. code-block:: python
  
                 {
                     "type": "random_uniform_initializer",
                     "kwargs": {
                         "minval": -0.1,
                         "maxval": 0.1,
                         "seed": None
                     }
                 }
  
             which corresponds to :tf_main:`tf.random_uniform_initializer
             <random_uniform_initializer>`, and includes:
  
             `"type"`: str or initializer instance
                 Name, full path, or instance of the initializer class; Or name
                 or full path to a function that returns the initializer class.
                 The class or function can be
  
                 - Built-in initializer defined in
                   :tf_main:`tf.initializers <initializers>`, e.g.,
                   :tf_main:`random_uniform <random_uniform_initializer>`
                   (a.k.a :class:`tf.random_uniform_initializer`), or
                   in :mod:`tf`, e.g., :tf_main:`glorot_uniform_initializer
                   <glorot_uniform_initializer>`, or in
                   :tf_main:`tf.keras.initializers <keras/initializers>`.
                 - User-defined initializer in :mod:`texar.tf.custom`.
                 - External initializer. Must provide the full path,
                   e.g., :attr:`"my_module.MyInitializer"`, or the instance.
  
             `"kwargs"`: dict
                 A dictionary of arguments for constructor of the
                 initializer class or for the function. An initializer is
                 created by ``initialzier = initializer_class_or_fn(**kwargs)``
                 where :attr:`initializer_class_or_fn` is specified in
                 :attr:`"type"`.
                 Ignored if :attr:`"type"` is an initializer instance.
  
         `"regularizer"`: dict
             Hyperparameters of the regularizer for the embedding values. The
             regularizer must be an instance of
             the base :tf_main:`Regularizer <keras/regularizers/Regularizer>`
             class. The hyperparameters include:
  
             `"type"`: str or regularizer instance
                 Name, full path, or instance of the regularizer class. The
                 class can be
  
                 - Built-in regularizer defined in
                   :tf_main:`tf.keras.regularizers <keras/regularizers>`, e.g.,
                   :tf_main:`L1L2 <keras/regularizers/L1L2>`.
                 - User-defined regularizer in :mod:`texar.tf.custom`. The
                   regularizer class should inherit the base class
                   :tf_main:`Regularizer <keras/regularizers/Regularizer>`.
                 - External regularizer. Must provide the full path,
                   e.g., :attr:`"my_module.MyRegularizer"`, or the instance.
  
             `"kwargs"`: dict
                 A dictionary of arguments for constructor of the
                 regularizer class. A regularizer is created by
                 calling `regularizer_class(**kwargs)` where
                 :attr:`regularizer_class` is specified in :attr:`"type"`.
                 Ignored if :attr:`"type"` is a regularizer instance.
  
             The default value corresponds to
             :tf_main:`L1L2 <keras/regularizers/L1L2>` with `(l1=0, l2=0)`,
             which disables regularization.
  
         `"dropout_rate"`: float
             The dropout rate between 0 and 1. E.g., `dropout_rate=0.1` would
             drop out 10% of the embedding.
  
         `"dropout_strategy"`: str
             The dropout strategy. Can be one of the following
  
             - ``"element"``: The regular strategy that drops individual elements
               in the embedding vectors.
             - ``"item"``: Drops individual items (e.g., words) entirely. For
               example, for the word sequence "the simpler the better", the
               strategy can yield "_ simpler the better", where the first "the"
               is dropped.
             - ``"item_type"``: Drops item types (e.g., word types). For example,
               for the above sequence, the strategy can yield "_ simpler _
               better", where the word type "the" is dropped. The dropout will
               never yield "_ simpler the better" as in the ``"item"`` strategy.
  
         `"trainable"`: bool
             Whether the embedding is trainable.
      """
      return {
          "name": "embedding",
          "dim": 100,
          "initializer": None,
          "regularizer": layers.default_regularizer_hparams(),
          "dropout_rate": 0.0,
          "dropout_strategy": "element",
          "trainable": True,
          "@no_typecheck": ["dim"],
      }
  
imports: import tensorflow
  from texar.tf.hyperparams import HParams
  from texar.tf.core import layers
label_desc: Use image node_id 1 for calling a global function with example usage: default_embedding_hparams() and returns: dict